Skip to content

Commit

Permalink
enable to change output image/{compressed,camera_info} when remapped …
Browse files Browse the repository at this point in the history
…~output:=tmp
  • Loading branch information
k-okada committed Oct 17, 2021
1 parent 1b19390 commit 7bab20b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions jsk_perception/node_scripts/image_publisher.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,11 @@ def __init__(self):
dynamic_reconfigure.server.Server(
ImagePublisherConfig, self._cb_dyn_reconfig)
self.pub = rospy.Publisher('~output', Image, queue_size=1)
self.pub_compressed = rospy.Publisher('~output/compressed', CompressedImage, queue_size=1)
self.pub_compressed = rospy.Publisher('{}/compressed'.format(rospy.resolve_name('~output')), CompressedImage, queue_size=1)
self.publish_info = rospy.get_param('~publish_info', True)
if self.publish_info:
self.pub_info = rospy.Publisher(
'~output/camera_info', CameraInfo, queue_size=1)
'{}/camera_info'.format(rospy.resolve_name('~output')), CameraInfo, queue_size=1)
rate = rospy.get_param('~rate', 1.)
rospy.Timer(rospy.Duration(1. / rate), self.publish)

Expand Down

0 comments on commit 7bab20b

Please sign in to comment.