Reproducible crash in Oculus Integration v31.2 using OVRHaptics
Reporting bugs on this forum feels like whispering in the wind, but here goes:
- Oculus Quest is set to "Auto Switch between hands and controllers"
- Application built with Oculus Integration v31.2 (legacy OVRPlugin) configured to use hands and controllers
- Launch application in "hand tracking" mode
- Once application is running switch to controllers
- Attempt to play a properly configured OVRHapticsClip
- Crash (if you're running ARM64 build)
Expected results:
- No crash
If running ARM64 build (IL2CPP):
E CRASH : Cause: null pointer dereference
If running ARM7 build (Mono):
E Unity : ArgumentNullException: Value cannot be null.
E Unity : Parameter name: dest
E Unity : at (wrapper managed-to-native) System.Runtime.InteropServices.Marshal.copy_to_unmanaged(System.Array,int,intptr,int)
E Unity : at System.Runtime.InteropServices.Marshal.Copy (System.Byte[] source, System.Int32 startIndex, System.IntPtr destination, System.Int32 length) [0x00000] in <8cb436e1877f4e87804bd45a3de980ae>:0
E Unity : at OVRHaptics+OVRHapticsOutput.Process () [0x001d5] in <project path>\Assets\Oculus\VR\Scripts\OVRHaptics.cs:227
E Unity : at OVRHaptics.Process () [0x0000c] in <project path>\Assets\Oculus\VR\Scripts\OVRHaptics.cs:381
E Unity : at OVRManager.LateUpdate () [0x00001] in <project path>\Assets\Oculus\VR\Scripts\OVRManager.cs:2010
I'm definitely not passing a null OVRHapticsClip, and if I launch the app in controller mode the haptic plays correctly.
Theory: If you start the app in hand tracking mode this call doesn't return what you're expecting:
// OVRHaptics.cs line 67
OVRPlugin.HapticsDesc desc = OVRPlugin.GetControllerHapticsDesc((uint)OVRPlugin.Controller.RTouch);
