Files
UnrealEngine/Engine/Source/Runtime/HeadMountedDisplay/Private/IXRLoadingScreen.cpp
2025-05-18 13:04:45 +08:00

26 lines
634 B
C++

// Copyright Epic Games, Inc. All Rights Reserved.
#include "IXRLoadingScreen.h"
#include "IXRTrackingSystem.h"
#include "EngineGlobals.h"
#include "Engine/Engine.h"
void IXRLoadingScreen::ShowLoadingScreen_Compat(bool bShow, FTextureRHIRef Texture, const FVector& Offset, const FVector2D& Scale)
{
// Backwards compatibility with IStereoLayers::ShowSplashScreen
IXRLoadingScreen* LoadingScreen = GEngine && GEngine->XRSystem.IsValid()? GEngine->XRSystem->GetLoadingScreen() : nullptr;
if (LoadingScreen)
{
if (bShow)
{
LoadingScreen->ShowLoadingScreen();
}
else
{
LoadingScreen->HideLoadingScreen();
}
}
}