-
Notifications
You must be signed in to change notification settings - Fork 293
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
3D plot plugin system #332
Conversation
Signed-off-by: Lucas Fernando <lucas.costa@ee.ufcg.edu.br>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The file structure is looking good. I think the only thing missing is to add the plugin to the list, because right now it's not being compiled:
diff --git a/src/systems/CMakeLists.txt b/src/systems/CMakeLists.txt
index ab085ca8..89cf2333 100644
--- a/src/systems/CMakeLists.txt
+++ b/src/systems/CMakeLists.txt
@@ -84,6 +84,7 @@ add_subdirectory(joint_controller)
add_subdirectory(joint_position_controller)
add_subdirectory(joint_state_publisher)
add_subdirectory(lift_drag)
+add_subdirectory(link_plot3d_plugin)
add_subdirectory(log)
add_subdirectory(log_video_recorder)
add_subdirectory(logical_camera)
} | ||
|
||
// Get params from SDF | ||
this->dataPtr->jointName = _sdf->Get<std::string>("joint_name"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I recommend getting link_name
s instead. The joints by themselves are not very helpful to find points in the 3D space.
You could also support multiple links and expose other options like an offset from the link's origin and the material color. See what it looked like on Gazebo classic. Here, I recommend something like this:
<plugin name='3dplot' filename='LinkPlot3DPlugin'>
<!-- Update at 10 Hz -->
<frequency>10</frequency>
<!-- Upper link plot -->
<plot>
<link>double_pendulum_with_base::upper_link</link>
<!-- Point 1m in +Z axis in link frame -->
<offset>0 0 1</offset>
<color>1 0 0</color>
</plot>
<!-- Upper link plot -->
<plot>
<link>double_pendulum_with_base::lower_link</link>
<!-- Point 1m in +Z axis in link frame -->
<offset>0 0 1</offset>
<color>0 0 1</color>
</plot>
</plugin>
- Using an
offset
vector instead ofpose
because we don't need rotation - Using
color
instead ofmaterial
because Ignition doesn't support Ogre materials
Let me know if you have any questions!
Hi @luccosta , are you planning to keep working on this PR? Anything we can help with? |
Hi @chapulina, I want to apologize for the absence, and I will return working on this PR in this weekend. :) |
No worries, @luccosta, I was just checking in. Thanks! |
This PR is part of this issue #231 .
Initial upload with WIP. Really just the draft while understanding the Ignition structure.
Signed-off-by: Lucas Fernando lucas.costa@ee.ufcg.edu.br