40 this->channelRefToObjectToWhichThisIsAttached = channelRefToObjectToWhichThisIsAttached;
41 channelRefIsValid =
true;
51 armarx::VariantPtr::dynamicCast(initialGlobalPoseOfObjectToWhichThisIsAttached)->setClass(
new armarx::MatrixFloat(globalPoseOfAtObj));
52 globalPoseOfObjectToWhichThisIsAttachedAtLocalizationStart =
new armarx::Variant();
53 armarx::VariantPtr::dynamicCast(globalPoseOfObjectToWhichThisIsAttachedAtLocalizationStart)->setClass(
new armarx::MatrixFloat(globalPoseOfAtObj));
60 if (channelRefIsValid)
65 armarx::LinkedPosePtr oldPoseGlobal = armarx::LinkedPosePtr::dynamicCast(poseAtLastLocalization)->toGlobal();
75 Eigen::Matrix4f trafoOfObjectToWhichThisIsAttached = globalPoseOfAtObj->toEigen() * initPoseOfAtObj.inverse();
79 Eigen::Matrix4f predictedPose = trafoOfObjectToWhichThisIsAttached * oldPoseGlobal->toEigen();
88 channelRefIsValid =
false;
89 ARMARX_ERROR_S <<
"The ChannelRef of the object to which this is attached is not valid (anymore). Did you release that object?";
92 return armarx::LinkedPosePtr::dynamicCast(poseAtLastLocalization);
99 if (channelRefIsValid)
106 this->poseAtLastLocalization = poseAtLastLocalization;
109 this->globalRobotPoseAtLastLocalization = globalRobotPoseAtLastLocalization;
111 initialGlobalPoseOfObjectToWhichThisIsAttached = armarx::VariantPtr::dynamicCast(globalPoseOfObjectToWhichThisIsAttachedAtLocalizationStart)->clone();
113 if (uncertaintyAtLastLocalization)
115 this->uncertaintyAtLastLocalization = uncertaintyAtLastLocalization;
121 channelRefIsValid =
false;
122 ARMARX_ERROR_S <<
"The ChannelRef of the object to which this is attached is not valid (anymore). Did you release that object?";
131 if (uncertaintyAtLastLocalization)
133 return uncertaintyAtLastLocalization;
150 armarx::VariantPtr::dynamicCast(globalPoseOfObjectToWhichThisIsAttachedAtLocalizationStart)->setClass(
new armarx::MatrixFloat(globalPoseOfAtObj->toEigen()));