PickNikRobotics / rviz_visual_tools

C++ API wrapper for displaying shapes and meshes in Rviz
771 stars 243 forks source link

Default constructor is not nodelet friendly #49

Closed shaun-edwards closed 5 years ago

shaun-edwards commented 7 years ago

The rviz_visual_tools constructor does not allow the node handle to be passed into the class, rather it initializes the node handle nh_("~") here. When using nodelets, this results in topics being published under an anonymous namespace (which changes every time the nodelet is launched).

I believe the appropriate fix is to allow the node handle to be passed in on construction. When using nodelets, the user should pass in getNodeHandle().

shaun-edwards commented 7 years ago

I'm happy to submit a PR to address this, if indeed I am correct and it is an issue.

Would you accept a PR against indigo?

davetcoleman commented 7 years ago

I'd accept it to indigo. Make sure the new constructor has a default value for nh if the user does not specify. We'll then cherry-pick it to J/K

davetcoleman commented 6 years ago

Any progress on this or should this issue be closed?

shaun-edwards commented 6 years ago

I plan to get back to this in the new year, but no longer on indigo. @geoffreychiou...do you want to have a look at this?

geoffreychiou commented 6 years ago

@shaun-edwards On kinetic?

shaun-edwards commented 6 years ago

Kinetic...it looks like this is the latest LTS

VictorLamoine commented 5 years ago

@davetcoleman you forgot to close this issue