def __init__(self, *args, **kwds):
        """
    Constructor. Any message fields that are implicitly/explicitly
    set to None will be assigned a default value. The recommend
    use is keyword arguments as this is more robust to future message
    changes.  You cannot mix in-order arguments and keyword arguments.

    The available fields are:
       header,ns,id,type,action,position,scale,outline_color,filled,fill_color,lifetime,points,outline_colors

    :param args: complete set of field values, in .msg order
    :param kwds: use keyword arguments corresponding to message field names
    to set specific fields.
    """
        if args or kwds:
            super(ImageMarker, self).__init__(*args, **kwds)
            #message fields cannot be None, assign default values for those that are
            if self.header is None:
                self.header = std_msgs.Header()
            if self.ns is None:
                self.ns = ''
            if self.id is None:
                self.id = 0
            if self.type is None:
                self.type = 0
            if self.action is None:
                self.action = 0
            if self.position is None:
                self.position = geometry_msgs.msg.Point()
            if self.scale is None:
                self.scale = 0.
            if self.outline_color is None:
                self.outline_color = std_msgs.ColorRGBA()
            if self.filled is None:
                self.filled = 0
            if self.fill_color is None:
                self.fill_color = std_msgs.ColorRGBA()
            if self.lifetime is None:
                self.lifetime = genpy.Duration()
            if self.points is None:
                self.points = []
            if self.outline_colors is None:
                self.outline_colors = []
        else:
            self.header = std_msgs.Header()
            self.ns = ''
            self.id = 0
            self.type = 0
            self.action = 0
            self.position = geometry_msgs.msg.Point()
            self.scale = 0.
            self.outline_color = std_msgs.ColorRGBA()
            self.filled = 0
            self.fill_color = std_msgs.ColorRGBA()
            self.lifetime = genpy.Duration()
            self.points = []
            self.outline_colors = []
 def deserialize_numpy(self, str, numpy):
     """
 unpack serialized message in str into this message instance using numpy for array types
 :param str: byte array of serialized message, ``str``
 :param numpy: numpy python module
 """
     try:
         if self.orientation is None:
             self.orientation = geometry_msgs.msg.Quaternion()
         if self.markers is None:
             self.markers = None
         end = 0
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
             self.name = str[start:end].decode('utf-8')
         else:
             self.name = str[start:end]
         _x = self
         start = end
         end += 35
         (
             _x.orientation.x,
             _x.orientation.y,
             _x.orientation.z,
             _x.orientation.w,
             _x.orientation_mode,
             _x.interaction_mode,
             _x.always_visible,
         ) = _get_struct_4d3B().unpack(str[start:end])
         self.always_visible = bool(self.always_visible)
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         self.markers = []
         for i in range(0, length):
             val1 = visualization_msgs.msg.Marker()
             _v25 = val1.header
             start = end
             end += 4
             (_v25.seq, ) = _get_struct_I().unpack(str[start:end])
             _v26 = _v25.stamp
             _x = _v26
             start = end
             end += 8
             (
                 _x.secs,
                 _x.nsecs,
             ) = _get_struct_2I().unpack(str[start:end])
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             start = end
             end += length
             if python3:
                 _v25.frame_id = str[start:end].decode('utf-8')
             else:
                 _v25.frame_id = str[start:end]
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             start = end
             end += length
             if python3:
                 val1.ns = str[start:end].decode('utf-8')
             else:
                 val1.ns = str[start:end]
             _x = val1
             start = end
             end += 12
             (
                 _x.id,
                 _x.type,
                 _x.action,
             ) = _get_struct_3i().unpack(str[start:end])
             _v27 = val1.pose
             _v28 = _v27.position
             _x = _v28
             start = end
             end += 24
             (
                 _x.x,
                 _x.y,
                 _x.z,
             ) = _get_struct_3d().unpack(str[start:end])
             _v29 = _v27.orientation
             _x = _v29
             start = end
             end += 32
             (
                 _x.x,
                 _x.y,
                 _x.z,
                 _x.w,
             ) = _get_struct_4d().unpack(str[start:end])
             _v30 = val1.scale
             _x = _v30
             start = end
             end += 24
             (
                 _x.x,
                 _x.y,
                 _x.z,
             ) = _get_struct_3d().unpack(str[start:end])
             _v31 = val1.color
             _x = _v31
             start = end
             end += 16
             (
                 _x.r,
                 _x.g,
                 _x.b,
                 _x.a,
             ) = _get_struct_4f().unpack(str[start:end])
             _v32 = val1.lifetime
             _x = _v32
             start = end
             end += 8
             (
                 _x.secs,
                 _x.nsecs,
             ) = _get_struct_2i().unpack(str[start:end])
             start = end
             end += 1
             (val1.frame_locked, ) = _get_struct_B().unpack(str[start:end])
             val1.frame_locked = bool(val1.frame_locked)
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             val1.points = []
             for i in range(0, length):
                 val2 = geometry_msgs.msg.Point()
                 _x = val2
                 start = end
                 end += 24
                 (
                     _x.x,
                     _x.y,
                     _x.z,
                 ) = _get_struct_3d().unpack(str[start:end])
                 val1.points.append(val2)
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             val1.colors = []
             for i in range(0, length):
                 val2 = std_msgs.ColorRGBA()
                 _x = val2
                 start = end
                 end += 16
                 (
                     _x.r,
                     _x.g,
                     _x.b,
                     _x.a,
                 ) = _get_struct_4f().unpack(str[start:end])
                 val1.colors.append(val2)
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             start = end
             end += length
             if python3:
                 val1.text = str[start:end].decode('utf-8')
             else:
                 val1.text = str[start:end]
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             start = end
             end += length
             if python3:
                 val1.mesh_resource = str[start:end].decode('utf-8')
             else:
                 val1.mesh_resource = str[start:end]
             start = end
             end += 1
             (val1.mesh_use_embedded_materials, ) = _get_struct_B().unpack(
                 str[start:end])
             val1.mesh_use_embedded_materials = bool(
                 val1.mesh_use_embedded_materials)
             self.markers.append(val1)
         start = end
         end += 1
         (self.independent_marker_orientation, ) = _get_struct_B().unpack(
             str[start:end])
         self.independent_marker_orientation = bool(
             self.independent_marker_orientation)
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
             self.description = str[start:end].decode('utf-8')
         else:
             self.description = str[start:end]
         return self
     except struct.error as e:
         raise genpy.DeserializationError(e)  #most likely buffer underfill
 def deserialize_numpy(self, str, numpy):
     """
 unpack serialized message in str into this message instance using numpy for array types
 :param str: byte array of serialized message, ``str``
 :param numpy: numpy python module
 """
     try:
         if self.header is None:
             self.header = std_msgs.Header()
         if self.pose is None:
             self.pose = geometry_msgs.msg.Pose()
         if self.scale is None:
             self.scale = geometry_msgs.msg.Vector3()
         if self.color is None:
             self.color = std_msgs.ColorRGBA()
         if self.lifetime is None:
             self.lifetime = genpy.Duration()
         if self.points is None:
             self.points = None
         if self.colors is None:
             self.colors = None
         end = 0
         _x = self
         start = end
         end += 12
         (
             _x.header.seq,
             _x.header.stamp.secs,
             _x.header.stamp.nsecs,
         ) = _get_struct_3I().unpack(str[start:end])
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
             self.header.frame_id = str[start:end].decode('utf-8')
         else:
             self.header.frame_id = str[start:end]
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
             self.ns = str[start:end].decode('utf-8')
         else:
             self.ns = str[start:end]
         _x = self
         start = end
         end += 117
         (
             _x.id,
             _x.type,
             _x.action,
             _x.pose.position.x,
             _x.pose.position.y,
             _x.pose.position.z,
             _x.pose.orientation.x,
             _x.pose.orientation.y,
             _x.pose.orientation.z,
             _x.pose.orientation.w,
             _x.scale.x,
             _x.scale.y,
             _x.scale.z,
             _x.color.r,
             _x.color.g,
             _x.color.b,
             _x.color.a,
             _x.lifetime.secs,
             _x.lifetime.nsecs,
             _x.frame_locked,
         ) = _get_struct_3i10d4f2iB().unpack(str[start:end])
         self.frame_locked = bool(self.frame_locked)
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         self.points = []
         for i in range(0, length):
             val1 = geometry_msgs.msg.Point()
             _x = val1
             start = end
             end += 24
             (
                 _x.x,
                 _x.y,
                 _x.z,
             ) = _get_struct_3d().unpack(str[start:end])
             self.points.append(val1)
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         self.colors = []
         for i in range(0, length):
             val1 = std_msgs.ColorRGBA()
             _x = val1
             start = end
             end += 16
             (
                 _x.r,
                 _x.g,
                 _x.b,
                 _x.a,
             ) = _get_struct_4f().unpack(str[start:end])
             self.colors.append(val1)
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
             self.text = str[start:end].decode('utf-8')
         else:
             self.text = str[start:end]
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
             self.mesh_resource = str[start:end].decode('utf-8')
         else:
             self.mesh_resource = str[start:end]
         start = end
         end += 1
         (self.mesh_use_embedded_materials, ) = _get_struct_B().unpack(
             str[start:end])
         self.mesh_use_embedded_materials = bool(
             self.mesh_use_embedded_materials)
         self.lifetime.canon()
         return self
     except struct.error as e:
         raise genpy.DeserializationError(e)  #most likely buffer underfill
    def __init__(self, *args, **kwds):
        """
    Constructor. Any message fields that are implicitly/explicitly
    set to None will be assigned a default value. The recommend
    use is keyword arguments as this is more robust to future message
    changes.  You cannot mix in-order arguments and keyword arguments.

    The available fields are:
       header,ns,id,type,action,pose,scale,color,lifetime,frame_locked,points,colors,text,mesh_resource,mesh_use_embedded_materials

    :param args: complete set of field values, in .msg order
    :param kwds: use keyword arguments corresponding to message field names
    to set specific fields.
    """
        if args or kwds:
            super(Marker, self).__init__(*args, **kwds)
            #message fields cannot be None, assign default values for those that are
            if self.header is None:
                self.header = std_msgs.Header()
            if self.ns is None:
                self.ns = ''
            if self.id is None:
                self.id = 0
            if self.type is None:
                self.type = 0
            if self.action is None:
                self.action = 0
            if self.pose is None:
                self.pose = geometry_msgs.msg.Pose()
            if self.scale is None:
                self.scale = geometry_msgs.msg.Vector3()
            if self.color is None:
                self.color = std_msgs.ColorRGBA()
            if self.lifetime is None:
                self.lifetime = genpy.Duration()
            if self.frame_locked is None:
                self.frame_locked = False
            if self.points is None:
                self.points = []
            if self.colors is None:
                self.colors = []
            if self.text is None:
                self.text = ''
            if self.mesh_resource is None:
                self.mesh_resource = ''
            if self.mesh_use_embedded_materials is None:
                self.mesh_use_embedded_materials = False
        else:
            self.header = std_msgs.Header()
            self.ns = ''
            self.id = 0
            self.type = 0
            self.action = 0
            self.pose = geometry_msgs.msg.Pose()
            self.scale = geometry_msgs.msg.Vector3()
            self.color = std_msgs.ColorRGBA()
            self.lifetime = genpy.Duration()
            self.frame_locked = False
            self.points = []
            self.colors = []
            self.text = ''
            self.mesh_resource = ''
            self.mesh_use_embedded_materials = False
 def deserialize_numpy(self, str, numpy):
   """
   unpack serialized message in str into this message instance using numpy for array types
   :param str: byte array of serialized message, ``str``
   :param numpy: numpy python module
   """
   try:
     if self.header is None:
       self.header = std_msgs.Header()
     if self.pose is None:
       self.pose = geometry_msgs.msg.Pose()
     if self.menu_entries is None:
       self.menu_entries = None
     if self.controls is None:
       self.controls = None
     end = 0
     _x = self
     start = end
     end += 12
     (_x.header.seq, _x.header.stamp.secs, _x.header.stamp.nsecs,) = _get_struct_3I().unpack(str[start:end])
     start = end
     end += 4
     (length,) = _struct_I.unpack(str[start:end])
     start = end
     end += length
     if python3:
       self.header.frame_id = str[start:end].decode('utf-8')
     else:
       self.header.frame_id = str[start:end]
     _x = self
     start = end
     end += 56
     (_x.pose.position.x, _x.pose.position.y, _x.pose.position.z, _x.pose.orientation.x, _x.pose.orientation.y, _x.pose.orientation.z, _x.pose.orientation.w,) = _get_struct_7d().unpack(str[start:end])
     start = end
     end += 4
     (length,) = _struct_I.unpack(str[start:end])
     start = end
     end += length
     if python3:
       self.name = str[start:end].decode('utf-8')
     else:
       self.name = str[start:end]
     start = end
     end += 4
     (length,) = _struct_I.unpack(str[start:end])
     start = end
     end += length
     if python3:
       self.description = str[start:end].decode('utf-8')
     else:
       self.description = str[start:end]
     start = end
     end += 4
     (self.scale,) = _get_struct_f().unpack(str[start:end])
     start = end
     end += 4
     (length,) = _struct_I.unpack(str[start:end])
     self.menu_entries = []
     for i in range(0, length):
       val1 = visualization_msgs.msg.MenuEntry()
       _x = val1
       start = end
       end += 8
       (_x.id, _x.parent_id,) = _get_struct_2I().unpack(str[start:end])
       start = end
       end += 4
       (length,) = _struct_I.unpack(str[start:end])
       start = end
       end += length
       if python3:
         val1.title = str[start:end].decode('utf-8')
       else:
         val1.title = str[start:end]
       start = end
       end += 4
       (length,) = _struct_I.unpack(str[start:end])
       start = end
       end += length
       if python3:
         val1.command = str[start:end].decode('utf-8')
       else:
         val1.command = str[start:end]
       start = end
       end += 1
       (val1.command_type,) = _get_struct_B().unpack(str[start:end])
       self.menu_entries.append(val1)
     start = end
     end += 4
     (length,) = _struct_I.unpack(str[start:end])
     self.controls = []
     for i in range(0, length):
       val1 = visualization_msgs.msg.InteractiveMarkerControl()
       start = end
       end += 4
       (length,) = _struct_I.unpack(str[start:end])
       start = end
       end += length
       if python3:
         val1.name = str[start:end].decode('utf-8')
       else:
         val1.name = str[start:end]
       _v28 = val1.orientation
       _x = _v28
       start = end
       end += 32
       (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
       _x = val1
       start = end
       end += 3
       (_x.orientation_mode, _x.interaction_mode, _x.always_visible,) = _get_struct_3B().unpack(str[start:end])
       val1.always_visible = bool(val1.always_visible)
       start = end
       end += 4
       (length,) = _struct_I.unpack(str[start:end])
       val1.markers = []
       for i in range(0, length):
         val2 = visualization_msgs.msg.Marker()
         _v29 = val2.header
         start = end
         end += 4
         (_v29.seq,) = _get_struct_I().unpack(str[start:end])
         _v30 = _v29.stamp
         _x = _v30
         start = end
         end += 8
         (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
         start = end
         end += 4
         (length,) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
           _v29.frame_id = str[start:end].decode('utf-8')
         else:
           _v29.frame_id = str[start:end]
         start = end
         end += 4
         (length,) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
           val2.ns = str[start:end].decode('utf-8')
         else:
           val2.ns = str[start:end]
         _x = val2
         start = end
         end += 12
         (_x.id, _x.type, _x.action,) = _get_struct_3i().unpack(str[start:end])
         _v31 = val2.pose
         _v32 = _v31.position
         _x = _v32
         start = end
         end += 24
         (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
         _v33 = _v31.orientation
         _x = _v33
         start = end
         end += 32
         (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
         _v34 = val2.scale
         _x = _v34
         start = end
         end += 24
         (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
         _v35 = val2.color
         _x = _v35
         start = end
         end += 16
         (_x.r, _x.g, _x.b, _x.a,) = _get_struct_4f().unpack(str[start:end])
         _v36 = val2.lifetime
         _x = _v36
         start = end
         end += 8
         (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
         start = end
         end += 1
         (val2.frame_locked,) = _get_struct_B().unpack(str[start:end])
         val2.frame_locked = bool(val2.frame_locked)
         start = end
         end += 4
         (length,) = _struct_I.unpack(str[start:end])
         val2.points = []
         for i in range(0, length):
           val3 = geometry_msgs.msg.Point()
           _x = val3
           start = end
           end += 24
           (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
           val2.points.append(val3)
         start = end
         end += 4
         (length,) = _struct_I.unpack(str[start:end])
         val2.colors = []
         for i in range(0, length):
           val3 = std_msgs.ColorRGBA()
           _x = val3
           start = end
           end += 16
           (_x.r, _x.g, _x.b, _x.a,) = _get_struct_4f().unpack(str[start:end])
           val2.colors.append(val3)
         start = end
         end += 4
         (length,) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
           val2.text = str[start:end].decode('utf-8')
         else:
           val2.text = str[start:end]
         start = end
         end += 4
         (length,) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
           val2.mesh_resource = str[start:end].decode('utf-8')
         else:
           val2.mesh_resource = str[start:end]
         start = end
         end += 1
         (val2.mesh_use_embedded_materials,) = _get_struct_B().unpack(str[start:end])
         val2.mesh_use_embedded_materials = bool(val2.mesh_use_embedded_materials)
         val1.markers.append(val2)
       start = end
       end += 1
       (val1.independent_marker_orientation,) = _get_struct_B().unpack(str[start:end])
       val1.independent_marker_orientation = bool(val1.independent_marker_orientation)
       start = end
       end += 4
       (length,) = _struct_I.unpack(str[start:end])
       start = end
       end += length
       if python3:
         val1.description = str[start:end].decode('utf-8')
       else:
         val1.description = str[start:end]
       self.controls.append(val1)
     return self
   except struct.error as e:
     raise genpy.DeserializationError(e) #most likely buffer underfill
Beispiel #6
0
 def deserialize(self, str):
     """
 unpack serialized message in str into this message instance
 :param str: byte array of serialized message, ``str``
 """
     try:
         if self.markers is None:
             self.markers = None
         end = 0
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         self.markers = []
         for i in range(0, length):
             val1 = visualization_msgs.msg.Marker()
             _v9 = val1.header
             start = end
             end += 4
             (_v9.seq, ) = _get_struct_I().unpack(str[start:end])
             _v10 = _v9.stamp
             _x = _v10
             start = end
             end += 8
             (
                 _x.secs,
                 _x.nsecs,
             ) = _get_struct_2I().unpack(str[start:end])
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             start = end
             end += length
             if python3:
                 _v9.frame_id = str[start:end].decode('utf-8')
             else:
                 _v9.frame_id = str[start:end]
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             start = end
             end += length
             if python3:
                 val1.ns = str[start:end].decode('utf-8')
             else:
                 val1.ns = str[start:end]
             _x = val1
             start = end
             end += 12
             (
                 _x.id,
                 _x.type,
                 _x.action,
             ) = _get_struct_3i().unpack(str[start:end])
             _v11 = val1.pose
             _v12 = _v11.position
             _x = _v12
             start = end
             end += 24
             (
                 _x.x,
                 _x.y,
                 _x.z,
             ) = _get_struct_3d().unpack(str[start:end])
             _v13 = _v11.orientation
             _x = _v13
             start = end
             end += 32
             (
                 _x.x,
                 _x.y,
                 _x.z,
                 _x.w,
             ) = _get_struct_4d().unpack(str[start:end])
             _v14 = val1.scale
             _x = _v14
             start = end
             end += 24
             (
                 _x.x,
                 _x.y,
                 _x.z,
             ) = _get_struct_3d().unpack(str[start:end])
             _v15 = val1.color
             _x = _v15
             start = end
             end += 16
             (
                 _x.r,
                 _x.g,
                 _x.b,
                 _x.a,
             ) = _get_struct_4f().unpack(str[start:end])
             _v16 = val1.lifetime
             _x = _v16
             start = end
             end += 8
             (
                 _x.secs,
                 _x.nsecs,
             ) = _get_struct_2i().unpack(str[start:end])
             start = end
             end += 1
             (val1.frame_locked, ) = _get_struct_B().unpack(str[start:end])
             val1.frame_locked = bool(val1.frame_locked)
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             val1.points = []
             for i in range(0, length):
                 val2 = geometry_msgs.msg.Point()
                 _x = val2
                 start = end
                 end += 24
                 (
                     _x.x,
                     _x.y,
                     _x.z,
                 ) = _get_struct_3d().unpack(str[start:end])
                 val1.points.append(val2)
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             val1.colors = []
             for i in range(0, length):
                 val2 = std_msgs.ColorRGBA()
                 _x = val2
                 start = end
                 end += 16
                 (
                     _x.r,
                     _x.g,
                     _x.b,
                     _x.a,
                 ) = _get_struct_4f().unpack(str[start:end])
                 val1.colors.append(val2)
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             start = end
             end += length
             if python3:
                 val1.text = str[start:end].decode('utf-8')
             else:
                 val1.text = str[start:end]
             start = end
             end += 4
             (length, ) = _struct_I.unpack(str[start:end])
             start = end
             end += length
             if python3:
                 val1.mesh_resource = str[start:end].decode('utf-8')
             else:
                 val1.mesh_resource = str[start:end]
             start = end
             end += 1
             (val1.mesh_use_embedded_materials, ) = _get_struct_B().unpack(
                 str[start:end])
             val1.mesh_use_embedded_materials = bool(
                 val1.mesh_use_embedded_materials)
             self.markers.append(val1)
         return self
     except struct.error as e:
         raise genpy.DeserializationError(e)  #most likely buffer underfill
Beispiel #7
0
 def deserialize(self, str):
   """
   unpack serialized message in str into this message instance
   :param str: byte array of serialized message, ``str``
   """
   try:
     if self.markers is None:
       self.markers = None
     end = 0
     start = end
     end += 4
     (length,) = _struct_I.unpack(str[start:end])
     start = end
     end += length
     if python3:
       self.server_id = str[start:end].decode('utf-8')
     else:
       self.server_id = str[start:end]
     start = end
     end += 8
     (self.seq_num,) = _get_struct_Q().unpack(str[start:end])
     start = end
     end += 4
     (length,) = _struct_I.unpack(str[start:end])
     self.markers = []
     for i in range(0, length):
       val1 = visualization_msgs.msg.InteractiveMarker()
       _v15 = val1.header
       start = end
       end += 4
       (_v15.seq,) = _get_struct_I().unpack(str[start:end])
       _v16 = _v15.stamp
       _x = _v16
       start = end
       end += 8
       (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
       start = end
       end += 4
       (length,) = _struct_I.unpack(str[start:end])
       start = end
       end += length
       if python3:
         _v15.frame_id = str[start:end].decode('utf-8')
       else:
         _v15.frame_id = str[start:end]
       _v17 = val1.pose
       _v18 = _v17.position
       _x = _v18
       start = end
       end += 24
       (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
       _v19 = _v17.orientation
       _x = _v19
       start = end
       end += 32
       (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
       start = end
       end += 4
       (length,) = _struct_I.unpack(str[start:end])
       start = end
       end += length
       if python3:
         val1.name = str[start:end].decode('utf-8')
       else:
         val1.name = str[start:end]
       start = end
       end += 4
       (length,) = _struct_I.unpack(str[start:end])
       start = end
       end += length
       if python3:
         val1.description = str[start:end].decode('utf-8')
       else:
         val1.description = str[start:end]
       start = end
       end += 4
       (val1.scale,) = _get_struct_f().unpack(str[start:end])
       start = end
       end += 4
       (length,) = _struct_I.unpack(str[start:end])
       val1.menu_entries = []
       for i in range(0, length):
         val2 = visualization_msgs.msg.MenuEntry()
         _x = val2
         start = end
         end += 8
         (_x.id, _x.parent_id,) = _get_struct_2I().unpack(str[start:end])
         start = end
         end += 4
         (length,) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
           val2.title = str[start:end].decode('utf-8')
         else:
           val2.title = str[start:end]
         start = end
         end += 4
         (length,) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
           val2.command = str[start:end].decode('utf-8')
         else:
           val2.command = str[start:end]
         start = end
         end += 1
         (val2.command_type,) = _get_struct_B().unpack(str[start:end])
         val1.menu_entries.append(val2)
       start = end
       end += 4
       (length,) = _struct_I.unpack(str[start:end])
       val1.controls = []
       for i in range(0, length):
         val2 = visualization_msgs.msg.InteractiveMarkerControl()
         start = end
         end += 4
         (length,) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
           val2.name = str[start:end].decode('utf-8')
         else:
           val2.name = str[start:end]
         _v20 = val2.orientation
         _x = _v20
         start = end
         end += 32
         (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
         _x = val2
         start = end
         end += 3
         (_x.orientation_mode, _x.interaction_mode, _x.always_visible,) = _get_struct_3B().unpack(str[start:end])
         val2.always_visible = bool(val2.always_visible)
         start = end
         end += 4
         (length,) = _struct_I.unpack(str[start:end])
         val2.markers = []
         for i in range(0, length):
           val3 = visualization_msgs.msg.Marker()
           _v21 = val3.header
           start = end
           end += 4
           (_v21.seq,) = _get_struct_I().unpack(str[start:end])
           _v22 = _v21.stamp
           _x = _v22
           start = end
           end += 8
           (_x.secs, _x.nsecs,) = _get_struct_2I().unpack(str[start:end])
           start = end
           end += 4
           (length,) = _struct_I.unpack(str[start:end])
           start = end
           end += length
           if python3:
             _v21.frame_id = str[start:end].decode('utf-8')
           else:
             _v21.frame_id = str[start:end]
           start = end
           end += 4
           (length,) = _struct_I.unpack(str[start:end])
           start = end
           end += length
           if python3:
             val3.ns = str[start:end].decode('utf-8')
           else:
             val3.ns = str[start:end]
           _x = val3
           start = end
           end += 12
           (_x.id, _x.type, _x.action,) = _get_struct_3i().unpack(str[start:end])
           _v23 = val3.pose
           _v24 = _v23.position
           _x = _v24
           start = end
           end += 24
           (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
           _v25 = _v23.orientation
           _x = _v25
           start = end
           end += 32
           (_x.x, _x.y, _x.z, _x.w,) = _get_struct_4d().unpack(str[start:end])
           _v26 = val3.scale
           _x = _v26
           start = end
           end += 24
           (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
           _v27 = val3.color
           _x = _v27
           start = end
           end += 16
           (_x.r, _x.g, _x.b, _x.a,) = _get_struct_4f().unpack(str[start:end])
           _v28 = val3.lifetime
           _x = _v28
           start = end
           end += 8
           (_x.secs, _x.nsecs,) = _get_struct_2i().unpack(str[start:end])
           start = end
           end += 1
           (val3.frame_locked,) = _get_struct_B().unpack(str[start:end])
           val3.frame_locked = bool(val3.frame_locked)
           start = end
           end += 4
           (length,) = _struct_I.unpack(str[start:end])
           val3.points = []
           for i in range(0, length):
             val4 = geometry_msgs.msg.Point()
             _x = val4
             start = end
             end += 24
             (_x.x, _x.y, _x.z,) = _get_struct_3d().unpack(str[start:end])
             val3.points.append(val4)
           start = end
           end += 4
           (length,) = _struct_I.unpack(str[start:end])
           val3.colors = []
           for i in range(0, length):
             val4 = std_msgs.ColorRGBA()
             _x = val4
             start = end
             end += 16
             (_x.r, _x.g, _x.b, _x.a,) = _get_struct_4f().unpack(str[start:end])
             val3.colors.append(val4)
           start = end
           end += 4
           (length,) = _struct_I.unpack(str[start:end])
           start = end
           end += length
           if python3:
             val3.text = str[start:end].decode('utf-8')
           else:
             val3.text = str[start:end]
           start = end
           end += 4
           (length,) = _struct_I.unpack(str[start:end])
           start = end
           end += length
           if python3:
             val3.mesh_resource = str[start:end].decode('utf-8')
           else:
             val3.mesh_resource = str[start:end]
           start = end
           end += 1
           (val3.mesh_use_embedded_materials,) = _get_struct_B().unpack(str[start:end])
           val3.mesh_use_embedded_materials = bool(val3.mesh_use_embedded_materials)
           val2.markers.append(val3)
         start = end
         end += 1
         (val2.independent_marker_orientation,) = _get_struct_B().unpack(str[start:end])
         val2.independent_marker_orientation = bool(val2.independent_marker_orientation)
         start = end
         end += 4
         (length,) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
           val2.description = str[start:end].decode('utf-8')
         else:
           val2.description = str[start:end]
         val1.controls.append(val2)
       self.markers.append(val1)
     return self
   except struct.error as e:
     raise genpy.DeserializationError(e) #most likely buffer underfill
 def deserialize_numpy(self, str, numpy):
     """
 unpack serialized message in str into this message instance using numpy for array types
 :param str: byte array of serialized message, ``str``
 :param numpy: numpy python module
 """
     try:
         if self.header is None:
             self.header = std_msgs.Header()
         if self.position is None:
             self.position = geometry_msgs.msg.Point()
         if self.outline_color is None:
             self.outline_color = std_msgs.ColorRGBA()
         if self.fill_color is None:
             self.fill_color = std_msgs.ColorRGBA()
         if self.lifetime is None:
             self.lifetime = genpy.Duration()
         if self.points is None:
             self.points = None
         if self.outline_colors is None:
             self.outline_colors = None
         end = 0
         _x = self
         start = end
         end += 12
         (
             _x.header.seq,
             _x.header.stamp.secs,
             _x.header.stamp.nsecs,
         ) = _get_struct_3I().unpack(str[start:end])
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
             self.header.frame_id = str[start:end].decode('utf-8')
         else:
             self.header.frame_id = str[start:end]
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         start = end
         end += length
         if python3:
             self.ns = str[start:end].decode('utf-8')
         else:
             self.ns = str[start:end]
         _x = self
         start = end
         end += 81
         (
             _x.id,
             _x.type,
             _x.action,
             _x.position.x,
             _x.position.y,
             _x.position.z,
             _x.scale,
             _x.outline_color.r,
             _x.outline_color.g,
             _x.outline_color.b,
             _x.outline_color.a,
             _x.filled,
             _x.fill_color.r,
             _x.fill_color.g,
             _x.fill_color.b,
             _x.fill_color.a,
             _x.lifetime.secs,
             _x.lifetime.nsecs,
         ) = _get_struct_3i3d5fB4f2i().unpack(str[start:end])
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         self.points = []
         for i in range(0, length):
             val1 = geometry_msgs.msg.Point()
             _x = val1
             start = end
             end += 24
             (
                 _x.x,
                 _x.y,
                 _x.z,
             ) = _get_struct_3d().unpack(str[start:end])
             self.points.append(val1)
         start = end
         end += 4
         (length, ) = _struct_I.unpack(str[start:end])
         self.outline_colors = []
         for i in range(0, length):
             val1 = std_msgs.ColorRGBA()
             _x = val1
             start = end
             end += 16
             (
                 _x.r,
                 _x.g,
                 _x.b,
                 _x.a,
             ) = _get_struct_4f().unpack(str[start:end])
             self.outline_colors.append(val1)
         self.lifetime.canon()
         return self
     except struct.error as e:
         raise genpy.DeserializationError(e)  #most likely buffer underfill