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

Add tutorial on migrating the Light class from gazebo classic #1931

Merged
merged 3 commits into from
Apr 17, 2023

Conversation

iche033
Copy link
Contributor

@iche033 iche033 commented Mar 15, 2023

🎉 New feature

Part of #325

Summary

Add migration tutorial for Gazebo classic's Light class.

Checklist

  • Signed all commits for DCO
  • Added tests
  • Added example and/or tutorial
  • Updated documentation (as needed)
  • Updated migration guide (as needed)
  • Consider updating Python bindings (if the library has them)
  • codecheck passed (See contributing)
  • All tests passed (See test coverage)
  • While waiting for a review on your PR, please help review another open pull request to support the maintainers

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.

@iche033 iche033 requested a review from mjcarroll as a code owner March 15, 2023 21:40
@github-actions github-actions bot added the 🏯 fortress Ignition Fortress label Mar 15, 2023
@codecov
Copy link

codecov bot commented Mar 15, 2023

Codecov Report

Merging #1931 (29a4bfc) into ign-gazebo6 (89df3b7) will increase coverage by 0.32%.
The diff coverage is 91.82%.

❗ Current head 29a4bfc differs from pull request most recent head 20d0011. Consider uploading reports for the commit 20d0011 to get more accurate results

@@               Coverage Diff               @@
##           ign-gazebo6    #1931      +/-   ##
===============================================
+ Coverage        64.99%   65.31%   +0.32%     
===============================================
  Files              324      327       +3     
  Lines            26562    26878     +316     
===============================================
+ Hits             17264    17556     +292     
- Misses            9298     9322      +24     
Impacted Files Coverage Δ
src/rendering/RenderUtil.cc 39.97% <71.42%> (+0.26%) ⬆️
src/Sensor.cc 85.71% <85.71%> (ø)
src/Light.cc 93.11% <93.11%> (ø)
src/Actor.cc 94.33% <94.33%> (ø)
src/Joint.cc 97.10% <100.00%> (+0.10%) ⬆️

... and 1 file with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@azeey azeey requested a review from j-rivero March 20, 2023 18:26
Copy link
Contributor

@j-rivero j-rivero left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some fixes and comments.

* [ignition/gazebo/SdfEntityCreator.hh](https://gazebosim.org/api/gazebo/6/SdfEntityCreator_8hh.html)
* [ignition/gazebo/EntityComponentManager.hh](https://gazebosim.org/api/gazebo/6/classignition_1_1gazebo_1_1EntityComponentManager.html)

It's worth remembering that most of this functionality can be performed using
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we elaborate a bit on this? How should someone use the EntityComponentManager to access to the light functionality?

tutorials/migration_light_api.md Outdated Show resolved Hide resolved
tutorials/migration_light_api.md Outdated Show resolved Hide resolved
tutorials/migration_light_api.md Outdated Show resolved Hide resolved
tutorials/migration_light_api.md Outdated Show resolved Hide resolved
SetSpecularColor | `ignition::gazebo::Light::SetSpecularColor`
SetSpotFalloff | `ignition::gazebo::Light::SetSpotFalloff`
SetSpotInnerAngle | ignition::gazebo::Light::SetSpotInnerAngle`
SetSpotOuterAngle | ignition::gazebo::Light::SetSpotOuterAngle`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
SetSpotOuterAngle | ignition::gazebo::Light::SetSpotOuterAngle`
SetSpotOuterAngle | `ignition::gazebo::Light::SetSpotOuterAngle`

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed 4320596

tutorials/migration_light_api.md Outdated Show resolved Hide resolved
RemoveChildren | Not supported
SetParent | TODO
SetWorld | TODO

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume that is currently no possible to use a write-like method in Gazebo, is this correct? If so, we can mention it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep, added a note mentioning they are not implemented yet. 20d0011

tutorials/migration_light_api.md Show resolved Hide resolved
iche033 added 2 commits March 22, 2023 18:43
Signed-off-by: Ian Chen <[email protected]>
Signed-off-by: Ian Chen <[email protected]>
@iche033
Copy link
Contributor Author

iche033 commented Mar 22, 2023

thanks for the review! If the changes look fine, I'll apply them to my other tutorial PRs

@azeey azeey requested a review from j-rivero April 10, 2023 18:36
Copy link
Contributor

@j-rivero j-rivero left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @iche033 . Looks great!

@iche033 iche033 merged commit 8681482 into ign-gazebo6 Apr 17, 2023
@iche033 iche033 deleted the migration_light branch April 17, 2023 17:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏯 fortress Ignition Fortress
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants