Ask Your Question

Revision history [back]

The way I made it work is by specifying the full path to the nodelet manager when loading a nodelet from a namespace

for example

<node pkg="nodelet" type="nodelet" name="my_nodelet_manager" args="manager" cwd="node" output="screen" />

<group ns="camera1">
  <node node pkg="nodelet" type="nodelet" name="my_nodelet" args="load pkg_name/nodelet_name /my_nodelet_manager" />
</group>

adding the slash in front of my_nodelet_manager in the nodelet loading command will make sure it won't look for the nodelet manager inside the namespace "camera1" but will try finding it using its global path. This also works with subnamespaces. If you want your camera and also the nodelet manager to be inside the slam namespace just do

<group ns="slam">
    <node pkg="nodelet" type="nodelet" name="my_nodelet_manager" args="manager" cwd="node" output="screen" />
    <group ns="camera1">
      <node node pkg="nodelet" type="nodelet" name="my_nodelet"
       args="load pkg_name/nodelet_name /slam/my_nodelet_manager" />
    </group>

</group>