OSVR-Unreal icon indicating copy to clipboard operation
OSVR-Unreal copied to clipboard

Render Manager is null causing osvrRenderManagerGetRenderInfoCollection failure

Open ndrmstevenh opened this issue 9 years ago • 2 comments

@JeroMiya

I'm using UE4.13 and I'm hitting an assert which I think is caused by mRenderManager being a nullptr after getting the latest commit (bfdb58d).

Callstack is as follows

AGame.exe!FOSVRCustomPresent::UpdateCachedRenderInfoCollection(void * & renderInfoCollection) Line 300 C++ AGame.exe!FOSVRCustomPresent::GetHeadPoseFromCachedRenderInfoCollection(bool renderThread, bool updateCache) Line 146 C++ AGame.exe!FOSVRHMD::UpdateHeadPose(bool renderThread, FQuat & lastHmdOrientation, FVector & lastHmdPosition, FQuat & hmdOrientation, FVector & hmdPosition) Line 229 C++ AGame.exe!FOSVRHMD::UpdatePlayerCamera(FQuat & CurrentOrientation, FVector & CurrentPosition) Line 366 C++ AGame.exe!UCameraComponent::GetCameraView(float DeltaTime, FMinimalViewInfo & DesiredView) Line 226 C++ AGame.exe!AActor::CalcCamera(float DeltaTime, FMinimalViewInfo & OutResult) Line 2301 C++ AGame.exe!APlayerCameraManager::UpdateViewTargetInternal(FTViewTarget & OutVT, float DeltaTime) Line 416 C++ AGame.exe!APlayerCameraManager::UpdateViewTarget(FTViewTarget & OutVT, float DeltaTime) Line 514 C++ AGame.exe!APlayerCameraManager::DoUpdateCamera(float DeltaTime) Line 858 C++ AGame.exe!APlayerCameraManager::UpdateCamera(float DeltaTime) Line 823 C++ AGame.exe!UWorld::Tick(ELevelTick TickType, float DeltaSeconds) Line 1334 C++ AGame.exe!UGameEngine::Tick(float DeltaSeconds, bool bIdleMode) Line 1057 C++ AGame.exe!FEngineLoop::Tick() Line 2838 C++ AGame.exe!GuardedMain(const wchar_t * CmdLine, HINSTANCE__ * hInInstance, HINSTANCE__ * hPrevInstance, int nCmdShow) Line 156 C++ AGame.exe!WinMain(HINSTANCE__ * hInInstance, HINSTANCE__ * hPrevInstance, char * __formal, int nCmdShow) Line 191 C++ [External Code]

ndrmstevenh avatar Nov 24 '16 08:11 ndrmstevenh

Thanks for reporting this @ndrmstevenh. I wasn't able to reproduce this myself, but I went ahead and added some null guards and additional diagnostics in this branch:

https://github.com/OSVR/OSVR-Unreal/tree/cached-ri-nullptr-fix

Could you do me a big favor and pull that version of the code to see if it fixes your problem? You may see some log messages about mRenderManager being null, but if you see it repeating the same messages every frame then this is not a full fix. If you could also post your unreal logs to this issue, that would be helpful. Thanks!

JeroMiya avatar Nov 30 '16 17:11 JeroMiya

Hi JeroMiya, I grabbed those changes and that does indeed fix the problem. Which specific logs would you need? There doesn't appear to be anything in the logs folder that was outputted on that day other than an ini.

ndrmstevenh avatar Dec 01 '16 10:12 ndrmstevenh