resized_image_client.py
Go to the documentation of this file.
1 #!/usr/bin/env python
2 
3 import rospy
4 import dynamic_reconfigure.client
5 import time
6 
8  def __init__(self, node, x=0.1, y=0.1, mps=1.0):
9  self.client = dynamic_reconfigure.client.Client(node)
10  self.resize_scale_x = x
11  self.resize_scale_y = y
12  self.msg_par_second = mps
13 
14  def update(self):
15  params = { 'resize_scale_x' : self.resize_scale_x, 'resize_scale_y' : self.resize_scale_y, 'msg_par_second' : self.msg_par_second}
16  rospy.loginfo("update config \nresized_scale_x : %s \nresized_scale_y : %s \nmsg_par_second : %s", self.resize_scale_x, self.resize_scale_y, self.msg_par_second)
17  config = self.client.update_configuration(params)
18 
19 
20 if __name__ == '__main__':
21  rospy.init_node('resized_image_client_sample')
22  ric = ResizedImageClient('/head_resized')
23  while True:
24  ric.update()
25  time.sleep(1)
26 
def __init__(self, node, x=0.1, y=0.1, mps=1.0)


resized_image_transport
Author(s): Yohei Kakiuchi
autogenerated on Mon May 3 2021 03:03:39