本文整理汇总了C++中Isometry3d::makeAffine方法的典型用法代码示例。如果您正苦于以下问题:C++ Isometry3d::makeAffine方法的具体用法?C++ Isometry3d::makeAffine怎么用?C++ Isometry3d::makeAffine使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Isometry3d
的用法示例。
在下文中一共展示了Isometry3d::makeAffine方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: DecodePose
Eigen::Isometry3d DecodePose(const bot_core::position_3d_t& msg) {
Isometry3d ret;
ret.translation() = DecodeVector3d(msg.translation);
auto quaternion = DecodeQuaternion(msg.rotation);
ret.linear() = drake::math::quat2rotmat(quaternion);
ret.makeAffine();
return ret;
}
示例2: jointTransform
Isometry3d PrismaticJoint::jointTransform(double* const q) const
{
Isometry3d ret;
ret.linear().setIdentity();
ret.translation() = q[0] * translation_axis;
ret.makeAffine();
return ret;
}
示例3: jointTransform
Isometry3d RollPitchYawFloatingJoint::jointTransform(const Eigen::Ref<const VectorXd>& q) const
{
Isometry3d ret;
auto pos = q.middleRows<SPACE_DIMENSION>(0);
auto rpy = q.middleRows<RPY_SIZE>(SPACE_DIMENSION);
ret.linear() = rpy2rotmat(rpy);
ret.translation() = pos;
ret.makeAffine();
return ret;
}
示例4: jointTransform
Isometry3d RollPitchYawFloatingJoint::jointTransform(double* const q) const
{
Isometry3d ret;
Map<Vector3d> pos(&q[0]);
Map<Vector3d> rpy(&q[3]);
ret.linear() = rpy2rotmat(rpy);
ret.translation() = pos;
ret.makeAffine();
return ret;
}
示例5: updateBodyNodes
void CollisionInterface::updateBodyNodes() {
int numNodes = mNodeMap.size();
for (std::map<BodyNode*, RigidBody*>::iterator it = mNodeMap.begin(); it != mNodeMap.end(); ++it) {
BodyNode *bn = it->first;
RigidBody *rb = it->second;
if (bn->getSkeleton()->getName() == "pinata")
continue;
Isometry3d W;
W.setIdentity();
W.linear() = rb->mOrientation;
W.translation() = rb->mPosition;
W.makeAffine();
bn->getSkeleton()->getJoint("freeJoint")->setTransformFromParentBodyNode(W);
//bn->updateTransform();
bn->getSkeleton()->computeForwardKinematics(true, false, false);
}
}