-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bugfix: Resolving Inertial Pose in Collision::CalculateInertial()
#1317
Bugfix: Resolving Inertial Pose in Collision::CalculateInertial()
#1317
Conversation
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
…phere Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
…for each collision Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
…o Mesh::MassMatrix Signed-off-by: Jasmeet Singh <[email protected]>
…ulator callback Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
…rameter Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
Signed-off-by: Jasmeet Singh <[email protected]>
src/Collision.cc
Outdated
@@ -287,7 +294,7 @@ void Collision::CalculateInertial( | |||
// Else resolve collision pose in Link Frame and then set as inertial pose | |||
if (this->dataPtr->poseRelativeTo.empty()) | |||
{ | |||
_inertial.SetPose(this->dataPtr->pose); | |||
_inertial.SetPose(_inertial.Pose() * this->dataPtr->pose); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using notation from http://sdformat.org/tutorials?tut=specify_pose&cat=specification&
X_LI
: Pose of the inertial I
relative to the link L
.
X_LC
: Pose of the collision relative to L
X_CG
: Pose of the inertial returned by the auto MOI calculator, which we take as being relative to the collision
Since we want _inertial
to be in frame L
, we would want
X_LG = X_LC * L_CG and
X_LG = X_LI`.
So, I think the terms are swapped. What do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh yeah that makes sense. I have swapped the terms in ca09b95
Signed-off-by: Jasmeet Singh <[email protected]>
Codecov Report
@@ Coverage Diff @@
## sdf14 #1317 +/- ##
=======================================
Coverage 87.47% 87.47%
=======================================
Files 134 134
Lines 17751 17751
=======================================
Hits 15528 15528
Misses 2223 2223
|
…Inertial() Signed-off-by: Jasmeet Singh <[email protected]>
Collision::CalculateInertial()
Collision::CalculateInertial()
🦟 Bug fix
Summary
This PR fixes the resolving of inertial pose in
Collision::CalculateInertial()
by adding the calculated inertial pose returned fromGeometry::CalculateInertial()
to the pose of the collision.Also shifted the
this->dataPtr->sdf
based check for loading the<auto_inertia_params>
element fromCollision::CalculateInertial()
toCollision::Load()
. This would allow users to programmatically create collisions and call CalculateInertial() function on them.Checklist
codecheck
passed (See contributing)Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining
Signed-off-by
messages.