MCPcopy Create free account
hub / github.com/OpenNI/OpenNI / SetIntProperty

Method SetIntProperty

Source/Modules/nimMockNodes/MockGenerator.cpp:82–118  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

80}
81
82XnStatus MockGenerator::SetIntProperty(const XnChar* strName, XnUInt64 nValue)
83{
84 XnStatus nRetVal = XN_STATUS_OK;
85
86 if (strcmp(strName, XN_PROP_IS_GENERATING) == 0)
87 {
88 SetGenerating((XnBool)nValue);
89 }
90 else if (strcmp(strName, XN_PROP_TIMESTAMP) == 0)
91 {
92 m_data[m_nNextDataIdx].nTimeStamp = nValue;
93 }
94 else if (strcmp(strName, XN_PROP_FRAME_ID) == 0)
95 {
96 m_data[m_nNextDataIdx].nFrameID = (XnUInt32)nValue;
97 }
98 else if (strcmp(strName, XN_CAPABILITY_MIRROR) == 0)
99 {
100 m_bMirrorCap = (XnBool)nValue;
101 }
102 else if (strcmp(strName, XN_CAPABILITY_FRAME_SYNC) == 0)
103 {
104 m_bFrameSyncCap = (XnBool)nValue;
105 }
106 else if (strcmp(strName, XN_PROP_MIRROR) == 0)
107 {
108 nRetVal = SetMirror((XnBool)nValue);
109 XN_IS_STATUS_OK(nRetVal);
110 }
111 //TODO: Check for alternative view point cap, framesync cap
112 else
113 {
114 return MockProductionNode::SetIntProperty(strName, nValue);
115 }
116
117 return XN_STATUS_OK;
118}
119
120XnStatus MockGenerator::SetStringProperty(const XnChar* strName, const XnChar* strValue)
121{

Callers 3

xnSetIntPropertyFunction · 0.45
ConfigureGeneratorsFunction · 0.45
mainFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected