ChannexDK Posted January 24, 2022 Posted January 24, 2022 Unity 2020.3.8 OpenVR 1.1.4 VIVE Hands Tracking SDK 1.0.0 When exiting playmode, the GestureInterface.StopGestureDetection(); crashes. I noticed the comment in the WindowsPlayModeMonitor, saying that it needed to shutdown the detection engine, because the UnityXR system stops before OnApplicationExit is called. This is very true, but judging from the log, the XR system is also being shut down before the playModeStateChanged callback is executed. I'm not entirely sure how to work around this, since there is no earlier callback in Unity that I know of, so the best resolution would be for the aristo_interface to not assume that any XR pointers are valid when StopGestureDetection is called. It seems like it's trying to access something in a SetCameraTransform() function - and I have made absolutely sure that it is not because SetCameraTransform is being called from the Unity side (added logs around the call and checked). Note: The log entry "ViveHandTrackingEngine.StopDetection() called" is from a Debug.Log statement I added to make sure exactly where the crash came from. My StopDetection method in ViveHandTrackingEngine.cs looks like this: public override void StopDetection() { Debug.Log("ViveHandTrackingEngine.StopDetection() called"); this.isRunning = false; GestureInterface.StopGestureDetection(); lastIndex = -1; Debug.Log("ViveHandTrackingEngine.StopDetection() Complete"); } The StopDetection() log statement is never logged (therefore I can be fairly certain that the crash is occuring in StopGestureDetection(). No other changes were made to the package and the crash also happens in the examples. Every time. Except from the log: [XR] [OpenVR] Device disconnected (stopping provider). Handle: 653853456. DeviceID: 0 [XR] [OpenVR] Device disconnected (stopping provider). Handle: 653853456. DeviceID: 1 [XR] [OpenVR] Device disconnected (stopping provider). Handle: 653853456. DeviceID: 2 [XR] [OpenVR] Device disconnected (stopping provider). Handle: 653853456. DeviceID: 3 [XR] [OpenVR] XR OpenVR Display Stop [XR] [OpenVR] XR OpenVR Display Shutdown XRTextureManager::RequestDestroyTexture XRTextureManager::RequestDestroyTexture XRTextureManager::RequestDestroyTexture XRTextureManager::RequestDestroyTexture [XR] [OpenVR] Shutdown XRTextureManager::RequestDestroyTexture XRTextureManager::RequestDestroyTexture XRTextureManager::RequestDestroyTexture XRTextureManager::RequestDestroyTexture ViveHandTrackingEngine.StopDetection() called UnityEngine.StackTraceUtility:ExtractStackTrace () UnityEngine.DebugLogHandler:LogFormat (UnityEngine.LogType,UnityEngine.Object,string,object[]) UnityEngine.Logger:Log (UnityEngine.LogType,object) UnityEngine.Debug:Log (object) ViveHandTracking.ViveHandTrackingEngine:StopDetection () (at Packages/com.htc.upm.vivehandtracking@1.0.0/Runtime/Scripts/Engine/ViveHandTrackingEngine.cs:220) ViveHandTracking.GestureProvider:StopGestureDetection () (at Packages/com.htc.upm.vivehandtracking@1.0.0/Runtime/Scripts/GestureProvider.cs:181) ViveHandTracking.GestureProvider:OnDisable () (at Packages/com.htc.upm.vivehandtracking@1.0.0/Runtime/Scripts/GestureProvider.cs:189) ViveHandTracking.WindowsPlayModeMonitor:LogPlayModeState (UnityEditor.PlayModeStateChange) (at Packages/com.htc.upm.vivehandtracking@1.0.0/Editor/WindowsPlayModeMonitor.cs:16) UnityEditor.EditorApplication:Internal_PlayModeStateChanged (UnityEditor.PlayModeStateChange) **Content CUT for clarity** ========== OUTPUTTING STACK TRACE ================== 0x00007FFA3F2762C2 (aristo_interface) SetCameraTransform 0x00007FFA3F270268 (aristo_interface) SetCameraTransform 0x00007FFA3F26CB6F (aristo_interface) GetGestureResult ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFA3F257A54) 0x00007FFA3F257A54 (aristo_interface) (function-name not available) ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFA3F25AC9F) 0x00007FFA3F25AC9F (aristo_interface) (function-name not available) ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFA3F25E655) 0x00007FFA3F25E655 (aristo_interface) (function-name not available) ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFA3F259B28) 0x00007FFA3F259B28 (aristo_interface) (function-name not available) 0x00007FFAB7BE1BB2 (ucrtbase) configthreadlocale 0x00007FFAB8BC7034 (KERNEL32) BaseThreadInitThunk 0x00007FFABA362651 (ntdll) RtlUserThreadStart ========== END OF STACKTRACE =========== 1
TMosier Posted January 27, 2022 Posted January 27, 2022 Having the exact same issue. Sample projects are crashing on playmode exit but also, the HMD doesn't seem to track when I enter playmode. The scene loads and I can see the default hand positions but the movement of the camera does not track at all. Exiting playmode crashes and my log file looks basically identical.
cri_eva Posted March 2, 2022 Posted March 2, 2022 Any updates on this issue? I have the same problem using Unity 2021.1.27f1
Ryan Logan Posted May 13, 2022 Posted May 13, 2022 (edited) Same here in 2020.3.20f1 with a Cosmos. Tracking works fine (well as good as it's going to work), but crashes every time I exit play mode. Edited May 13, 2022 by Ryan Logan
4bgt Posted October 17, 2022 Posted October 17, 2022 Got this from a bug report in Unity: Katrina Kaktavičiūtė commented: Hi, Thank you for reporting this issue I have checked the editor logs and it seems to be crashing with "aristo_interface" DLL: 0x00007FFB73D562C2 (aristo_interface) SetCameraTransform 0x00007FFB73D50268 (aristo_interface) SetCameraTransform 0x00007FFB73D4CB6F (aristo_interface) GetGestureResult ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFB73D37A54) 0x00007FFB73D37A54 (aristo_interface) (function-name not available) ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFB73D3AC9F) 0x00007FFB73D3AC9F (aristo_interface) (function-name not available) ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFB73D3E655) 0x00007FFB73D3E655 (aristo_interface) (function-name not available) ERROR: SymGetSymFromAddr64, GetLastError: 'Attempt to access invalid address.' (Address: 00007FFB73D39B28) 0x00007FFB73D39B28 (aristo_interface) (function-name not available) 0x00007FFBDF3F1BB2 (ucrtbase) configthreadlocale 0x00007FFBE0BD7034 (KERNEL32) BaseThreadInitThunk 0x00007FFBE14C26A1 (ntdll) RtlUserThreadStart ... Please report this issue to HTC as this DLL belongs to them, also I have found a forum thread where you could find some answers to your problem: [https://forum.vive.com/topic/9816-ver-0100-dllnotfoundexception-aristo_interface/|https://forum.vive.com/topic/9816-ver-0100-dllnotfoundexception-aristo_interface/|smart-link] I will be closing the case and if you have more questions feel free to ask. Best Regards, Katrina Customer QA Team I also played around a bit. To me it looks like the Stop function is working properly, but is either too slow or called to late when changing the play-state. My current work-around is to use a function that 1) destroys the object with the gesture interface script, so StopDetection() is called earlier through it's OnDestroy() function 2) afterwards stops unity. This is not perfect, but better then crashing every time. 1
Kate.kate Posted July 11, 2023 Posted July 11, 2023 I also solved the problem of crashing on stop by manually deactivating the hand detection on application quit. This is the line of code I used: GestureProvider.Current.enabled = false; // disable the script to stop the detection
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now