Quantcast
Channel: Questions in topic: "native plugin"
Viewing all articles
Browse latest Browse all 376

Editor crash "allocation 0x0xc000000000000000 already registered"

$
0
0
I am trying to integrate [libfreenect2][1] and [freenect2.net wrapper][2] but I am getting a strange crash that only happens in the Linux editor for my main project. The Windows editor, and Windows and Linux standalone all work fine. I am using editor version 2017.2.0f3. The crash happens almost instantly after I call `device = new Device(0);` to initialize the Kinect device. There is an error in the console, then the editor itself closes. I tried copying just the code that interacts with the Kinect to a new project, and it worked there. How can I find the cause of the crash? Or am I stuck copying pieces one at a time to a new project until it starts crashing? Relevant bits of scripts: //KinectManager2.cs void Start () { depthSources = GetComponents(); Array.Sort(depthSources, delegate (DepthSourceBase a, DepthSourceBase b) { return a.Priority.CompareTo(b.Priority); }); foreach (DepthSourceBase source in depthSources) { if (source.enabled && source.InitDepthSource()) { activeDepthSource = source; break; } } } //KinectTwoDepthSource.cs public override bool InitDepthSource() { try { if (Device.Count > 0) { device = new Device(0); foundKinect = true; Width = device.DepthFrameSize.Width; Height = device.DepthFrameSize.Height; raw = new float[Width * Height]; averageDepth = new float[Width * Height]; averageDepthCount = new int[Width * Height]; for (int i = 0; i < depthBuffer.Length; i++) { depthBuffer[i] = new float[Width * Height]; for (int j = 0; j < depthBuffer[i].Length; j++) { depthBuffer[i][j] = float.NaN; } } device.FrameReceived += Handle_KinectTwo_DataReceived; return true; } } catch (DllNotFoundException) { } return false; } Here is the Editor.log from right before initializing the device. I'm not sure why it is complaining about the .so files, since they are all in `Assets/Plugins/Libfreenect2/Linux` and it must find them if it gets past `if (Device.Count > 0)` Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/Libfreenect2/Linux/libfreenect2c.so Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/Libfreenect2/Linux/libfreenect2c.so Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/Libfreenect2/Linux/libfreenect2c.so Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/Libfreenect2/Linux/libfreenect2c.so /home/builduser/buildslave/unity/build/Editor/Platform/Linux/UndoPlatformDependent.cpp:SetUndoMenuNamePlatformDependent [Info] [Freenect2Impl] enumerating devices... [Info] [Freenect2Impl] 14 usb devices connected [Info] [Freenect2Impl] found valid Kinect v2 @4:13 with serial 006147365347 [Info] [Freenect2Impl] found 1 devices Found device UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object) UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[]) UnityEngine.Logger:Log(LogType, Object) UnityEngine.Debug:Log(Object) KinectTwoDepthSource:InitDepthSource() (at Assets/Script/Kinect/KinectTwoDepthSource.cs:85) KinectManager2:Start() (at Assets/Script/Kinect/KinectManager2.cs:30) (Filename: Assets/Script/Kinect/KinectTwoDepthSource.cs Line: 85) Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/Libfreenect2/Linux/libfreenect2c.so Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/Libfreenect2/Linux/libfreenect2c.so Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/Libfreenect2/Linux/libfreenect2c.so Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/Libfreenect2/Linux/libfreenect2c.so [Info] [Freenect2DeviceImpl] opening... [Info] [Freenect2DeviceImpl] transfer pool sizes rgb: 20*16384 ir: 60*8*33792 [Info] [Freenect2DeviceImpl] opened Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/x86_64/libfreenect.so Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/x86_64/libfreenect.so Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/x86_64/libfreenect.so Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/x86_64/libfreenect.so Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/x86_64/libfreenect.so Fallback handler could not load library /home/adminz/Downloads/unity-editor-2017.2.0f3/Editor/Data/Mono/lib/libAssets/Plugins/x86_64/libfreenect.so The specified identifier (BoxDimensions) does not exists. please use Exists () to check for existent before calling Load. returning the default(T) instance. UnityEngine.DebugLogHandler:Internal_Log(LogType, String, Object) UnityEngine.DebugLogHandler:LogFormat(LogType, Object, String, Object[]) UnityEngine.Logger:LogFormat(LogType, String, Object[]) UnityEngine.Debug:LogWarningFormat(String, Object[]) BayatGames.SaveGameFree.SaveGame:Load(String, String, Boolean, String, ISaveGameSerializer, ISaveGameEncoder, Encoding, SaveGamePath) (at Assets/BayatGames/SaveGameFree/Scripts/SaveGame.cs:624) BayatGames.SaveGameFree.SaveGame:Load(String, String) (at Assets/BayatGames/SaveGameFree/Scripts/SaveGame.cs:439) CalibrationManager:Start() (at Assets/Script/Calibration/CalibrationManager.cs:146) (Filename: Assets/BayatGames/SaveGameFree/Scripts/SaveGame.cs Line: 624) InvalidCastException: Specified cast is not valid. at CalibrationManager.InitTextureDisplay () [0x000d6] in /home/adminz/AR-Sandbox-master/Assets/Script/Calibration/CalibrationManager.cs:256 at CalibrationManager.Start () [0x00653] in /home/adminz/AR-Sandbox-master/Assets/Script/Calibration/CalibrationManager.cs:233 (Filename: Assets/Script/Calibration/CalibrationManager.cs Line: 256) allocation 0x0xc000000000000000 already registered @ /home/builduser/buildslave/unity/build/Runtime/GfxDevice/opengles/DataBuffersGLES.cpp:l234 size 24000; now calling from /home/builduser/buildslave/unity/build/Runtime/GfxDevice/opengles/DataBuffersGLES.cpp:l234 size 3000? (Filename: /home/builduser/buildslave/unity/build/Runtime/Allocator/MemoryManager.cpp Line: 1464) Receiving unhandled NULL exception #0 0x007fb6d22aeac0 in funlockfile #1 0x007ffeb1f58920 in _nv042glcore #2 0x007ffeb1f58960 in _nv042glcore #3 0x007ffeb1f58a70 in _nv023glcore #4 0x007ffeb1f58ab0 in GfxDeviceGLES::DrawBufferRanges(GfxBuffer*, VertexStreamSource const*, int, DrawBuffersRange const*, int, VertexDeclaration*, ShaderChannelMask, unsigned long, bool) #5 0x007ffeb1f58b80 in GfxDeviceGLES::DrawBuffers(GfxBuffer*, VertexStreamSource const*, int, DrawBuffersRange const*, int, VertexDeclaration*, ShaderChannelMask) #6 0x007ffeb1f58c00 in UI::Canvas::DrawRawMesh(UI::Batch&, GfxBuffer*, GfxBuffer*) #7 0x007ffeb1f58c90 in UI::Canvas::RenderOverlays() #8 0x007ffeb1f58ce0 in UI::CanvasManager::RenderOverlays(int) #9 0x007ffeb1f58d30 in RepaintController::RenderGameViewCameras(RenderTexture*, int, RectT const&, Vector2f const&, bool) #10 0x007ffeb1f58e30 in EditorGUIUtility_CUSTOM_INTERNAL_CALL_RenderGameViewCamerasInternal(MonoObject*, int, RectT const&, Vector2fIcall const&, unsigned char) #11 0x007ffeb1f58e90 in (Unknown) #12 0x007ffeb1f58ea0 in (Unknown) #13 0x007ffeb1f58eb0 in mono_get_jit_info_from_method #14 0x007ffeb1f597c0 in mono_g_hash_table_print_stats #15 0x007ffeb1f597f0 in mono_runtime_run_main #16 0x007ffeb1f598a0 in mono_unity_register_path_remapper #17 0x007ffeb1f59970 in (Unknown) #18 0x007ffeb1f59980 in (Unknown) #19 0x007ffeb1f59990 in (Unknown) Launching bug reporter [Unity Package Manager (Upm)] - Application terminated due to HTTP connection being closed on the other end. [1]: https://github.com/OpenKinect/libfreenect2 [2]: https://github.com/thomiel/freenect2.net

Viewing all articles
Browse latest Browse all 376

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>