none
Microsoft.Kinect.Wpf.Controls.DepthImageColorizerStrategy.ColorizeDepthPixels error from Kinect SDK RRS feed

  • General discussion

  • We are experiencing the following error intermittently in the Kinect SDK 2.0.141.19000. We are not able to catch the error and handle it as it seems to be in a Kinect component which is not invoked by our code. Any help would be greatly appreciated.

    Exception Info: System.IndexOutOfRangeException

    Stack:

       at Microsoft.Kinect.Wpf.Controls.DepthImageColorizerStrategy.ColorizeDepthPixels(Microsoft.Kinect.Wpf.Controls.IDepthImageColorizerParameters, UInt16[], Byte[], Byte[], Int32, Int32, Int32)

       at Microsoft.Kinect.Wpf.Controls.DepthImageProcessor.WriteToBitmap(Microsoft.Kinect.DepthFrame)

       at Microsoft.Kinect.Wpf.Controls.DepthImageProcessor.KinectSensorOnDepthFrameReady(System.Object, Microsoft.Kinect.MultiSourceFrameArrivedEventArgs)

       at ContextEventHandler`1[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].SendOrPostDelegate(System.Object)

       at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)

       at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)

       at System.Windows.Threading.DispatcherOperation.InvokeImpl()

       at System.Windows.Threading.DispatcherOperation.InvokeInSecurityContext(System.Object)

       at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)

       at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)

       at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)

       at System.Windows.Threading.DispatcherOperation.Invoke()

       at System.Windows.Threading.Dispatcher.ProcessQueue()

       at System.Windows.Threading.Dispatcher.WndProcHook(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)

       at MS.Win32.HwndWrapper.WndProc(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)

       at MS.Win32.HwndSubclass.DispatcherCallbackOperation(System.Object)

       at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)

       at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)

       at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(System.Windows.Threading.DispatcherPriority, System.TimeSpan, System.Delegate, System.Object, Int32)

       at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr, Int32, IntPtr, IntPtr)

       at MS.Win32.UnsafeNativeMethods.DispatchMessage(System.Windows.Interop.MSG ByRef)

       at System.Windows.Threading.Dispatcher.PushFrameImpl(System.Windows.Threading.DispatcherFrame)

       at System.Windows.Threading.Dispatcher.PushFrame(System.Windows.Threading.DispatcherFrame)

       at System.Windows.Threading.Dispatcher.Run()

       at System.Windows.Application.RunDispatcher(System.Object)

       at System.Windows.Application.RunInternal(System.Windows.Window)

       at System.Windows.Application.Run(System.Windows.Window)

       at System.Windows.Application.Run()


    Tuesday, January 20, 2015 3:20 PM

All replies

  • Thanks for the report, but for now, there isn't much that can be done in your code to prevent this as you said. From the callstack it looks like the user visualizer toolkit component. Without reproducing it locally, I don't know how the index is out of range, but I have reported this to the team for investigation.

    As for a workaround, you may opt to remove the user-viewer component and see if that will at least prevent the crash from occurring. You also may be able to create a try/catch block around the instance of creating the application to see if you can catch the exception and handle it safely. The alternative is to create a separate process that monitors the application and if it isn't running, creates a new instance(watchdog)


    Carmine Sirignano - MSFT

    Tuesday, January 20, 2015 6:57 PM
  • Is there any update on this issue?
    Wednesday, March 18, 2015 10:04 AM