Internal team is encountering a crash when adding too many VR devices.
Email thread titled "Re: Crash Logs"
The bug is an internal limit of devices the code supports, which is 8. If a controller outside those bounds tries to register input the code crashes.
Example: HMD + 4 lighthouses + 2 controllers + 2 pucks == 9 devices. If a controller is turned on last it will crash the game.
Workaround
Our workaround was to always turn on the controllers before the pucks.
Potential Fix to Verify
I'm thinking an easy short-term fix is to make the ControllerStates array size to be vr::k_unMaxTrackedDeviceCount (which is 64), since the SendControllerEvents loop indexes into ControllerStates with indices in that range.
I'm hesitant to submit this sight unseen and I'm out this afternoon. Shelved this change in 4336476 if anyone wants to try.
NickW, is there anyone on the VR team that can give this a peek and make sure this is a valid approach (and fix it in Main?)
Repro:
1. Have 8 devices to connect to steam VR. Make sure controllers are connected last.
i.e. HMD + 2 Light Houses + 4 Pucks + 2 Controllers (don't connect controllers yet)
2. Open a project in the editor.
3. Connect all devices connecting the controllers last.
4. Observe editor crash.
Results: Editor crashes
Note have to restart SteamVR to stop crashes even after all devices are disconnected
[2018.08.31-00.52.57:645][ 0]LogWindows: Error: Assertion failed: IsValidIndex(Index) [Link Removed] [Line: 403]
[2018.08.31-00.52.57:645][ 0]LogWindows: Error: IsValidIndex(1523229094)
[2018.08.31-00.52.57:645][ 0]LogWindows: Error:
[2018.08.31-00.52.57:645][ 0]LogWindows: Error:
[2018.08.31-00.52.57:645][ 0]LogWindows: Error: [Callstack] 0x00007ffb773da388 KERNELBASE.dll!UnknownFunction []
[2018.08.31-00.52.57:645][ 0]LogWindows: Error: [Callstack] 0x00007ffb0c1a7450 UE4Editor-ApplicationCore.dll!FWindowsErrorOutputDevice::Serialize() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ffb09c4a12b UE4Editor-Core.dll!FOutputDevice::LogfImpl() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ffb09bd5299 UE4Editor-Core.dll!FDebug::AssertFailed() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ffb09e76430 UE4Editor-Core.dll!FName::GetDisplayNameEntry() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ffb09e8f63f UE4Editor-Core.dll!FName::ToString() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ffb09e8f5e8 UE4Editor-Core.dll!FName::ToString() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ffb08e85cf1 UE4Editor-Slate.dll!FSlateApplication::OnControllerButtonPressed() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ffb10d454f4 UE4Editor-SteamVRController.dll!FSteamVRController::SendControllerEvents() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ffb0c19cf47 UE4Editor-ApplicationCore.dll!FWindowsApplication::PollGameDeviceState() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ffb08e8fc84 UE4Editor-Slate.dll!FSlateApplication::PollGameDeviceState() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ff6d18c5ab9 UE4Editor.exe!FEngineLoop::Tick() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ff6d18d6b30 UE4Editor.exe!GuardedMain() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ff6d18d6baa UE4Editor.exe!GuardedMainWrapper() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ff6d18e3f77 UE4Editor.exe!WinMain() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ff6d18e59d7 UE4Editor.exe!__scrt_common_main_seh() []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ffb78283034 KERNEL32.DLL!UnknownFunction []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error: [Callstack] 0x00007ffb7a571431 ntdll.dll!UnknownFunction []
[2018.08.31-00.52.57:646][ 0]LogWindows: Error:
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-63579 in the post.
0 |
Component | UE - Platform - XR |
---|---|
Affects Versions | 4.21 |
Target Fix | 4.21 |
Created | Aug 31, 2018 |
---|---|
Resolved | Sep 7, 2018 |
Updated | Sep 16, 2019 |