OpenNI in WPF via EmguCV
Another quick demo showing the Kinect’s IR stream running in a WPF app. This time the image is created as an EmguCV (OpenCV-C#) Image Gray, ushort. As you can see the quality is greatly enhanced in comparison to the last attempt. If you look closely you can make out the IR dot markers and also the grid pattern.
As a bonus it’s ready for some Image manipulation via EmguCV too.
Sourcecode is available here.
By default the example is running the standard WPF code to get is to show the EmguCV image as shown above in MainWindow.xmal.cs comment out:
imgVideo.Source = _kinect.IrImageSource;
and replace with:
imgVideo.Source = ToBitmapSource(irGrayCVImage);
Kudos must go to Vangos Pterneas who’s excelent work provided most of the groundwork for this demo.