Skip to content

Commit

Permalink
Issue #215
Browse files Browse the repository at this point in the history
Fixed incorrect reading of the orientation from the visual mesh. Instead use the rotation of the afRigidBody
  • Loading branch information
adnanmunawar committed Sep 26, 2023
1 parent 6a23e19 commit 43baf0a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ambf_plugins/core/ros_comm_plugin/ObjectCommPlugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -736,7 +736,7 @@ void afObjectCommunicationPlugin::rigidBodyUpdateState(afRigidBodyPtr afRBPtr, d
setTimeStamps(m_objectPtr->m_afWorld->getWallTime(), m_objectPtr->m_afWorld->getSimulationTime(), m_objectPtr->getCurrentTimeStamp());
btRigidBody* btRBPtr = afRBPtr->m_bulletRigidBody;
cQuaternion q;
q.fromRotMat(afRBPtr->m_visualMesh->getLocalRot());
q.fromRotMat(afRBPtr->getLocalRot());

// Update the Pose
cVector3d localPos = afRBPtr->getLocalPos();
Expand Down

0 comments on commit 43baf0a

Please sign in to comment.