_DisplayButtons.py
Go to the documentation of this file.
00001 """autogenerated by genpy from hrl_clickable_world/DisplayButtonsRequest.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 genpy
00008 import geometry_msgs.msg
00009 import visualization_msgs.msg
00010 import std_msgs.msg
00011 
00012 class DisplayButtonsRequest(genpy.Message):
00013   _md5sum = "751920a2717efc2ee0759ed5dd79d09d"
00014   _type = "hrl_clickable_world/DisplayButtonsRequest"
00015   _has_header = False #flag to mark the presence of a Header object
00016   _full_text = """visualization_msgs/Marker[] buttons
00017 
00018 ================================================================================
00019 MSG: visualization_msgs/Marker
00020 # See http://www.ros.org/wiki/rviz/DisplayTypes/Marker and http://www.ros.org/wiki/rviz/Tutorials/Markers%3A%20Basic%20Shapes for more information on using this message with rviz
00021 
00022 uint8 ARROW=0
00023 uint8 CUBE=1
00024 uint8 SPHERE=2
00025 uint8 CYLINDER=3
00026 uint8 LINE_STRIP=4
00027 uint8 LINE_LIST=5
00028 uint8 CUBE_LIST=6
00029 uint8 SPHERE_LIST=7
00030 uint8 POINTS=8
00031 uint8 TEXT_VIEW_FACING=9
00032 uint8 MESH_RESOURCE=10
00033 uint8 TRIANGLE_LIST=11
00034 
00035 uint8 ADD=0
00036 uint8 MODIFY=0
00037 uint8 DELETE=2
00038 
00039 Header header                        # header for time/frame information
00040 string ns                            # Namespace to place this object in... used in conjunction with id to create a unique name for the object
00041 int32 id                                         # object ID useful in conjunction with the namespace for manipulating and deleting the object later
00042 int32 type                                     # Type of object
00043 int32 action                           # 0 add/modify an object, 1 (deprecated), 2 deletes an object
00044 geometry_msgs/Pose pose                 # Pose of the object
00045 geometry_msgs/Vector3 scale             # Scale of the object 1,1,1 means default (usually 1 meter square)
00046 std_msgs/ColorRGBA color             # Color [0.0-1.0]
00047 duration lifetime                    # How long the object should last before being automatically deleted.  0 means forever
00048 bool frame_locked                    # If this marker should be frame-locked, i.e. retransformed into its frame every timestep
00049 
00050 #Only used if the type specified has some use for them (eg. POINTS, LINE_STRIP, ...)
00051 geometry_msgs/Point[] points
00052 #Only used if the type specified has some use for them (eg. POINTS, LINE_STRIP, ...)
00053 #number of colors must either be 0 or equal to the number of points
00054 #NOTE: alpha is not yet used
00055 std_msgs/ColorRGBA[] colors
00056 
00057 # NOTE: only used for text markers
00058 string text
00059 
00060 # NOTE: only used for MESH_RESOURCE markers
00061 string mesh_resource
00062 bool mesh_use_embedded_materials
00063 
00064 ================================================================================
00065 MSG: std_msgs/Header
00066 # Standard metadata for higher-level stamped data types.
00067 # This is generally used to communicate timestamped data 
00068 # in a particular coordinate frame.
00069 # 
00070 # sequence ID: consecutively increasing ID 
00071 uint32 seq
00072 #Two-integer timestamp that is expressed as:
00073 # * stamp.secs: seconds (stamp_secs) since epoch
00074 # * stamp.nsecs: nanoseconds since stamp_secs
00075 # time-handling sugar is provided by the client library
00076 time stamp
00077 #Frame this data is associated with
00078 # 0: no frame
00079 # 1: global frame
00080 string frame_id
00081 
00082 ================================================================================
00083 MSG: geometry_msgs/Pose
00084 # A representation of pose in free space, composed of postion and orientation. 
00085 Point position
00086 Quaternion orientation
00087 
00088 ================================================================================
00089 MSG: geometry_msgs/Point
00090 # This contains the position of a point in free space
00091 float64 x
00092 float64 y
00093 float64 z
00094 
00095 ================================================================================
00096 MSG: geometry_msgs/Quaternion
00097 # This represents an orientation in free space in quaternion form.
00098 
00099 float64 x
00100 float64 y
00101 float64 z
00102 float64 w
00103 
00104 ================================================================================
00105 MSG: geometry_msgs/Vector3
00106 # This represents a vector in free space. 
00107 
00108 float64 x
00109 float64 y
00110 float64 z
00111 ================================================================================
00112 MSG: std_msgs/ColorRGBA
00113 float32 r
00114 float32 g
00115 float32 b
00116 float32 a
00117 
00118 """
00119   __slots__ = ['buttons']
00120   _slot_types = ['visualization_msgs/Marker[]']
00121 
00122   def __init__(self, *args, **kwds):
00123     """
00124     Constructor. Any message fields that are implicitly/explicitly
00125     set to None will be assigned a default value. The recommend
00126     use is keyword arguments as this is more robust to future message
00127     changes.  You cannot mix in-order arguments and keyword arguments.
00128 
00129     The available fields are:
00130        buttons
00131 
00132     :param args: complete set of field values, in .msg order
00133     :param kwds: use keyword arguments corresponding to message field names
00134     to set specific fields.
00135     """
00136     if args or kwds:
00137       super(DisplayButtonsRequest, self).__init__(*args, **kwds)
00138       #message fields cannot be None, assign default values for those that are
00139       if self.buttons is None:
00140         self.buttons = []
00141     else:
00142       self.buttons = []
00143 
00144   def _get_types(self):
00145     """
00146     internal API method
00147     """
00148     return self._slot_types
00149 
00150   def serialize(self, buff):
00151     """
00152     serialize message into buffer
00153     :param buff: buffer, ``StringIO``
00154     """
00155     try:
00156       length = len(self.buttons)
00157       buff.write(_struct_I.pack(length))
00158       for val1 in self.buttons:
00159         _v1 = val1.header
00160         buff.write(_struct_I.pack(_v1.seq))
00161         _v2 = _v1.stamp
00162         _x = _v2
00163         buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
00164         _x = _v1.frame_id
00165         length = len(_x)
00166         if python3 or type(_x) == unicode:
00167           _x = _x.encode('utf-8')
00168           length = len(_x)
00169         buff.write(struct.pack('<I%ss'%length, length, _x))
00170         _x = val1.ns
00171         length = len(_x)
00172         if python3 or type(_x) == unicode:
00173           _x = _x.encode('utf-8')
00174           length = len(_x)
00175         buff.write(struct.pack('<I%ss'%length, length, _x))
00176         _x = val1
00177         buff.write(_struct_3i.pack(_x.id, _x.type, _x.action))
00178         _v3 = val1.pose
00179         _v4 = _v3.position
00180         _x = _v4
00181         buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00182         _v5 = _v3.orientation
00183         _x = _v5
00184         buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
00185         _v6 = val1.scale
00186         _x = _v6
00187         buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00188         _v7 = val1.color
00189         _x = _v7
00190         buff.write(_struct_4f.pack(_x.r, _x.g, _x.b, _x.a))
00191         _v8 = val1.lifetime
00192         _x = _v8
00193         buff.write(_struct_2i.pack(_x.secs, _x.nsecs))
00194         buff.write(_struct_B.pack(val1.frame_locked))
00195         length = len(val1.points)
00196         buff.write(_struct_I.pack(length))
00197         for val2 in val1.points:
00198           _x = val2
00199           buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00200         length = len(val1.colors)
00201         buff.write(_struct_I.pack(length))
00202         for val2 in val1.colors:
00203           _x = val2
00204           buff.write(_struct_4f.pack(_x.r, _x.g, _x.b, _x.a))
00205         _x = val1.text
00206         length = len(_x)
00207         if python3 or type(_x) == unicode:
00208           _x = _x.encode('utf-8')
00209           length = len(_x)
00210         buff.write(struct.pack('<I%ss'%length, length, _x))
00211         _x = val1.mesh_resource
00212         length = len(_x)
00213         if python3 or type(_x) == unicode:
00214           _x = _x.encode('utf-8')
00215           length = len(_x)
00216         buff.write(struct.pack('<I%ss'%length, length, _x))
00217         buff.write(_struct_B.pack(val1.mesh_use_embedded_materials))
00218     except struct.error as se: self._check_types(se)
00219     except TypeError as te: self._check_types(te)
00220 
00221   def deserialize(self, str):
00222     """
00223     unpack serialized message in str into this message instance
00224     :param str: byte array of serialized message, ``str``
00225     """
00226     try:
00227       if self.buttons is None:
00228         self.buttons = None
00229       end = 0
00230       start = end
00231       end += 4
00232       (length,) = _struct_I.unpack(str[start:end])
00233       self.buttons = []
00234       for i in range(0, length):
00235         val1 = visualization_msgs.msg.Marker()
00236         _v9 = val1.header
00237         start = end
00238         end += 4
00239         (_v9.seq,) = _struct_I.unpack(str[start:end])
00240         _v10 = _v9.stamp
00241         _x = _v10
00242         start = end
00243         end += 8
00244         (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
00245         start = end
00246         end += 4
00247         (length,) = _struct_I.unpack(str[start:end])
00248         start = end
00249         end += length
00250         if python3:
00251           _v9.frame_id = str[start:end].decode('utf-8')
00252         else:
00253           _v9.frame_id = str[start:end]
00254         start = end
00255         end += 4
00256         (length,) = _struct_I.unpack(str[start:end])
00257         start = end
00258         end += length
00259         if python3:
00260           val1.ns = str[start:end].decode('utf-8')
00261         else:
00262           val1.ns = str[start:end]
00263         _x = val1
00264         start = end
00265         end += 12
00266         (_x.id, _x.type, _x.action,) = _struct_3i.unpack(str[start:end])
00267         _v11 = val1.pose
00268         _v12 = _v11.position
00269         _x = _v12
00270         start = end
00271         end += 24
00272         (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00273         _v13 = _v11.orientation
00274         _x = _v13
00275         start = end
00276         end += 32
00277         (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
00278         _v14 = val1.scale
00279         _x = _v14
00280         start = end
00281         end += 24
00282         (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00283         _v15 = val1.color
00284         _x = _v15
00285         start = end
00286         end += 16
00287         (_x.r, _x.g, _x.b, _x.a,) = _struct_4f.unpack(str[start:end])
00288         _v16 = val1.lifetime
00289         _x = _v16
00290         start = end
00291         end += 8
00292         (_x.secs, _x.nsecs,) = _struct_2i.unpack(str[start:end])
00293         start = end
00294         end += 1
00295         (val1.frame_locked,) = _struct_B.unpack(str[start:end])
00296         val1.frame_locked = bool(val1.frame_locked)
00297         start = end
00298         end += 4
00299         (length,) = _struct_I.unpack(str[start:end])
00300         val1.points = []
00301         for i in range(0, length):
00302           val2 = geometry_msgs.msg.Point()
00303           _x = val2
00304           start = end
00305           end += 24
00306           (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00307           val1.points.append(val2)
00308         start = end
00309         end += 4
00310         (length,) = _struct_I.unpack(str[start:end])
00311         val1.colors = []
00312         for i in range(0, length):
00313           val2 = std_msgs.msg.ColorRGBA()
00314           _x = val2
00315           start = end
00316           end += 16
00317           (_x.r, _x.g, _x.b, _x.a,) = _struct_4f.unpack(str[start:end])
00318           val1.colors.append(val2)
00319         start = end
00320         end += 4
00321         (length,) = _struct_I.unpack(str[start:end])
00322         start = end
00323         end += length
00324         if python3:
00325           val1.text = str[start:end].decode('utf-8')
00326         else:
00327           val1.text = str[start:end]
00328         start = end
00329         end += 4
00330         (length,) = _struct_I.unpack(str[start:end])
00331         start = end
00332         end += length
00333         if python3:
00334           val1.mesh_resource = str[start:end].decode('utf-8')
00335         else:
00336           val1.mesh_resource = str[start:end]
00337         start = end
00338         end += 1
00339         (val1.mesh_use_embedded_materials,) = _struct_B.unpack(str[start:end])
00340         val1.mesh_use_embedded_materials = bool(val1.mesh_use_embedded_materials)
00341         self.buttons.append(val1)
00342       return self
00343     except struct.error as e:
00344       raise genpy.DeserializationError(e) #most likely buffer underfill
00345 
00346 
00347   def serialize_numpy(self, buff, numpy):
00348     """
00349     serialize message with numpy array types into buffer
00350     :param buff: buffer, ``StringIO``
00351     :param numpy: numpy python module
00352     """
00353     try:
00354       length = len(self.buttons)
00355       buff.write(_struct_I.pack(length))
00356       for val1 in self.buttons:
00357         _v17 = val1.header
00358         buff.write(_struct_I.pack(_v17.seq))
00359         _v18 = _v17.stamp
00360         _x = _v18
00361         buff.write(_struct_2I.pack(_x.secs, _x.nsecs))
00362         _x = _v17.frame_id
00363         length = len(_x)
00364         if python3 or type(_x) == unicode:
00365           _x = _x.encode('utf-8')
00366           length = len(_x)
00367         buff.write(struct.pack('<I%ss'%length, length, _x))
00368         _x = val1.ns
00369         length = len(_x)
00370         if python3 or type(_x) == unicode:
00371           _x = _x.encode('utf-8')
00372           length = len(_x)
00373         buff.write(struct.pack('<I%ss'%length, length, _x))
00374         _x = val1
00375         buff.write(_struct_3i.pack(_x.id, _x.type, _x.action))
00376         _v19 = val1.pose
00377         _v20 = _v19.position
00378         _x = _v20
00379         buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00380         _v21 = _v19.orientation
00381         _x = _v21
00382         buff.write(_struct_4d.pack(_x.x, _x.y, _x.z, _x.w))
00383         _v22 = val1.scale
00384         _x = _v22
00385         buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00386         _v23 = val1.color
00387         _x = _v23
00388         buff.write(_struct_4f.pack(_x.r, _x.g, _x.b, _x.a))
00389         _v24 = val1.lifetime
00390         _x = _v24
00391         buff.write(_struct_2i.pack(_x.secs, _x.nsecs))
00392         buff.write(_struct_B.pack(val1.frame_locked))
00393         length = len(val1.points)
00394         buff.write(_struct_I.pack(length))
00395         for val2 in val1.points:
00396           _x = val2
00397           buff.write(_struct_3d.pack(_x.x, _x.y, _x.z))
00398         length = len(val1.colors)
00399         buff.write(_struct_I.pack(length))
00400         for val2 in val1.colors:
00401           _x = val2
00402           buff.write(_struct_4f.pack(_x.r, _x.g, _x.b, _x.a))
00403         _x = val1.text
00404         length = len(_x)
00405         if python3 or type(_x) == unicode:
00406           _x = _x.encode('utf-8')
00407           length = len(_x)
00408         buff.write(struct.pack('<I%ss'%length, length, _x))
00409         _x = val1.mesh_resource
00410         length = len(_x)
00411         if python3 or type(_x) == unicode:
00412           _x = _x.encode('utf-8')
00413           length = len(_x)
00414         buff.write(struct.pack('<I%ss'%length, length, _x))
00415         buff.write(_struct_B.pack(val1.mesh_use_embedded_materials))
00416     except struct.error as se: self._check_types(se)
00417     except TypeError as te: self._check_types(te)
00418 
00419   def deserialize_numpy(self, str, numpy):
00420     """
00421     unpack serialized message in str into this message instance using numpy for array types
00422     :param str: byte array of serialized message, ``str``
00423     :param numpy: numpy python module
00424     """
00425     try:
00426       if self.buttons is None:
00427         self.buttons = None
00428       end = 0
00429       start = end
00430       end += 4
00431       (length,) = _struct_I.unpack(str[start:end])
00432       self.buttons = []
00433       for i in range(0, length):
00434         val1 = visualization_msgs.msg.Marker()
00435         _v25 = val1.header
00436         start = end
00437         end += 4
00438         (_v25.seq,) = _struct_I.unpack(str[start:end])
00439         _v26 = _v25.stamp
00440         _x = _v26
00441         start = end
00442         end += 8
00443         (_x.secs, _x.nsecs,) = _struct_2I.unpack(str[start:end])
00444         start = end
00445         end += 4
00446         (length,) = _struct_I.unpack(str[start:end])
00447         start = end
00448         end += length
00449         if python3:
00450           _v25.frame_id = str[start:end].decode('utf-8')
00451         else:
00452           _v25.frame_id = str[start:end]
00453         start = end
00454         end += 4
00455         (length,) = _struct_I.unpack(str[start:end])
00456         start = end
00457         end += length
00458         if python3:
00459           val1.ns = str[start:end].decode('utf-8')
00460         else:
00461           val1.ns = str[start:end]
00462         _x = val1
00463         start = end
00464         end += 12
00465         (_x.id, _x.type, _x.action,) = _struct_3i.unpack(str[start:end])
00466         _v27 = val1.pose
00467         _v28 = _v27.position
00468         _x = _v28
00469         start = end
00470         end += 24
00471         (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00472         _v29 = _v27.orientation
00473         _x = _v29
00474         start = end
00475         end += 32
00476         (_x.x, _x.y, _x.z, _x.w,) = _struct_4d.unpack(str[start:end])
00477         _v30 = val1.scale
00478         _x = _v30
00479         start = end
00480         end += 24
00481         (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00482         _v31 = val1.color
00483         _x = _v31
00484         start = end
00485         end += 16
00486         (_x.r, _x.g, _x.b, _x.a,) = _struct_4f.unpack(str[start:end])
00487         _v32 = val1.lifetime
00488         _x = _v32
00489         start = end
00490         end += 8
00491         (_x.secs, _x.nsecs,) = _struct_2i.unpack(str[start:end])
00492         start = end
00493         end += 1
00494         (val1.frame_locked,) = _struct_B.unpack(str[start:end])
00495         val1.frame_locked = bool(val1.frame_locked)
00496         start = end
00497         end += 4
00498         (length,) = _struct_I.unpack(str[start:end])
00499         val1.points = []
00500         for i in range(0, length):
00501           val2 = geometry_msgs.msg.Point()
00502           _x = val2
00503           start = end
00504           end += 24
00505           (_x.x, _x.y, _x.z,) = _struct_3d.unpack(str[start:end])
00506           val1.points.append(val2)
00507         start = end
00508         end += 4
00509         (length,) = _struct_I.unpack(str[start:end])
00510         val1.colors = []
00511         for i in range(0, length):
00512           val2 = std_msgs.msg.ColorRGBA()
00513           _x = val2
00514           start = end
00515           end += 16
00516           (_x.r, _x.g, _x.b, _x.a,) = _struct_4f.unpack(str[start:end])
00517           val1.colors.append(val2)
00518         start = end
00519         end += 4
00520         (length,) = _struct_I.unpack(str[start:end])
00521         start = end
00522         end += length
00523         if python3:
00524           val1.text = str[start:end].decode('utf-8')
00525         else:
00526           val1.text = str[start:end]
00527         start = end
00528         end += 4
00529         (length,) = _struct_I.unpack(str[start:end])
00530         start = end
00531         end += length
00532         if python3:
00533           val1.mesh_resource = str[start:end].decode('utf-8')
00534         else:
00535           val1.mesh_resource = str[start:end]
00536         start = end
00537         end += 1
00538         (val1.mesh_use_embedded_materials,) = _struct_B.unpack(str[start:end])
00539         val1.mesh_use_embedded_materials = bool(val1.mesh_use_embedded_materials)
00540         self.buttons.append(val1)
00541       return self
00542     except struct.error as e:
00543       raise genpy.DeserializationError(e) #most likely buffer underfill
00544 
00545 _struct_I = genpy.struct_I
00546 _struct_B = struct.Struct("<B")
00547 _struct_2i = struct.Struct("<2i")
00548 _struct_3i = struct.Struct("<3i")
00549 _struct_4f = struct.Struct("<4f")
00550 _struct_4d = struct.Struct("<4d")
00551 _struct_2I = struct.Struct("<2I")
00552 _struct_3d = struct.Struct("<3d")
00553 """autogenerated by genpy from hrl_clickable_world/DisplayButtonsResponse.msg. Do not edit."""
00554 import sys
00555 python3 = True if sys.hexversion > 0x03000000 else False
00556 import genpy
00557 import struct
00558 
00559 
00560 class DisplayButtonsResponse(genpy.Message):
00561   _md5sum = "d41d8cd98f00b204e9800998ecf8427e"
00562   _type = "hrl_clickable_world/DisplayButtonsResponse"
00563   _has_header = False #flag to mark the presence of a Header object
00564   _full_text = """
00565 
00566 """
00567   __slots__ = []
00568   _slot_types = []
00569 
00570   def __init__(self, *args, **kwds):
00571     """
00572     Constructor. Any message fields that are implicitly/explicitly
00573     set to None will be assigned a default value. The recommend
00574     use is keyword arguments as this is more robust to future message
00575     changes.  You cannot mix in-order arguments and keyword arguments.
00576 
00577     The available fields are:
00578        
00579 
00580     :param args: complete set of field values, in .msg order
00581     :param kwds: use keyword arguments corresponding to message field names
00582     to set specific fields.
00583     """
00584     if args or kwds:
00585       super(DisplayButtonsResponse, self).__init__(*args, **kwds)
00586 
00587   def _get_types(self):
00588     """
00589     internal API method
00590     """
00591     return self._slot_types
00592 
00593   def serialize(self, buff):
00594     """
00595     serialize message into buffer
00596     :param buff: buffer, ``StringIO``
00597     """
00598     try:
00599       pass
00600     except struct.error as se: self._check_types(se)
00601     except TypeError as te: self._check_types(te)
00602 
00603   def deserialize(self, str):
00604     """
00605     unpack serialized message in str into this message instance
00606     :param str: byte array of serialized message, ``str``
00607     """
00608     try:
00609       end = 0
00610       return self
00611     except struct.error as e:
00612       raise genpy.DeserializationError(e) #most likely buffer underfill
00613 
00614 
00615   def serialize_numpy(self, buff, numpy):
00616     """
00617     serialize message with numpy array types into buffer
00618     :param buff: buffer, ``StringIO``
00619     :param numpy: numpy python module
00620     """
00621     try:
00622       pass
00623     except struct.error as se: self._check_types(se)
00624     except TypeError as te: self._check_types(te)
00625 
00626   def deserialize_numpy(self, str, numpy):
00627     """
00628     unpack serialized message in str into this message instance using numpy for array types
00629     :param str: byte array of serialized message, ``str``
00630     :param numpy: numpy python module
00631     """
00632     try:
00633       end = 0
00634       return self
00635     except struct.error as e:
00636       raise genpy.DeserializationError(e) #most likely buffer underfill
00637 
00638 _struct_I = genpy.struct_I
00639 class DisplayButtons(object):
00640   _type          = 'hrl_clickable_world/DisplayButtons'
00641   _md5sum = '751920a2717efc2ee0759ed5dd79d09d'
00642   _request_class  = DisplayButtonsRequest
00643   _response_class = DisplayButtonsResponse


hrl_clickable_world
Author(s): Kelsey Hawkins, Advisor: Prof. Charlie Kemp (Healthcare Robotics Lab at Georgia Tech)
autogenerated on Wed Nov 27 2013 11:54:28