I'm trying to extract the planes from a sceneperception instance to determine if an actual face or a picture is being detected. However, I'm running into an issue where I enable scene perception. This muse be done before the sense manager is initialized. However, when I try to do that, I get a nullreferenceexception. Enabling scene preception after initializing the sensemanager removes the exception but prevents me from doing face recognition.
senseManager = PXCMSenseManager.CreateInstance();
// Enable the color stream
senseManager.EnableStream(PXCMCapture.StreamType.STREAM_TYPE_COLOR, 640, 480, 30);
senseManager.EnableStream(PXCMCapture.StreamType.STREAM_TYPE_DEPTH, 640, 480, 30);
//Code for face recognition initialization
senseManager.Init(); //Throws an error
Any help to resolve this issue would be appreciated! Thank you!