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

Allow to move to model from Angle view plugin #1810

Merged
merged 2 commits into from
Nov 30, 2022

Conversation

ahcorde
Copy link
Contributor

@ahcorde ahcorde commented Nov 23, 2022

Signed-off-by: Alejandro Hernández Cordero [email protected]

🎉 New feature

Summary

Allow to move to model from Angle view plugin

move_to_object

Test

ign gazebo -v 4 shapes.sdf

Open view_angle plugin` and in other terminal:

ign service  -s /gui/move_to/model --reqtype ignition.msgs.GUICamera  --reptype ignition.msgs.Boolean -r 'name: "box", pose: {position: {z:5}, orientation: {x:0, y:0, z: -1, w:0}}, projection_type: "orbit"' --timeout 5000

You can change:

  • name: "box" with any of the models in the world
  • position: {z:5} Distance between the modela and the camera
  • orientation angle of the camera
  • projection_type can be "orbit" or "ortho"

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.

Signed-off-by: Alejandro Hernández Cordero <[email protected]>
@ahcorde ahcorde self-assigned this Nov 23, 2022
@github-actions github-actions bot added the 🏯 fortress Ignition Fortress label Nov 23, 2022
@ahcorde ahcorde marked this pull request as ready for review November 23, 2022 17:13
@iche033
Copy link
Contributor

iche033 commented Nov 23, 2022

since this just provides a service and no gui elements, maybe we can put this logic in the CameraTracking plugin?

@ahcorde
Copy link
Contributor Author

ahcorde commented Nov 24, 2022

@iche033 I'm using the gazebo-entity, it contains some gazebo related code, that's why I included this code there.

@azeey azeey requested a review from iche033 November 28, 2022 19:49
Copy link
Contributor

@iche033 iche033 left a comment

Choose a reason for hiding this comment

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

works for me. Just some minor comments

src/gui/plugins/view_angle/ViewAngle.cc Outdated Show resolved Hide resolved
src/gui/plugins/view_angle/ViewAngle.cc Show resolved Hide resolved
src/gui/plugins/view_angle/ViewAngle.cc Outdated Show resolved Hide resolved
Signed-off-by: Alejandro Hernández Cordero <[email protected]>
@ahcorde
Copy link
Contributor Author

ahcorde commented Nov 29, 2022

Thank you for the review @iche033, done here fd460c0

@ahcorde ahcorde requested a review from iche033 November 29, 2022 16:43
@ahcorde ahcorde merged commit 7ba7377 into ign-gazebo6 Nov 30, 2022
@ahcorde ahcorde deleted the ahcorde/6/view_angle/move_to_model branch November 30, 2022 17:29
@ahcorde ahcorde mentioned this pull request Nov 30, 2022
9 tasks
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