You can change AlternateViewPointCap or MirrorCap when playing

I work with some data that another person recorded using the OpenNI recorder module. Unfortunately, they accidentally set the mirror feature during their recording, so I have a few problems. 1. Mirroring depth using MirrorCap and 2. Aligning depth using rgb using AlternateViewPointCap. I tried to access these features from the depth of the node as follows:

xn::Context ni_context;
xn::Player player;
xn::DepthGenerator g_depth;
xn::ImageGenerator g_image;
ni_context.Init();
ni_context.OpenFileRecording(oni_filename, player);
ni_context.FindExistingNode(XN_NODE_TYPE_DEPTH, g_depth);
ni_context.FindExistingNode(XN_NODE_TYPE_IMAGE, g_image); 
g_depth.GetMirrorCap().SetMirror(false);
g_depth.GetAlternativeViewPointCap().SetViewPoint(g_image);

However, this did not work. Even after I set the mirror to false, the IsMirrored () command on g_depth still returns as true, and the alternate pointer does not change the depth map that I get from the generator.

I also tried to do this through the node layout:

xn::MockDepthGenerator m_depth;
m_depth.CreateBasedOn(g_depth);
m_depth.GetMirrorCap().SetMirror(false);
m_depth.GetAlternativeViewPointCap().SetViewPoint(g_image);
xn::DepthMetaData temp;
g_depth.GetMetaData(temp);
m_depth.SetMetaData(temp);

, m_depth. , , , . , .

- node , SetMetaData. OpenCV, RGB , 4 . rgb, . , - , , , .

+1
2

, OpenNI, -, Primesense SoC - , SoC → RGB . , , - , . .

Primesense, , (XnDeviceSensorV2/Registration.cpp), , , OpenNI, . , , - ( , , . , Avin2 SensorKinect).

, FYI-mock - NiRecordSynthetic , .

+1

Roee, Kinect OpenNI, : , . , ZeroPlanePixelSize ZeroPlaneDistance , ( ).

XnUInt64 zpd;
XnDouble zpps;
g_DepthGenerator.GetIntProperty("ZPD", zpd);
g_DepthGenerator.GetRealProperty("ZPPS", zpps);

, , kinect, Avin2Sensor , RGB.

0

All Articles