Hi Heresy,
Thanks so much for the idea but i am having problems with this
approach as well. This is what i did in the Openni User Tracker.
nRetVal = g_Context.FindExistingNode(XN_NODE_TYPE_DEPTH,
g_DepthGenerator);
CHECK_RC(nRetVal, "Find depth generator");
nRetVal =
g_Context.CreateMockNodeBasedOn(g_DepthGenerator,"MockDepth",g_mockdepth);
//nRetVal =
g_mockdepth.CreateBasedOn(g_DepthGenerator,"MockDepth"); // I also
tried this but did not work either
CHECK_RC(nRetVal, "Create mock depth node");
xn::Query xQuery;
xQuery.AddNeededNode("MockDepth");
// Adding the Skeletal and Pose detection capabilities
xQuery.AddSupportedCapability(XN_CAPABILITY_SKELETON);
xQuery.AddSupportedCapability(XN_CAPABILITY_POSE_DETECTION);
nRetVal = g_Context.FindExistingNode(XN_NODE_TYPE_USER,
g_UserGenerator);
if (nRetVal != XN_STATUS_OK) {
nRetVal = g_UserGenerator.Create(g_Context,&xQuery);
CHECK_RC(nRetVal, "Find user generator");
}
This is what is done in the while loop
{
g_Context.WaitAndUpdateAll();
g_DepthGenerator.GetMetaData(depthMD);
nRetVal = depthMD.MakeDataWritable();
//transformDepthMD(depthMD); // we could use this to modify the
depth map but for the time being i have commented it out
nRetVal = g_mockdepth.SetData(depthMD);
.....
.....
.....
.....
.....
.....
}
Problem:
Now the problem is there is no compilation error but in runtime there
is no output like nothing happens.
Do you have any idea what could be the problem thanks again :)