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

Method RemovePlayerNodeInfo

Source/Modules/nimRecorder/PlayerNode.cpp:808–834  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

806}
807
808XnStatus PlayerNode::RemovePlayerNodeInfo(XnUInt32 nNodeID)
809{
810 XnStatus nRetVal = XN_STATUS_OK;
811
812 PlayerNodeInfo* pPlayerNodeInfo = GetPlayerNodeInfo(nNodeID);
813 XN_VALIDATE_PTR(pPlayerNodeInfo, XN_STATUS_CORRUPT_FILE);
814 if (pPlayerNodeInfo->bValid)
815 {
816 if (m_pNodeNotifications != NULL)
817 {
818 nRetVal = m_pNodeNotifications->OnNodeRemoved(m_pNotificationsCookie, pPlayerNodeInfo->strName);
819 if (nRetVal != XN_STATUS_OK)
820 {
821 return nRetVal;
822 }
823 }
824
825 if (pPlayerNodeInfo->codec.IsValid())
826 {
827 xnRemoveNeededNode(GetSelfNodeHandle(), pPlayerNodeInfo->codec);
828 pPlayerNodeInfo->codec.Release();
829 }
830 pPlayerNodeInfo->Reset(); //Now it's not valid anymore
831 }
832
833 return XN_STATUS_OK;
834}
835
836XnStatus PlayerNode::HandleNodeAddedImpl(XnUInt32 nNodeID, XnProductionNodeType type, const XnChar* strName, XnCodecID compression, XnUInt32 nNumberOfFrames, XnUInt64 /*nMinTimestamp*/, XnUInt64 nMaxTimestamp)
837{

Callers

nothing calls this directly

Calls 5

xnRemoveNeededNodeFunction · 0.85
OnNodeRemovedMethod · 0.45
IsValidMethod · 0.45
ReleaseMethod · 0.45
ResetMethod · 0.45

Tested by

no test coverage detected