24 mPosition.reset(
new Eigen::Vector3d(0, 0, 0));
25 mOrientation.reset(
new Eigen::Quaternion<double>(1, 0, 0, 0));
31 if(!pObject.sampledPoses.size()){
32 std::cerr <<
"Got a AsrObject without poses." << std::endl;
37 mPosition.reset(
new Eigen::Vector3d(pObject.sampledPoses.front().pose.position.x,
38 pObject.sampledPoses.front().pose.position.y,
39 pObject.sampledPoses.front().pose.position.z));
42 mOrientation.reset(
new Eigen::Quaternion<double>(pObject.sampledPoses.front().pose.orientation.w,
43 pObject.sampledPoses.front().pose.orientation.x,
44 pObject.sampledPoses.front().pose.orientation.y,
45 pObject.sampledPoses.front().pose.orientation.z));
52 mPosition.reset(
new Eigen::Vector3d(pPose.position.x,
57 mOrientation.reset(
new Eigen::Quaternion<double>(pPose.orientation.w,
60 pPose.orientation.z));
63 Pose::Pose(
const boost::shared_ptr<SceneModel::Object> pObject)
76 pResult.reset(
new Pose());
81 pResult->mPosition.reset(
new Eigen::Vector3d(pFrame->mOrientation->toRotationMatrix().inverse() * (*
mPosition - *pFrame->mPosition)));
84 pResult->mOrientation.reset(
new Eigen::Quaternion<double>(*
mOrientation * pFrame->mOrientation->inverse()));
Eigen::Quaternion< double > getOrientation()
boost::shared_ptr< Eigen::Vector3d > mPosition
Eigen::Vector3d getPosition()
void convertPoseIntoFrame(const boost::shared_ptr< Pose > &pFrame, boost::shared_ptr< Pose > &pResult)
boost::shared_ptr< Eigen::Quaternion< double > > mOrientation