Skip to content

Instantly share code, notes, and snippets.

@ikrima
Last active December 12, 2015 15:55
Show Gist options
  • Save ikrima/b8427028c10db1595e8a to your computer and use it in GitHub Desktop.
Save ikrima/b8427028c10db1595e8a to your computer and use it in GitHub Desktop.
Keep Editor window alive during VR Preview
if (bUseVRPreviewForPlayWorld && GEngine->HMDDevice.IsValid())
{
GEngine->HMDDevice->EnableStereo(true);
// minimize the root window to provide max performance for the preview.
TSharedPtr<SWindow> RootWindow = FGlobalTabmanager::Get()->GetRootWindow();
if (RootWindow.IsValid())
{
//////////////////////////////
//TODO: ikrimae: Pipe disabling this based on a config variable. So far hasn't crashed the editor but need stability testing & also it's a perf hit
//RootWindow->Minimize();
//////////////////////////////
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment