That depends on which node is publishing that topic. I guess it's openni_camera, openni2_camera or similar. These have a parameter called data_skip
, documented here: openni_camera. For example, if you set that param to 2, you'll get 10Hz instead of 30Hz (because the driver will skip 2 messages, then publish 1, then skip 2 and so on).
The advantage of this solution over using topic_tools/throttle is that this will happen inside the driver node, so you save the computational overhead caused by throttle. Assuming the throttle node runs on the same PC as the driver node, the throttle node has to memcpy all the data before throttling, which is about 300 MB/s for a Kinect or Xtion (for the point clouds). Also, you avoid the computational overhead of rectifying the images, computing a point cloud etc. for messages that are then thrown away. On a small system that's a considerable effort. Plus, all the topics (depth + rgb images, point clouds, ...) are throttled at once. Alternatively, you can reduce the resolution of the device using parameters.
The disadvantage of using data_skip
instead of throttle is that you reduce the data rate for all subscribers. If you used throttle instead, you could have some nodes on the local PC subscribing to the unthrottled topic, and only remote nodes on other PCs subscribing to the throttled topic (to save network bandwidth).