_compute_effector_camera_quick.py
Go to the documentation of this file.
00001 """autogenerated by genpy from visp_hand2eye_calibration/compute_effector_camera_quickRequest.msg. Do not edit."""
00002 import sys
00003 python3 = True if sys.hexversion > 0x03000000 else False
00004 import genpy
00005 import struct
00006 
00007 import geometry_msgs.msg
00008 import visp_hand2eye_calibration.msg
00009 import std_msgs.msg
00010 
00011 class compute_effector_camera_quickRequest(genpy.Message):
00012   _md5sum = "4ce42b1236ce32724031d598c2a332bf"
00013   _type = "visp_hand2eye_calibration/compute_effector_camera_quickRequest"
00014   _has_header = False #flag to mark the presence of a Header object
00015   _full_text = """
00016 
00017 
00018 visp_hand2eye_calibration/TransformArray camera_object
00019 visp_hand2eye_calibration/TransformArray world_effector
00020 
00021 ================================================================================
00022 MSG: visp_hand2eye_calibration/TransformArray
00023 # An array of transforms with a header for global reference.
00024 
00025 Header header
00026 
00027 geometry_msgs/Transform[] transforms
00028 ================================================================================
00029 MSG: std_msgs/Header
00030 # Standard metadata for higher-level stamped data types.
00031 # This is generally used to communicate timestamped data 
00032 # in a particular coordinate frame.
00033 # 
00034 # sequence ID: consecutively increasing ID 
00035 uint32 seq
00036 #Two-integer timestamp that is expressed as:
00037 # * stamp.secs: seconds (stamp_secs) since epoch
00038 # * stamp.nsecs: nanoseconds since stamp_secs
00039 # time-handling sugar is provided by the client library
00040 time stamp
00041 #Frame this data is associated with
00042 # 0: no frame
00043 # 1: global frame
00044 string frame_id
00045 
00046 ================================================================================
00047 MSG: geometry_msgs/Transform
00048 # This represents the transform between two coordinate frames in free space.
00049 
00050 Vector3 translation
00051 Quaternion rotation
00052 
00053 ================================================================================
00054 MSG: geometry_msgs/Vector3
00055 # This represents a vector in free space. 
00056 
00057 float64 x
00058 float64 y
00059 float64 z
00060 ================================================================================
00061 MSG: geometry_msgs/Quaternion
00062 # This represents an orientation in free space in quaternion form.
00063 
00064 float64 x
00065 float64 y
00066 float64 z
00067 float64 w
00068 
00069 """
00070   __slots__ = ['camera_object','world_effector']
00071   _slot_types = ['visp_hand2eye_calibration/TransformArray','visp_hand2eye_calibration/TransformArray']
00072 
00073   def __init__(self, *args, **kwds):
00074     """
00075     Constructor. Any message fields that are implicitly/explicitly
00076     set to None will be assigned a default value. The recommend
00077     use is keyword arguments as this is more robust to future message
00078     changes.  You cannot mix in-order arguments and keyword arguments.
00079 
00080     The available fields are:
00081        camera_object,world_effector
00082 
00083     :param args: complete set of field values, in .msg order
00084     :param kwds: use keyword arguments corresponding to message field names
00085     to set specific fields.
00086     """
00087     if args or kwds:
00088       super(compute_effector_camera_quickRequest, self).__init__(*args, **kwds)
00089       #message fields cannot be None, assign default values for those that are
00090       if self.camera_object is None:
00091         self.camera_object = visp_hand2eye_calibration.msg.TransformArray()
00092       if self.world_effector is None:
00093         self.world_effector = visp_hand2eye_calibration.msg.TransformArray()
00094     else:
00095       self.camera_object = visp_hand2eye_calibration.msg.TransformArray()
00096       self.world_effector = visp_hand2eye_calibration.msg.TransformArray()
00097 
00098   def _get_types(self):
00099     """
00100     internal API method
00101     """
00102     return self._slot_types
00103 
00104   def serialize(self, buff):
00105     """
00106     serialize message into buffer
00107     :param buff: buffer, ``StringIO``
00108     """
00109     try:
00110       _x = self
00111       buff.write(_struct_3I.pack(_x.camera_object.header.seq, _x.camera_object.header.stamp.secs, _x.camera_object.header.stamp.nsecs))
00112       _x = self.camera_object.header.frame_id
00113       length = len(_x)
00114       if python3 or type(_x) == unicode:
00115         _x = _x.encode('utf-8')
00116         length = len(_x)
00117       buff.write(struct.pack('<I%ss'%length, length, _x))
00118       length = len(self.camera_object.transforms)
00119       buff.write(_struct_I.pack(length))
00120       for val1 in self.camera_object.transforms:
00121         _v1 = val1.translation
00122         _x = _v1
00123         buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00124         _v2 = val1.rotation
00125         _x = _v2
00126         buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
00127       _x = self
00128       buff.write(_struct_3I.pack(_x.world_effector.header.seq, _x.world_effector.header.stamp.secs, _x.world_effector.header.stamp.nsecs))
00129       _x = self.world_effector.header.frame_id
00130       length = len(_x)
00131       if python3 or type(_x) == unicode:
00132         _x = _x.encode('utf-8')
00133         length = len(_x)
00134       buff.write(struct.pack('<I%ss'%length, length, _x))
00135       length = len(self.world_effector.transforms)
00136       buff.write(_struct_I.pack(length))
00137       for val1 in self.world_effector.transforms:
00138         _v3 = val1.translation
00139         _x = _v3
00140         buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00141         _v4 = val1.rotation
00142         _x = _v4
00143         buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
00144     except struct.error as se: self._check_types(se)
00145     except TypeError as te: self._check_types(te)
00146 
00147   def deserialize(self, str):
00148     """
00149     unpack serialized message in str into this message instance
00150     :param str: byte array of serialized message, ``str``
00151     """
00152     try:
00153       if self.camera_object is None:
00154         self.camera_object = visp_hand2eye_calibration.msg.TransformArray()
00155       if self.world_effector is None:
00156         self.world_effector = visp_hand2eye_calibration.msg.TransformArray()
00157       end = 0
00158       _x = self
00159       start = end
00160       end += 12
00161       (_x.camera_object.header.seq, _x.camera_object.header.stamp.secs, _x.camera_object.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00162       start = end
00163       end += 4
00164       (length,) = _struct_I.unpack(str[start:end])
00165       start = end
00166       end += length
00167       if python3:
00168         self.camera_object.header.frame_id = str[start:end].decode('utf-8')
00169       else:
00170         self.camera_object.header.frame_id = str[start:end]
00171       start = end
00172       end += 4
00173       (length,) = _struct_I.unpack(str[start:end])
00174       self.camera_object.transforms = []
00175       for i in range(0, length):
00176         val1 = geometry_msgs.msg.Transform()
00177         _v5 = val1.translation
00178         _x = _v5
00179         start = end
00180         end += 24
00181         (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00182         _v6 = val1.rotation
00183         _x = _v6
00184         start = end
00185         end += 32
00186         (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
00187         self.camera_object.transforms.append(val1)
00188       _x = self
00189       start = end
00190       end += 12
00191       (_x.world_effector.header.seq, _x.world_effector.header.stamp.secs, _x.world_effector.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00192       start = end
00193       end += 4
00194       (length,) = _struct_I.unpack(str[start:end])
00195       start = end
00196       end += length
00197       if python3:
00198         self.world_effector.header.frame_id = str[start:end].decode('utf-8')
00199       else:
00200         self.world_effector.header.frame_id = str[start:end]
00201       start = end
00202       end += 4
00203       (length,) = _struct_I.unpack(str[start:end])
00204       self.world_effector.transforms = []
00205       for i in range(0, length):
00206         val1 = geometry_msgs.msg.Transform()
00207         _v7 = val1.translation
00208         _x = _v7
00209         start = end
00210         end += 24
00211         (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00212         _v8 = val1.rotation
00213         _x = _v8
00214         start = end
00215         end += 32
00216         (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
00217         self.world_effector.transforms.append(val1)
00218       return self
00219     except struct.error as e:
00220       raise genpy.DeserializationError(e) #most likely buffer underfill
00221 
00222 
00223   def serialize_numpy(self, buff, numpy):
00224     """
00225     serialize message with numpy array types into buffer
00226     :param buff: buffer, ``StringIO``
00227     :param numpy: numpy python module
00228     """
00229     try:
00230       _x = self
00231       buff.write(_struct_3I.pack(_x.camera_object.header.seq, _x.camera_object.header.stamp.secs, _x.camera_object.header.stamp.nsecs))
00232       _x = self.camera_object.header.frame_id
00233       length = len(_x)
00234       if python3 or type(_x) == unicode:
00235         _x = _x.encode('utf-8')
00236         length = len(_x)
00237       buff.write(struct.pack('<I%ss'%length, length, _x))
00238       length = len(self.camera_object.transforms)
00239       buff.write(_struct_I.pack(length))
00240       for val1 in self.camera_object.transforms:
00241         _v9 = val1.translation
00242         _x = _v9
00243         buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00244         _v10 = val1.rotation
00245         _x = _v10
00246         buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
00247       _x = self
00248       buff.write(_struct_3I.pack(_x.world_effector.header.seq, _x.world_effector.header.stamp.secs, _x.world_effector.header.stamp.nsecs))
00249       _x = self.world_effector.header.frame_id
00250       length = len(_x)
00251       if python3 or type(_x) == unicode:
00252         _x = _x.encode('utf-8')
00253         length = len(_x)
00254       buff.write(struct.pack('<I%ss'%length, length, _x))
00255       length = len(self.world_effector.transforms)
00256       buff.write(_struct_I.pack(length))
00257       for val1 in self.world_effector.transforms:
00258         _v11 = val1.translation
00259         _x = _v11
00260         buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00261         _v12 = val1.rotation
00262         _x = _v12
00263         buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
00264     except struct.error as se: self._check_types(se)
00265     except TypeError as te: self._check_types(te)
00266 
00267   def deserialize_numpy(self, str, numpy):
00268     """
00269     unpack serialized message in str into this message instance using numpy for array types
00270     :param str: byte array of serialized message, ``str``
00271     :param numpy: numpy python module
00272     """
00273     try:
00274       if self.camera_object is None:
00275         self.camera_object = visp_hand2eye_calibration.msg.TransformArray()
00276       if self.world_effector is None:
00277         self.world_effector = visp_hand2eye_calibration.msg.TransformArray()
00278       end = 0
00279       _x = self
00280       start = end
00281       end += 12
00282       (_x.camera_object.header.seq, _x.camera_object.header.stamp.secs, _x.camera_object.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00283       start = end
00284       end += 4
00285       (length,) = _struct_I.unpack(str[start:end])
00286       start = end
00287       end += length
00288       if python3:
00289         self.camera_object.header.frame_id = str[start:end].decode('utf-8')
00290       else:
00291         self.camera_object.header.frame_id = str[start:end]
00292       start = end
00293       end += 4
00294       (length,) = _struct_I.unpack(str[start:end])
00295       self.camera_object.transforms = []
00296       for i in range(0, length):
00297         val1 = geometry_msgs.msg.Transform()
00298         _v13 = val1.translation
00299         _x = _v13
00300         start = end
00301         end += 24
00302         (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00303         _v14 = val1.rotation
00304         _x = _v14
00305         start = end
00306         end += 32
00307         (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
00308         self.camera_object.transforms.append(val1)
00309       _x = self
00310       start = end
00311       end += 12
00312       (_x.world_effector.header.seq, _x.world_effector.header.stamp.secs, _x.world_effector.header.stamp.nsecs,) = _struct_3I.unpack(str[start:end])
00313       start = end
00314       end += 4
00315       (length,) = _struct_I.unpack(str[start:end])
00316       start = end
00317       end += length
00318       if python3:
00319         self.world_effector.header.frame_id = str[start:end].decode('utf-8')
00320       else:
00321         self.world_effector.header.frame_id = str[start:end]
00322       start = end
00323       end += 4
00324       (length,) = _struct_I.unpack(str[start:end])
00325       self.world_effector.transforms = []
00326       for i in range(0, length):
00327         val1 = geometry_msgs.msg.Transform()
00328         _v15 = val1.translation
00329         _x = _v15
00330         start = end
00331         end += 24
00332         (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00333         _v16 = val1.rotation
00334         _x = _v16
00335         start = end
00336         end += 32
00337         (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
00338         self.world_effector.transforms.append(val1)
00339       return self
00340     except struct.error as e:
00341       raise genpy.DeserializationError(e) #most likely buffer underfill
00342 
00343 _struct_I = genpy.struct_I
00344 _struct_3I = struct.Struct("<3I")
00345 _struct_4d = struct.Struct("<4d")
00346 _struct_3d = struct.Struct("<3d")
00347 """autogenerated by genpy from visp_hand2eye_calibration/compute_effector_camera_quickResponse.msg. Do not edit."""
00348 import sys
00349 python3 = True if sys.hexversion > 0x03000000 else False
00350 import genpy
00351 import struct
00352 
00353 import geometry_msgs.msg
00354 
00355 class compute_effector_camera_quickResponse(genpy.Message):
00356   _md5sum = "e28a9ea34e6e135a6309cbdf6fb0ad0d"
00357   _type = "visp_hand2eye_calibration/compute_effector_camera_quickResponse"
00358   _has_header = False #flag to mark the presence of a Header object
00359   _full_text = """geometry_msgs/Transform effector_camera
00360 
00361 ================================================================================
00362 MSG: geometry_msgs/Transform
00363 # This represents the transform between two coordinate frames in free space.
00364 
00365 Vector3 translation
00366 Quaternion rotation
00367 
00368 ================================================================================
00369 MSG: geometry_msgs/Vector3
00370 # This represents a vector in free space. 
00371 
00372 float64 x
00373 float64 y
00374 float64 z
00375 ================================================================================
00376 MSG: geometry_msgs/Quaternion
00377 # This represents an orientation in free space in quaternion form.
00378 
00379 float64 x
00380 float64 y
00381 float64 z
00382 float64 w
00383 
00384 """
00385   __slots__ = ['effector_camera']
00386   _slot_types = ['geometry_msgs/Transform']
00387 
00388   def __init__(self, *args, **kwds):
00389     """
00390     Constructor. Any message fields that are implicitly/explicitly
00391     set to None will be assigned a default value. The recommend
00392     use is keyword arguments as this is more robust to future message
00393     changes.  You cannot mix in-order arguments and keyword arguments.
00394 
00395     The available fields are:
00396        effector_camera
00397 
00398     :param args: complete set of field values, in .msg order
00399     :param kwds: use keyword arguments corresponding to message field names
00400     to set specific fields.
00401     """
00402     if args or kwds:
00403       super(compute_effector_camera_quickResponse, self).__init__(*args, **kwds)
00404       #message fields cannot be None, assign default values for those that are
00405       if self.effector_camera is None:
00406         self.effector_camera = geometry_msgs.msg.Transform()
00407     else:
00408       self.effector_camera = geometry_msgs.msg.Transform()
00409 
00410   def _get_types(self):
00411     """
00412     internal API method
00413     """
00414     return self._slot_types
00415 
00416   def serialize(self, buff):
00417     """
00418     serialize message into buffer
00419     :param buff: buffer, ``StringIO``
00420     """
00421     try:
00422       _x = self
00423       buff.write(_struct_7d.pack(_x.effector_camera.translation.x, _x.effector_camera.translation.y, _x.effector_camera.translation.z, _x.effector_camera.rotation.x, _x.effector_camera.rotation.y, _x.effector_camera.rotation.z, _x.effector_camera.rotation.w))
00424     except struct.error as se: self._check_types(se)
00425     except TypeError as te: self._check_types(te)
00426 
00427   def deserialize(self, str):
00428     """
00429     unpack serialized message in str into this message instance
00430     :param str: byte array of serialized message, ``str``
00431     """
00432     try:
00433       if self.effector_camera is None:
00434         self.effector_camera = geometry_msgs.msg.Transform()
00435       end = 0
00436       _x = self
00437       start = end
00438       end += 56
00439       (_x.effector_camera.translation.x, _x.effector_camera.translation.y, _x.effector_camera.translation.z, _x.effector_camera.rotation.x, _x.effector_camera.rotation.y, _x.effector_camera.rotation.z, _x.effector_camera.rotation.w,) = _struct_7d.unpack(str[start:end])
00440       return self
00441     except struct.error as e:
00442       raise genpy.DeserializationError(e) #most likely buffer underfill
00443 
00444 
00445   def serialize_numpy(self, buff, numpy):
00446     """
00447     serialize message with numpy array types into buffer
00448     :param buff: buffer, ``StringIO``
00449     :param numpy: numpy python module
00450     """
00451     try:
00452       _x = self
00453       buff.write(_struct_7d.pack(_x.effector_camera.translation.x, _x.effector_camera.translation.y, _x.effector_camera.translation.z, _x.effector_camera.rotation.x, _x.effector_camera.rotation.y, _x.effector_camera.rotation.z, _x.effector_camera.rotation.w))
00454     except struct.error as se: self._check_types(se)
00455     except TypeError as te: self._check_types(te)
00456 
00457   def deserialize_numpy(self, str, numpy):
00458     """
00459     unpack serialized message in str into this message instance using numpy for array types
00460     :param str: byte array of serialized message, ``str``
00461     :param numpy: numpy python module
00462     """
00463     try:
00464       if self.effector_camera is None:
00465         self.effector_camera = geometry_msgs.msg.Transform()
00466       end = 0
00467       _x = self
00468       start = end
00469       end += 56
00470       (_x.effector_camera.translation.x, _x.effector_camera.translation.y, _x.effector_camera.translation.z, _x.effector_camera.rotation.x, _x.effector_camera.rotation.y, _x.effector_camera.rotation.z, _x.effector_camera.rotation.w,) = _struct_7d.unpack(str[start:end])
00471       return self
00472     except struct.error as e:
00473       raise genpy.DeserializationError(e) #most likely buffer underfill
00474 
00475 _struct_I = genpy.struct_I
00476 _struct_7d = struct.Struct("<7d")
00477 class compute_effector_camera_quick(object):
00478   _type          = 'visp_hand2eye_calibration/compute_effector_camera_quick'
00479   _md5sum = 'ac7e8b661c5bfedda75b54410a11cf73'
00480   _request_class  = compute_effector_camera_quickRequest
00481   _response_class = compute_effector_camera_quickResponse


visp_hand2eye_calibration
Author(s): Filip Novotny
autogenerated on Sat Dec 28 2013 17:45:52