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

Set near/far camera clipping distance #309

Merged
merged 5 commits into from
Nov 3, 2021
Merged

Conversation

jennuine
Copy link
Contributor

@jennuine jennuine commented Nov 3, 2021

🎉 New feature

Closes #308

Summary

Added ability to configure the user camera's near/far clipping distance in the MinimalScene plugin from xml. If none is set, the default near 0.01 and far 1000 is used.

Test it

Add <camera_clip> to the MinimalScene plugin config. For example,

<camera_clip>
  <near>0.1</near>
  <far>5000</far>
</camera_clip>

to minimal_scene.sdf

Checklist

  • Signed all commits for DCO
  • Added tests
  • Added example and/or tutorial
  • Updated documentation (as needed)
  • Updated migration guide (as needed)
  • 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

Signed-off-by: Jenn Nguyen <jenn@openrobotics.org>
@jennuine jennuine added the 🏯 fortress Ignition Fortress label Nov 3, 2021
@jennuine jennuine self-assigned this Nov 3, 2021
@github-actions github-actions bot added the 🌱 garden Ignition Garden label Nov 3, 2021
Signed-off-by: Jenn Nguyen <jenn@openrobotics.org>
@codecov
Copy link

codecov bot commented Nov 3, 2021

Codecov Report

Merging #309 (06b7c18) into ign-gui6 (443bfac) will increase coverage by 0.07%.
The diff coverage is 85.71%.

Impacted file tree graph

@@             Coverage Diff              @@
##           ign-gui6     #309      +/-   ##
============================================
+ Coverage     65.53%   65.60%   +0.07%     
============================================
  Files            32       32              
  Lines          4694     4722      +28     
============================================
+ Hits           3076     3098      +22     
- Misses         1618     1624       +6     
Impacted Files Coverage Δ
src/plugins/minimal_scene/MinimalScene.cc 60.92% <85.71%> (+1.35%) ⬆️
src/plugins/scene3d/Scene3D.cc 48.83% <0.00%> (-0.26%) ⬇️

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 443bfac...06b7c18. Read the comment docs.

@scpeters
Copy link
Member

scpeters commented Nov 3, 2021

windows CI seems unhappy

Signed-off-by: Jenn Nguyen <jenn@openrobotics.org>
src/plugins/minimal_scene/MinimalScene.cc Outdated Show resolved Hide resolved
src/plugins/minimal_scene/MinimalScene.cc Outdated Show resolved Hide resolved
Copy link
Contributor

@ahcorde ahcorde left a comment

Choose a reason for hiding this comment

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

LGTM with the @scpeters comments addressed

Signed-off-by: Jenn Nguyen <jenn@openrobotics.org>
Signed-off-by: Jenn Nguyen <jenn@openrobotics.org>
@jennuine jennuine merged commit a8e18ab into ign-gui6 Nov 3, 2021
@jennuine jennuine deleted the jennuine/camera_clip branch November 3, 2021 22:01
scpeters added a commit to scpeters/ign-gazebo that referenced this pull request Nov 4, 2021
This adds example camera_clip parameters to the
MinimalScene plugin in the example world file
minimal_scene.sdf

These parameters were added in gazebosim/gz-gui#309

Signed-off-by: Steve Peters <scpeters@openrobotics.org>
scpeters added a commit to gazebosim/gz-sim that referenced this pull request Nov 5, 2021
This adds example camera_clip parameters to the
MinimalScene plugin in the example world file
minimal_scene.sdf

These parameters were added in gazebosim/gz-gui#309

Also increase timeout for examples build test

Signed-off-by: Steve Peters <scpeters@openrobotics.org>
WilliamLewww pushed a commit to WilliamLewww/ign-gazebo that referenced this pull request Dec 7, 2021
This adds example camera_clip parameters to the
MinimalScene plugin in the example world file
minimal_scene.sdf

These parameters were added in gazebosim/gz-gui#309

Also increase timeout for examples build test

Signed-off-by: Steve Peters <scpeters@openrobotics.org>
Signed-off-by: William Lew <WilliamMilesLew@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏯 fortress Ignition Fortress 🌱 garden Ignition Garden
Projects
None yet
Development

Successfully merging this pull request may close these issues.

MinimalScene: configurable near/far clip planes
4 participants