Skip to content
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

Cherry-pick #312, #316 to master #339

Merged
merged 2 commits into from
Aug 18, 2020

Conversation

scpeters
Copy link
Member

This is a forward-port via cherry-pick of #312 and #316 from sdf10. Use rebase and merge if CI is clean.

…#312)

* Normalize joint axis xyz vector when parsing from SDFormat

Signed-off-by: Addisu Z. Taddese <addisu@openrobotics.org>

Co-authored-by: Steve Peters <scpeters@openrobotics.org>
@scpeters scpeters requested a review from azeey August 17, 2020 20:40
@codecov-commenter
Copy link

Codecov Report

Merging #339 into master will decrease coverage by 0.21%.
The diff coverage is 71.21%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #339      +/-   ##
==========================================
- Coverage   87.59%   87.38%   -0.22%     
==========================================
  Files          60       60              
  Lines        9215     9319     +104     
==========================================
+ Hits         8072     8143      +71     
- Misses       1143     1176      +33     
Impacted Files Coverage Δ
src/parser.cc 78.88% <50.00%> (+0.02%) ⬆️
src/FrameSemantics.cc 77.30% <68.18%> (-1.06%) ⬇️
src/Model.cc 85.35% <69.81%> (-3.09%) ⬇️
src/JointAxis.cc 94.15% <100.00%> (+0.11%) ⬆️
src/SemanticPose.cc 100.00% <100.00%> (ø)
src/World.cc 93.12% <100.00%> (+0.05%) ⬆️
include/sdf/Types.hh 100.00% <0.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4582b72...e2db237. Read the comment docs.

@scpeters
Copy link
Member Author

CI is happy after updating an expected console message in e2db237. I'll rebase and merge now

@scpeters
Copy link
Member Author

actually I'm going to squash e2db237 into f4fe589 and then merge

Nested model elements (`//model/model`) are currently supported in the
SDFormat 1.7 spec, but are not supported by the DOM API or frame
semantics operations in libsdformat 9.2.
Per Amendment 1 of the SDFormat 1.7 proposal
(sdformat.org/tutorials?tut=pose_frame_semantics_proposal#amendment-1-directly-nested-models),
this PR adds support for nested models in the DOM API and frame
semantics (fixing gazebosim#283) through three steps:

* adding `Model::Model*` methods for accessing nested models via
  the DOM API (047ec96)
* loading nested models in `Model::Load` (b57fea2, step 3 of model parsing
  stages (sdformat.org/tutorials?tut=pose_frame_semantics_proposal#1-model))
* supporting nested models (`//model/model`) in frame semantics as
  opaque frames to match how models in the world scope (`//world/model`)
  are treated (85e0b4f, steps 6-9 of model parsing stages
  (sdformat.org/tutorials?tut=pose_frame_semantics_proposal#1-model))

The first two steps are straightforward, while the 3rd step adds new behavior.
This behavior is added to `libsdformat9` because it is compatible with the
SDFormat 1.7 spec (which supports nested models) and makes the treatment
of models more consistent with regard to frame semantics.
In libsdformat 9.2.0, a `//world/model` supports frame semantics: they have
frames that can be referenced by name with `//pose/@relative_to` and
`//world/frame/@attached_to` values can resolve to a `//world/model`.
This extends that same behavior to nested `//model/model` elements;
they now have their own frames in the frame and pose graphs, and a
`//model/frame` is permitted to attach to a model.

This does not add support for referencing elements within a model via
the `::` syntax in the frame semantics or DOM APIs.
That will be added in SDFormat 1.8 (see gazebosim#293).

An expected console message was updated in a test while
merging forward to libsdformat11.

Signed-off-by: Steve Peters <scpeters@openrobotics.org>
@scpeters
Copy link
Member Author

CI is happy again; I'm going to rebase and merge

@scpeters scpeters merged commit 706f867 into gazebosim:master Aug 18, 2020
@scpeters scpeters deleted the pick_312_316_master branch August 18, 2020 00:00
@dirk-thomas
Copy link
Contributor

@scpeters This pull request seem to have introduced the following compiler warnings: https://build.osrfoundation.org/job/ignition_launch-ci-master-bionic-amd64/10/

[Discovered during osrf/buildfarmer#84]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants