Added std::optional MassMatrix() functions for Box, Cylinder & Sphere#538
Merged
quarkytale merged 6 commits intogazebosim:gz-math7from Jun 30, 2023
Merged
Conversation
Signed-off-by: Jasmeet Singh <jasmeet0915@gmail.com>
… bindings Signed-off-by: Jasmeet Singh <jasmeet0915@gmail.com>
Signed-off-by: Jasmeet Singh <jasmeet0915@gmail.com>
…phere Signed-off-by: Jasmeet Singh <jasmeet0915@gmail.com>
ahcorde
requested changes
Jun 27, 2023
Contributor
ahcorde
left a comment
There was a problem hiding this comment.
can you add the same test in Python ?
…linder Signed-off-by: Jasmeet Singh <jasmeet0915@gmail.com>
Contributor
Author
Codecov Report
@@ Coverage Diff @@
## gz-math7 #538 +/- ##
============================================
- Coverage 99.74% 99.70% -0.05%
============================================
Files 77 77
Lines 7032 7049 +17
============================================
+ Hits 7014 7028 +14
- Misses 18 21 +3
|
ahcorde
requested changes
Jun 28, 2023
Signed-off-by: Jasmeet Singh <jasmeet0915@gmail.com>
ahcorde
approved these changes
Jun 29, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🎉 New feature
Summary
The
Capsule.hhandEllipsoid.hhhaveMassMatrix()functions that take no parameters and return astd::optionalwhileBox.hh,Cylinder.hhandSphere.hhhaveMassMatrix()functions that have aboolreturn type and takegz::math::MassMatrix3dobject as a parameter.This PR corrects this non-uniformity of MassMatrix functions across different shapes by overloading the
MassMatrix()function in theBox,CylinderandSphereheaders to createstd::optional MassMatrix()functions with a signature similar to the ones inCapsuleorEllpisoidheaders.Checklist
codecheckpassed (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-bymessages.Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining
Signed-off-bymessages.