rosruby_msgs 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/actionlib_msgs/GoalID.rb +106 -0
- data/lib/actionlib_msgs/GoalStatus.rb +160 -0
- data/lib/actionlib_msgs/GoalStatusArray.rb +207 -0
- data/lib/actionlib_tutorials/AveragingAction.rb +322 -0
- data/lib/actionlib_tutorials/AveragingActionFeedback.rb +213 -0
- data/lib/actionlib_tutorials/AveragingActionGoal.rb +167 -0
- data/lib/actionlib_tutorials/AveragingActionResult.rb +209 -0
- data/lib/actionlib_tutorials/AveragingFeedback.rb +93 -0
- data/lib/actionlib_tutorials/AveragingGoal.rb +85 -0
- data/lib/actionlib_tutorials/AveragingResult.rb +87 -0
- data/lib/actionlib_tutorials/FibonacciAction.rb +334 -0
- data/lib/actionlib_tutorials/FibonacciActionFeedback.rb +216 -0
- data/lib/actionlib_tutorials/FibonacciActionGoal.rb +167 -0
- data/lib/actionlib_tutorials/FibonacciActionResult.rb +214 -0
- data/lib/actionlib_tutorials/FibonacciFeedback.rb +93 -0
- data/lib/actionlib_tutorials/FibonacciGoal.rb +85 -0
- data/lib/actionlib_tutorials/FibonacciResult.rb +91 -0
- data/lib/geometry_msgs/Point.rb +88 -0
- data/lib/geometry_msgs/Point32.rb +94 -0
- data/lib/geometry_msgs/PointStamped.rb +133 -0
- data/lib/geometry_msgs/Polygon.rb +112 -0
- data/lib/geometry_msgs/PolygonStamped.rb +159 -0
- data/lib/geometry_msgs/Pose.rb +110 -0
- data/lib/geometry_msgs/Pose2D.rb +88 -0
- data/lib/geometry_msgs/PoseArray.rb +174 -0
- data/lib/geometry_msgs/PoseStamped.rb +150 -0
- data/lib/geometry_msgs/PoseWithCovariance.rb +125 -0
- data/lib/geometry_msgs/PoseWithCovarianceStamped.rb +169 -0
- data/lib/geometry_msgs/Quaternion.rb +91 -0
- data/lib/geometry_msgs/QuaternionStamped.rb +136 -0
- data/lib/geometry_msgs/Transform.rb +111 -0
- data/lib/geometry_msgs/TransformStamped.rb +168 -0
- data/lib/geometry_msgs/Twist.rb +100 -0
- data/lib/geometry_msgs/TwistStamped.rb +140 -0
- data/lib/geometry_msgs/TwistWithCovariance.rb +115 -0
- data/lib/geometry_msgs/TwistWithCovarianceStamped.rb +158 -0
- data/lib/geometry_msgs/Vector3.rb +88 -0
- data/lib/geometry_msgs/Vector3Stamped.rb +133 -0
- data/lib/geometry_msgs/Wrench.rb +101 -0
- data/lib/geometry_msgs/WrenchStamped.rb +141 -0
- data/lib/nav_msgs/GetMap.rb +280 -0
- data/lib/nav_msgs/GetPlan.rb +406 -0
- data/lib/nav_msgs/GridCells.rb +153 -0
- data/lib/nav_msgs/MapMetaData.rb +130 -0
- data/lib/nav_msgs/OccupancyGrid.rb +187 -0
- data/lib/nav_msgs/Odometry.rb +223 -0
- data/lib/nav_msgs/Path.rb +205 -0
- data/lib/roscpp/Empty.rb +166 -0
- data/lib/roscpp/GetLoggers.rb +205 -0
- data/lib/roscpp/Logger.rb +98 -0
- data/lib/roscpp/SetLoggerLevel.rb +189 -0
- data/lib/roscpp_tutorials/TwoInts.rb +185 -0
- data/lib/rosgraph_msgs/Clock.rb +90 -0
- data/lib/rosgraph_msgs/Log.rb +210 -0
- data/lib/sensor_msgs/CameraInfo.rb +325 -0
- data/lib/sensor_msgs/ChannelFloat32.rb +122 -0
- data/lib/sensor_msgs/CompressedImage.rb +151 -0
- data/lib/sensor_msgs/Image.rb +179 -0
- data/lib/sensor_msgs/Imu.rb +193 -0
- data/lib/sensor_msgs/JointState.rb +195 -0
- data/lib/sensor_msgs/Joy.rb +141 -0
- data/lib/sensor_msgs/JoyFeedback.rb +104 -0
- data/lib/sensor_msgs/JoyFeedbackArray.rb +116 -0
- data/lib/sensor_msgs/LaserScan.rb +178 -0
- data/lib/sensor_msgs/NavSatFix.rb +215 -0
- data/lib/sensor_msgs/NavSatStatus.rb +115 -0
- data/lib/sensor_msgs/PointCloud.rb +222 -0
- data/lib/sensor_msgs/PointCloud2.rb +226 -0
- data/lib/sensor_msgs/PointField.rb +119 -0
- data/lib/sensor_msgs/Range.rb +157 -0
- data/lib/sensor_msgs/RegionOfInterest.rb +106 -0
- data/lib/sensor_msgs/SetCameraInfo.rb +437 -0
- data/lib/sensor_msgs/TimeReference.rb +140 -0
- data/lib/std_msgs/Bool.rb +83 -0
- data/lib/std_msgs/Byte.rb +83 -0
- data/lib/std_msgs/ByteMultiArray.rb +165 -0
- data/lib/std_msgs/Char.rb +82 -0
- data/lib/std_msgs/ColorRGBA.rb +89 -0
- data/lib/std_msgs/Duration.rb +87 -0
- data/lib/std_msgs/Empty.rb +75 -0
- data/lib/std_msgs/Float32.rb +82 -0
- data/lib/std_msgs/Float32MultiArray.rb +165 -0
- data/lib/std_msgs/Float64.rb +82 -0
- data/lib/std_msgs/Float64MultiArray.rb +165 -0
- data/lib/std_msgs/Header.rb +112 -0
- data/lib/std_msgs/Int16.rb +83 -0
- data/lib/std_msgs/Int16MultiArray.rb +165 -0
- data/lib/std_msgs/Int32.rb +82 -0
- data/lib/std_msgs/Int32MultiArray.rb +165 -0
- data/lib/std_msgs/Int64.rb +82 -0
- data/lib/std_msgs/Int64MultiArray.rb +165 -0
- data/lib/std_msgs/Int8.rb +83 -0
- data/lib/std_msgs/Int8MultiArray.rb +165 -0
- data/lib/std_msgs/MultiArrayDimension.rb +95 -0
- data/lib/std_msgs/MultiArrayLayout.rb +141 -0
- data/lib/std_msgs/String.rb +87 -0
- data/lib/std_msgs/Time.rb +87 -0
- data/lib/std_msgs/UInt16.rb +83 -0
- data/lib/std_msgs/UInt16MultiArray.rb +165 -0
- data/lib/std_msgs/UInt32.rb +81 -0
- data/lib/std_msgs/UInt32MultiArray.rb +165 -0
- data/lib/std_msgs/UInt64.rb +82 -0
- data/lib/std_msgs/UInt64MultiArray.rb +165 -0
- data/lib/std_msgs/UInt8.rb +83 -0
- data/lib/std_msgs/UInt8MultiArray.rb +168 -0
- data/lib/std_srvs/Empty.rb +166 -0
- data/lib/stereo_msgs/DisparityImage.rb +261 -0
- data/lib/tf/FrameGraph.rb +179 -0
- data/lib/tf/tfMessage.rb +202 -0
- data/lib/trajectory_msgs/JointTrajectory.rb +198 -0
- data/lib/trajectory_msgs/JointTrajectoryPoint.rb +125 -0
- data/lib/visualization_msgs/ImageMarker.rb +238 -0
- data/lib/visualization_msgs/InteractiveMarker.rb +651 -0
- data/lib/visualization_msgs/InteractiveMarkerControl.rb +469 -0
- data/lib/visualization_msgs/InteractiveMarkerFeedback.rb +235 -0
- data/lib/visualization_msgs/InteractiveMarkerInit.rb +707 -0
- data/lib/visualization_msgs/InteractiveMarkerPose.rb +166 -0
- data/lib/visualization_msgs/InteractiveMarkerUpdate.rb +825 -0
- data/lib/visualization_msgs/Marker.rb +318 -0
- data/lib/visualization_msgs/MarkerArray.rb +349 -0
- data/lib/visualization_msgs/MenuEntry.rb +168 -0
- metadata +123 -2
@@ -0,0 +1,157 @@
|
|
1
|
+
# autogenerated by genmsg_ruby from Range.msg. Do not edit.
|
2
|
+
require 'ros/message'
|
3
|
+
|
4
|
+
require "std_msgs/Header"
|
5
|
+
|
6
|
+
module Sensor_msgs
|
7
|
+
|
8
|
+
class Range <::ROS::Message
|
9
|
+
def self.md5sum
|
10
|
+
"c005c34273dc426c67a020a87bc24148"
|
11
|
+
end
|
12
|
+
|
13
|
+
def self.type
|
14
|
+
"sensor_msgs/Range"
|
15
|
+
end
|
16
|
+
|
17
|
+
def has_header?
|
18
|
+
true
|
19
|
+
end
|
20
|
+
|
21
|
+
def message_definition
|
22
|
+
"# Single range reading from an active ranger that emits energy and reports
|
23
|
+
# one range reading that is valid along an arc at the distance measured.
|
24
|
+
# This message is not appropriate for fixed-range obstacle detectors,
|
25
|
+
# such as the Sharp GP2D15. This message is also not appropriate for laser
|
26
|
+
# scanners. See the LaserScan message if you are working with a laser scanner.
|
27
|
+
|
28
|
+
Header header # timestamp in the header is the time the ranger
|
29
|
+
# returned the distance reading
|
30
|
+
|
31
|
+
# Radiation type enums
|
32
|
+
# If you want a value added to this list, send an email to the ros-users list
|
33
|
+
uint8 ULTRASOUND=0
|
34
|
+
uint8 INFRARED=1
|
35
|
+
|
36
|
+
uint8 radiation_type # the type of radiation used by the sensor
|
37
|
+
# (sound, IR, etc) [enum]
|
38
|
+
|
39
|
+
float32 field_of_view # the size of the arc that the distance reading is
|
40
|
+
# valid for [rad]
|
41
|
+
# the object causing the range reading may have
|
42
|
+
# been anywhere within -field_of_view/2 and
|
43
|
+
# field_of_view/2 at the measured range.
|
44
|
+
# 0 angle corresponds to the x-axis of the sensor.
|
45
|
+
|
46
|
+
float32 min_range # minimum range value [m]
|
47
|
+
float32 max_range # maximum range value [m]
|
48
|
+
|
49
|
+
float32 range # range data [m]
|
50
|
+
# (Note: values < range_min or > range_max
|
51
|
+
# should be discarded)
|
52
|
+
|
53
|
+
================================================================================
|
54
|
+
MSG: std_msgs/Header
|
55
|
+
# Standard metadata for higher-level stamped data types.
|
56
|
+
# This is generally used to communicate timestamped data
|
57
|
+
# in a particular coordinate frame.
|
58
|
+
#
|
59
|
+
# sequence ID: consecutively increasing ID
|
60
|
+
uint32 seq
|
61
|
+
#Two-integer timestamp that is expressed as:
|
62
|
+
# * stamp.secs: seconds (stamp_secs) since epoch
|
63
|
+
# * stamp.nsecs: nanoseconds since stamp_secs
|
64
|
+
# time-handling sugar is provided by the client library
|
65
|
+
time stamp
|
66
|
+
#Frame this data is associated with
|
67
|
+
# 0: no frame
|
68
|
+
# 1: global frame
|
69
|
+
string frame_id
|
70
|
+
|
71
|
+
"
|
72
|
+
end
|
73
|
+
# Pseudo-constants
|
74
|
+
ULTRASOUND = 0
|
75
|
+
INFRARED = 1
|
76
|
+
|
77
|
+
attr_accessor :header, :radiation_type, :field_of_view, :min_range, :max_range, :range
|
78
|
+
|
79
|
+
@@struct_L3 = ::ROS::Struct.new("L3")
|
80
|
+
@@struct_Cf4 = ::ROS::Struct.new("Cf4")
|
81
|
+
|
82
|
+
@@struct_L = ::ROS::Struct.new("L")
|
83
|
+
@@slot_types = ['Header','uint8','float32','float32','float32','float32']
|
84
|
+
|
85
|
+
def initialize
|
86
|
+
# Constructor. Any message fields that are implicitly/explicitly
|
87
|
+
# set to None will be assigned a default value. The recommend
|
88
|
+
# use is keyword arguments as this is more robust to future message
|
89
|
+
# changes. You cannot mix in-order arguments and keyword arguments.
|
90
|
+
#
|
91
|
+
# The available fields are:
|
92
|
+
# header,radiation_type,field_of_view,min_range,max_range,range
|
93
|
+
#
|
94
|
+
# @param args: complete set of field values, in .msg order
|
95
|
+
# @param kwds: use keyword arguments corresponding to message field names
|
96
|
+
# to set specific fields.
|
97
|
+
#
|
98
|
+
|
99
|
+
# message fields cannot be None, assign default values for those that are
|
100
|
+
@header = Std_msgs::Header.new
|
101
|
+
@radiation_type = 0
|
102
|
+
@field_of_view = 0.0
|
103
|
+
@min_range = 0.0
|
104
|
+
@max_range = 0.0
|
105
|
+
@range = 0.0
|
106
|
+
end
|
107
|
+
|
108
|
+
def _get_types
|
109
|
+
# internal API method
|
110
|
+
return @slot_types
|
111
|
+
end
|
112
|
+
|
113
|
+
def serialize(buff)
|
114
|
+
# serialize message into buffer
|
115
|
+
# @param buff: buffer
|
116
|
+
# @type buff: StringIO
|
117
|
+
begin
|
118
|
+
buff.write(@@struct_L3.pack(@header.seq, @header.stamp.secs, @header.stamp.nsecs))
|
119
|
+
_x = @header.frame_id
|
120
|
+
length = _x.length
|
121
|
+
buff.write([length, _x].pack("La#{length}"))
|
122
|
+
buff.write(@@struct_Cf4.pack(@radiation_type, @field_of_view, @min_range, @max_range, @range))
|
123
|
+
rescue => exception
|
124
|
+
raise "some erro in serialize: #{exception}"
|
125
|
+
|
126
|
+
end
|
127
|
+
end
|
128
|
+
|
129
|
+
def deserialize(str)
|
130
|
+
# unpack serialized message in str into this message instance
|
131
|
+
# @param str: byte array of serialized message
|
132
|
+
# @type str: str
|
133
|
+
|
134
|
+
begin
|
135
|
+
if @header == nil
|
136
|
+
@header = Std_msgs::Header.new
|
137
|
+
end
|
138
|
+
end_point = 0
|
139
|
+
start = end_point
|
140
|
+
end_point += ROS::Struct::calc_size('L3')
|
141
|
+
(@header.seq, @header.stamp.secs, @header.stamp.nsecs,) = @@struct_L3.unpack(str[start..(end_point-1)])
|
142
|
+
start = end_point
|
143
|
+
end_point += 4
|
144
|
+
(length,) = @@struct_L.unpack(str[start..(end_point-1)])
|
145
|
+
start = end_point
|
146
|
+
end_point += length
|
147
|
+
@header.frame_id = str[start..(end_point-1)]
|
148
|
+
start = end_point
|
149
|
+
end_point += ROS::Struct::calc_size('Cf4')
|
150
|
+
(@radiation_type, @field_of_view, @min_range, @max_range, @range,) = @@struct_Cf4.unpack(str[start..(end_point-1)])
|
151
|
+
return self
|
152
|
+
rescue => exception
|
153
|
+
raise "message DeserializationError: #{exception}" #most likely buffer underfill
|
154
|
+
end
|
155
|
+
end
|
156
|
+
end # end of class
|
157
|
+
end # end of module
|
@@ -0,0 +1,106 @@
|
|
1
|
+
# autogenerated by genmsg_ruby from RegionOfInterest.msg. Do not edit.
|
2
|
+
require 'ros/message'
|
3
|
+
|
4
|
+
|
5
|
+
module Sensor_msgs
|
6
|
+
|
7
|
+
class RegionOfInterest <::ROS::Message
|
8
|
+
def self.md5sum
|
9
|
+
"bdb633039d588fcccb441a4d43ccfe09"
|
10
|
+
end
|
11
|
+
|
12
|
+
def self.type
|
13
|
+
"sensor_msgs/RegionOfInterest"
|
14
|
+
end
|
15
|
+
|
16
|
+
def has_header?
|
17
|
+
false
|
18
|
+
end
|
19
|
+
|
20
|
+
def message_definition
|
21
|
+
"# This message is used to specify a region of interest within an image.
|
22
|
+
#
|
23
|
+
# When used to specify the ROI setting of the camera when the image was
|
24
|
+
# taken, the height and width fields should either match the height and
|
25
|
+
# width fields for the associated image; or height = width = 0
|
26
|
+
# indicates that the full resolution image was captured.
|
27
|
+
|
28
|
+
uint32 x_offset # Leftmost pixel of the ROI
|
29
|
+
# (0 if the ROI includes the left edge of the image)
|
30
|
+
uint32 y_offset # Topmost pixel of the ROI
|
31
|
+
# (0 if the ROI includes the top edge of the image)
|
32
|
+
uint32 height # Height of ROI
|
33
|
+
uint32 width # Width of ROI
|
34
|
+
|
35
|
+
# True if a distinct rectified ROI should be calculated from the \"raw\"
|
36
|
+
# ROI in this message. Typically this should be False if the full image
|
37
|
+
# is captured (ROI not used), and True if a subwindow is captured (ROI
|
38
|
+
# used).
|
39
|
+
bool do_rectify
|
40
|
+
|
41
|
+
"
|
42
|
+
end
|
43
|
+
attr_accessor :x_offset, :y_offset, :height, :width, :do_rectify
|
44
|
+
|
45
|
+
@@struct_L4C = ::ROS::Struct.new("L4C")
|
46
|
+
|
47
|
+
@@struct_L = ::ROS::Struct.new("L")
|
48
|
+
@@slot_types = ['uint32','uint32','uint32','uint32','bool']
|
49
|
+
|
50
|
+
def initialize
|
51
|
+
# Constructor. Any message fields that are implicitly/explicitly
|
52
|
+
# set to None will be assigned a default value. The recommend
|
53
|
+
# use is keyword arguments as this is more robust to future message
|
54
|
+
# changes. You cannot mix in-order arguments and keyword arguments.
|
55
|
+
#
|
56
|
+
# The available fields are:
|
57
|
+
# x_offset,y_offset,height,width,do_rectify
|
58
|
+
#
|
59
|
+
# @param args: complete set of field values, in .msg order
|
60
|
+
# @param kwds: use keyword arguments corresponding to message field names
|
61
|
+
# to set specific fields.
|
62
|
+
#
|
63
|
+
|
64
|
+
# message fields cannot be None, assign default values for those that are
|
65
|
+
@x_offset = 0
|
66
|
+
@y_offset = 0
|
67
|
+
@height = 0
|
68
|
+
@width = 0
|
69
|
+
@do_rectify = false
|
70
|
+
end
|
71
|
+
|
72
|
+
def _get_types
|
73
|
+
# internal API method
|
74
|
+
return @slot_types
|
75
|
+
end
|
76
|
+
|
77
|
+
def serialize(buff)
|
78
|
+
# serialize message into buffer
|
79
|
+
# @param buff: buffer
|
80
|
+
# @type buff: StringIO
|
81
|
+
begin
|
82
|
+
buff.write(@@struct_L4C.pack(@x_offset, @y_offset, @height, @width, @do_rectify))
|
83
|
+
rescue => exception
|
84
|
+
raise "some erro in serialize: #{exception}"
|
85
|
+
|
86
|
+
end
|
87
|
+
end
|
88
|
+
|
89
|
+
def deserialize(str)
|
90
|
+
# unpack serialized message in str into this message instance
|
91
|
+
# @param str: byte array of serialized message
|
92
|
+
# @type str: str
|
93
|
+
|
94
|
+
begin
|
95
|
+
end_point = 0
|
96
|
+
start = end_point
|
97
|
+
end_point += ROS::Struct::calc_size('L4C')
|
98
|
+
(@x_offset, @y_offset, @height, @width, @do_rectify,) = @@struct_L4C.unpack(str[start..(end_point-1)])
|
99
|
+
@do_rectify = bool(@do_rectify)
|
100
|
+
return self
|
101
|
+
rescue => exception
|
102
|
+
raise "message DeserializationError: #{exception}" #most likely buffer underfill
|
103
|
+
end
|
104
|
+
end
|
105
|
+
end # end of class
|
106
|
+
end # end of module
|
@@ -0,0 +1,437 @@
|
|
1
|
+
# autogenerated by genmsg_ruby from SetCameraInfoRequest.msg. Do not edit.
|
2
|
+
require 'ros/message'
|
3
|
+
|
4
|
+
require "std_msgs/Header"
|
5
|
+
require "sensor_msgs/RegionOfInterest"
|
6
|
+
require "sensor_msgs/CameraInfo"
|
7
|
+
|
8
|
+
module Sensor_msgs
|
9
|
+
|
10
|
+
class SetCameraInfoRequest <::ROS::Message
|
11
|
+
def self.md5sum
|
12
|
+
"ee34be01fdeee563d0d99cd594d5581d"
|
13
|
+
end
|
14
|
+
|
15
|
+
def self.type
|
16
|
+
"sensor_msgs/SetCameraInfoRequest"
|
17
|
+
end
|
18
|
+
|
19
|
+
def has_header?
|
20
|
+
false
|
21
|
+
end
|
22
|
+
|
23
|
+
def message_definition
|
24
|
+
"
|
25
|
+
|
26
|
+
|
27
|
+
|
28
|
+
|
29
|
+
|
30
|
+
|
31
|
+
|
32
|
+
sensor_msgs/CameraInfo camera_info
|
33
|
+
|
34
|
+
================================================================================
|
35
|
+
MSG: sensor_msgs/CameraInfo
|
36
|
+
# This message defines meta information for a camera. It should be in a
|
37
|
+
# camera namespace on topic \"camera_info\" and accompanied by up to five
|
38
|
+
# image topics named:
|
39
|
+
#
|
40
|
+
# image_raw - raw data from the camera driver, possibly Bayer encoded
|
41
|
+
# image - monochrome, distorted
|
42
|
+
# image_color - color, distorted
|
43
|
+
# image_rect - monochrome, rectified
|
44
|
+
# image_rect_color - color, rectified
|
45
|
+
#
|
46
|
+
# The image_pipeline contains packages (image_proc, stereo_image_proc)
|
47
|
+
# for producing the four processed image topics from image_raw and
|
48
|
+
# camera_info. The meaning of the camera parameters are described in
|
49
|
+
# detail at http://www.ros.org/wiki/image_pipeline/CameraInfo.
|
50
|
+
#
|
51
|
+
# The image_geometry package provides a user-friendly interface to
|
52
|
+
# common operations using this meta information. If you want to, e.g.,
|
53
|
+
# project a 3d point into image coordinates, we strongly recommend
|
54
|
+
# using image_geometry.
|
55
|
+
#
|
56
|
+
# If the camera is uncalibrated, the matrices D, K, R, P should be left
|
57
|
+
# zeroed out. In particular, clients may assume that K[0] == 0.0
|
58
|
+
# indicates an uncalibrated camera.
|
59
|
+
|
60
|
+
#######################################################################
|
61
|
+
# Image acquisition info #
|
62
|
+
#######################################################################
|
63
|
+
|
64
|
+
# Time of image acquisition, camera coordinate frame ID
|
65
|
+
Header header # Header timestamp should be acquisition time of image
|
66
|
+
# Header frame_id should be optical frame of camera
|
67
|
+
# origin of frame should be optical center of camera
|
68
|
+
# +x should point to the right in the image
|
69
|
+
# +y should point down in the image
|
70
|
+
# +z should point into the plane of the image
|
71
|
+
|
72
|
+
|
73
|
+
#######################################################################
|
74
|
+
# Calibration Parameters #
|
75
|
+
#######################################################################
|
76
|
+
# These are fixed during camera calibration. Their values will be the #
|
77
|
+
# same in all messages until the camera is recalibrated. Note that #
|
78
|
+
# self-calibrating systems may \"recalibrate\" frequently. #
|
79
|
+
# #
|
80
|
+
# The internal parameters can be used to warp a raw (distorted) image #
|
81
|
+
# to: #
|
82
|
+
# 1. An undistorted image (requires D and K) #
|
83
|
+
# 2. A rectified image (requires D, K, R) #
|
84
|
+
# The projection matrix P projects 3D points into the rectified image.#
|
85
|
+
#######################################################################
|
86
|
+
|
87
|
+
# The image dimensions with which the camera was calibrated. Normally
|
88
|
+
# this will be the full camera resolution in pixels.
|
89
|
+
uint32 height
|
90
|
+
uint32 width
|
91
|
+
|
92
|
+
# The distortion model used. Supported models are listed in
|
93
|
+
# sensor_msgs/distortion_models.h. For most cameras, \"plumb_bob\" - a
|
94
|
+
# simple model of radial and tangential distortion - is sufficent.
|
95
|
+
string distortion_model
|
96
|
+
|
97
|
+
# The distortion parameters, size depending on the distortion model.
|
98
|
+
# For \"plumb_bob\", the 5 parameters are: (k1, k2, t1, t2, k3).
|
99
|
+
float64[] D
|
100
|
+
|
101
|
+
# Intrinsic camera matrix for the raw (distorted) images.
|
102
|
+
# [fx 0 cx]
|
103
|
+
# K = [ 0 fy cy]
|
104
|
+
# [ 0 0 1]
|
105
|
+
# Projects 3D points in the camera coordinate frame to 2D pixel
|
106
|
+
# coordinates using the focal lengths (fx, fy) and principal point
|
107
|
+
# (cx, cy).
|
108
|
+
float64[9] K # 3x3 row-major matrix
|
109
|
+
|
110
|
+
# Rectification matrix (stereo cameras only)
|
111
|
+
# A rotation matrix aligning the camera coordinate system to the ideal
|
112
|
+
# stereo image plane so that epipolar lines in both stereo images are
|
113
|
+
# parallel.
|
114
|
+
float64[9] R # 3x3 row-major matrix
|
115
|
+
|
116
|
+
# Projection/camera matrix
|
117
|
+
# [fx' 0 cx' Tx]
|
118
|
+
# P = [ 0 fy' cy' Ty]
|
119
|
+
# [ 0 0 1 0]
|
120
|
+
# By convention, this matrix specifies the intrinsic (camera) matrix
|
121
|
+
# of the processed (rectified) image. That is, the left 3x3 portion
|
122
|
+
# is the normal camera intrinsic matrix for the rectified image.
|
123
|
+
# It projects 3D points in the camera coordinate frame to 2D pixel
|
124
|
+
# coordinates using the focal lengths (fx', fy') and principal point
|
125
|
+
# (cx', cy') - these may differ from the values in K.
|
126
|
+
# For monocular cameras, Tx = Ty = 0. Normally, monocular cameras will
|
127
|
+
# also have R = the identity and P[1:3,1:3] = K.
|
128
|
+
# For a stereo pair, the fourth column [Tx Ty 0]' is related to the
|
129
|
+
# position of the optical center of the second camera in the first
|
130
|
+
# camera's frame. We assume Tz = 0 so both cameras are in the same
|
131
|
+
# stereo image plane. The first camera always has Tx = Ty = 0. For
|
132
|
+
# the right (second) camera of a horizontal stereo pair, Ty = 0 and
|
133
|
+
# Tx = -fx' * B, where B is the baseline between the cameras.
|
134
|
+
# Given a 3D point [X Y Z]', the projection (x, y) of the point onto
|
135
|
+
# the rectified image is given by:
|
136
|
+
# [u v w]' = P * [X Y Z 1]'
|
137
|
+
# x = u / w
|
138
|
+
# y = v / w
|
139
|
+
# This holds for both images of a stereo pair.
|
140
|
+
float64[12] P # 3x4 row-major matrix
|
141
|
+
|
142
|
+
|
143
|
+
#######################################################################
|
144
|
+
# Operational Parameters #
|
145
|
+
#######################################################################
|
146
|
+
# These define the image region actually captured by the camera #
|
147
|
+
# driver. Although they affect the geometry of the output image, they #
|
148
|
+
# may be changed freely without recalibrating the camera. #
|
149
|
+
#######################################################################
|
150
|
+
|
151
|
+
# Binning refers here to any camera setting which combines rectangular
|
152
|
+
# neighborhoods of pixels into larger \"super-pixels.\" It reduces the
|
153
|
+
# resolution of the output image to
|
154
|
+
# (width / binning_x) x (height / binning_y).
|
155
|
+
# The default values binning_x = binning_y = 0 is considered the same
|
156
|
+
# as binning_x = binning_y = 1 (no subsampling).
|
157
|
+
uint32 binning_x
|
158
|
+
uint32 binning_y
|
159
|
+
|
160
|
+
# Region of interest (subwindow of full camera resolution), given in
|
161
|
+
# full resolution (unbinned) image coordinates. A particular ROI
|
162
|
+
# always denotes the same window of pixels on the camera sensor,
|
163
|
+
# regardless of binning settings.
|
164
|
+
# The default setting of roi (all values 0) is considered the same as
|
165
|
+
# full resolution (roi.width = width, roi.height = height).
|
166
|
+
RegionOfInterest roi
|
167
|
+
|
168
|
+
================================================================================
|
169
|
+
MSG: std_msgs/Header
|
170
|
+
# Standard metadata for higher-level stamped data types.
|
171
|
+
# This is generally used to communicate timestamped data
|
172
|
+
# in a particular coordinate frame.
|
173
|
+
#
|
174
|
+
# sequence ID: consecutively increasing ID
|
175
|
+
uint32 seq
|
176
|
+
#Two-integer timestamp that is expressed as:
|
177
|
+
# * stamp.secs: seconds (stamp_secs) since epoch
|
178
|
+
# * stamp.nsecs: nanoseconds since stamp_secs
|
179
|
+
# time-handling sugar is provided by the client library
|
180
|
+
time stamp
|
181
|
+
#Frame this data is associated with
|
182
|
+
# 0: no frame
|
183
|
+
# 1: global frame
|
184
|
+
string frame_id
|
185
|
+
|
186
|
+
================================================================================
|
187
|
+
MSG: sensor_msgs/RegionOfInterest
|
188
|
+
# This message is used to specify a region of interest within an image.
|
189
|
+
#
|
190
|
+
# When used to specify the ROI setting of the camera when the image was
|
191
|
+
# taken, the height and width fields should either match the height and
|
192
|
+
# width fields for the associated image; or height = width = 0
|
193
|
+
# indicates that the full resolution image was captured.
|
194
|
+
|
195
|
+
uint32 x_offset # Leftmost pixel of the ROI
|
196
|
+
# (0 if the ROI includes the left edge of the image)
|
197
|
+
uint32 y_offset # Topmost pixel of the ROI
|
198
|
+
# (0 if the ROI includes the top edge of the image)
|
199
|
+
uint32 height # Height of ROI
|
200
|
+
uint32 width # Width of ROI
|
201
|
+
|
202
|
+
# True if a distinct rectified ROI should be calculated from the \"raw\"
|
203
|
+
# ROI in this message. Typically this should be False if the full image
|
204
|
+
# is captured (ROI not used), and True if a subwindow is captured (ROI
|
205
|
+
# used).
|
206
|
+
bool do_rectify
|
207
|
+
|
208
|
+
"
|
209
|
+
end
|
210
|
+
attr_accessor :camera_info
|
211
|
+
|
212
|
+
@@struct_L6C = ::ROS::Struct.new("L6C")
|
213
|
+
@@struct_L3 = ::ROS::Struct.new("L3")
|
214
|
+
@@struct_d12 = ::ROS::Struct.new("d12")
|
215
|
+
@@struct_L2 = ::ROS::Struct.new("L2")
|
216
|
+
@@struct_d9 = ::ROS::Struct.new("d9")
|
217
|
+
|
218
|
+
@@struct_L = ::ROS::Struct.new("L")
|
219
|
+
@@slot_types = ['sensor_msgs/CameraInfo']
|
220
|
+
|
221
|
+
def initialize
|
222
|
+
# Constructor. Any message fields that are implicitly/explicitly
|
223
|
+
# set to None will be assigned a default value. The recommend
|
224
|
+
# use is keyword arguments as this is more robust to future message
|
225
|
+
# changes. You cannot mix in-order arguments and keyword arguments.
|
226
|
+
#
|
227
|
+
# The available fields are:
|
228
|
+
# camera_info
|
229
|
+
#
|
230
|
+
# @param args: complete set of field values, in .msg order
|
231
|
+
# @param kwds: use keyword arguments corresponding to message field names
|
232
|
+
# to set specific fields.
|
233
|
+
#
|
234
|
+
|
235
|
+
# message fields cannot be None, assign default values for those that are
|
236
|
+
@camera_info = Sensor_msgs::CameraInfo.new
|
237
|
+
end
|
238
|
+
|
239
|
+
def _get_types
|
240
|
+
# internal API method
|
241
|
+
return @slot_types
|
242
|
+
end
|
243
|
+
|
244
|
+
def serialize(buff)
|
245
|
+
# serialize message into buffer
|
246
|
+
# @param buff: buffer
|
247
|
+
# @type buff: StringIO
|
248
|
+
begin
|
249
|
+
buff.write(@@struct_L3.pack(@camera_info.header.seq, @camera_info.header.stamp.secs, @camera_info.header.stamp.nsecs))
|
250
|
+
_x = @camera_info.header.frame_id
|
251
|
+
length = _x.length
|
252
|
+
buff.write([length, _x].pack("La#{length}"))
|
253
|
+
buff.write(@@struct_L2.pack(@camera_info.height, @camera_info.width))
|
254
|
+
_x = @camera_info.distortion_model
|
255
|
+
length = _x.length
|
256
|
+
buff.write([length, _x].pack("La#{length}"))
|
257
|
+
length = @camera_info.D.length
|
258
|
+
buff.write(@@struct_L.pack(length))
|
259
|
+
pattern = "d#{length}"
|
260
|
+
buff.write(*@camera_info.D.pack(pattern))
|
261
|
+
buff.write(@@struct_d9.pack(*@camera_info.K))
|
262
|
+
buff.write(@@struct_d9.pack(*@camera_info.R))
|
263
|
+
buff.write(@@struct_d12.pack(*@camera_info.P))
|
264
|
+
buff.write(@@struct_L6C.pack(@camera_info.binning_x, @camera_info.binning_y, @camera_info.roi.x_offset, @camera_info.roi.y_offset, @camera_info.roi.height, @camera_info.roi.width, @camera_info.roi.do_rectify))
|
265
|
+
rescue => exception
|
266
|
+
raise "some erro in serialize: #{exception}"
|
267
|
+
|
268
|
+
end
|
269
|
+
end
|
270
|
+
|
271
|
+
def deserialize(str)
|
272
|
+
# unpack serialized message in str into this message instance
|
273
|
+
# @param str: byte array of serialized message
|
274
|
+
# @type str: str
|
275
|
+
|
276
|
+
begin
|
277
|
+
if @camera_info == nil
|
278
|
+
@camera_info = Sensor_msgs::CameraInfo.new
|
279
|
+
end
|
280
|
+
end_point = 0
|
281
|
+
start = end_point
|
282
|
+
end_point += ROS::Struct::calc_size('L3')
|
283
|
+
(@camera_info.header.seq, @camera_info.header.stamp.secs, @camera_info.header.stamp.nsecs,) = @@struct_L3.unpack(str[start..(end_point-1)])
|
284
|
+
start = end_point
|
285
|
+
end_point += 4
|
286
|
+
(length,) = @@struct_L.unpack(str[start..(end_point-1)])
|
287
|
+
start = end_point
|
288
|
+
end_point += length
|
289
|
+
@camera_info.header.frame_id = str[start..(end_point-1)]
|
290
|
+
start = end_point
|
291
|
+
end_point += ROS::Struct::calc_size('L2')
|
292
|
+
(@camera_info.height, @camera_info.width,) = @@struct_L2.unpack(str[start..(end_point-1)])
|
293
|
+
start = end_point
|
294
|
+
end_point += 4
|
295
|
+
(length,) = @@struct_L.unpack(str[start..(end_point-1)])
|
296
|
+
start = end_point
|
297
|
+
end_point += length
|
298
|
+
@camera_info.distortion_model = str[start..(end_point-1)]
|
299
|
+
start = end_point
|
300
|
+
end_point += 4
|
301
|
+
(length,) = @@struct_L.unpack(str[start..(end_point-1)])
|
302
|
+
pattern = "d#{length}"
|
303
|
+
start = end_point
|
304
|
+
end_point += ROS::Struct::calc_size("#{pattern}")
|
305
|
+
@camera_info.D = str[start..(end_point-1)].unpack(pattern)
|
306
|
+
start = end_point
|
307
|
+
end_point += 8
|
308
|
+
@camera_info.K = @@struct_d9.unpack(str[start..(end_point-1)])
|
309
|
+
start = end_point
|
310
|
+
end_point += 8
|
311
|
+
@camera_info.R = @@struct_d9.unpack(str[start..(end_point-1)])
|
312
|
+
start = end_point
|
313
|
+
end_point += 8
|
314
|
+
@camera_info.P = @@struct_d12.unpack(str[start..(end_point-1)])
|
315
|
+
start = end_point
|
316
|
+
end_point += ROS::Struct::calc_size('L6C')
|
317
|
+
(@camera_info.binning_x, @camera_info.binning_y, @camera_info.roi.x_offset, @camera_info.roi.y_offset, @camera_info.roi.height, @camera_info.roi.width, @camera_info.roi.do_rectify,) = @@struct_L6C.unpack(str[start..(end_point-1)])
|
318
|
+
@camera_info.roi.do_rectify = bool(@camera_info.roi.do_rectify)
|
319
|
+
return self
|
320
|
+
rescue => exception
|
321
|
+
raise "message DeserializationError: #{exception}" #most likely buffer underfill
|
322
|
+
end
|
323
|
+
end
|
324
|
+
end # end of class
|
325
|
+
end # end of module
|
326
|
+
# autogenerated by genmsg_ruby from SetCameraInfoResponse.msg. Do not edit.
|
327
|
+
require 'ros/message'
|
328
|
+
|
329
|
+
|
330
|
+
module Sensor_msgs
|
331
|
+
|
332
|
+
class SetCameraInfoResponse <::ROS::Message
|
333
|
+
def self.md5sum
|
334
|
+
"2ec6f3eff0161f4257b808b12bc830c2"
|
335
|
+
end
|
336
|
+
|
337
|
+
def self.type
|
338
|
+
"sensor_msgs/SetCameraInfoResponse"
|
339
|
+
end
|
340
|
+
|
341
|
+
def has_header?
|
342
|
+
false
|
343
|
+
end
|
344
|
+
|
345
|
+
def message_definition
|
346
|
+
"bool success
|
347
|
+
string status_message
|
348
|
+
|
349
|
+
|
350
|
+
"
|
351
|
+
end
|
352
|
+
attr_accessor :success, :status_message
|
353
|
+
|
354
|
+
@@struct_C = ::ROS::Struct.new("C")
|
355
|
+
|
356
|
+
@@struct_L = ::ROS::Struct.new("L")
|
357
|
+
@@slot_types = ['bool','string']
|
358
|
+
|
359
|
+
def initialize
|
360
|
+
# Constructor. Any message fields that are implicitly/explicitly
|
361
|
+
# set to None will be assigned a default value. The recommend
|
362
|
+
# use is keyword arguments as this is more robust to future message
|
363
|
+
# changes. You cannot mix in-order arguments and keyword arguments.
|
364
|
+
#
|
365
|
+
# The available fields are:
|
366
|
+
# success,status_message
|
367
|
+
#
|
368
|
+
# @param args: complete set of field values, in .msg order
|
369
|
+
# @param kwds: use keyword arguments corresponding to message field names
|
370
|
+
# to set specific fields.
|
371
|
+
#
|
372
|
+
|
373
|
+
# message fields cannot be None, assign default values for those that are
|
374
|
+
@success = false
|
375
|
+
@status_message = ''
|
376
|
+
end
|
377
|
+
|
378
|
+
def _get_types
|
379
|
+
# internal API method
|
380
|
+
return @slot_types
|
381
|
+
end
|
382
|
+
|
383
|
+
def serialize(buff)
|
384
|
+
# serialize message into buffer
|
385
|
+
# @param buff: buffer
|
386
|
+
# @type buff: StringIO
|
387
|
+
begin
|
388
|
+
buff.write(@@struct_C.pack(@success))
|
389
|
+
_x = @status_message
|
390
|
+
length = _x.length
|
391
|
+
buff.write([length, _x].pack("La#{length}"))
|
392
|
+
rescue => exception
|
393
|
+
raise "some erro in serialize: #{exception}"
|
394
|
+
|
395
|
+
end
|
396
|
+
end
|
397
|
+
|
398
|
+
def deserialize(str)
|
399
|
+
# unpack serialized message in str into this message instance
|
400
|
+
# @param str: byte array of serialized message
|
401
|
+
# @type str: str
|
402
|
+
|
403
|
+
begin
|
404
|
+
end_point = 0
|
405
|
+
start = end_point
|
406
|
+
end_point += ROS::Struct::calc_size('C')
|
407
|
+
(@success,) = @@struct_C.unpack(str[start..(end_point-1)])
|
408
|
+
@success = bool(@success)
|
409
|
+
start = end_point
|
410
|
+
end_point += 4
|
411
|
+
(length,) = @@struct_L.unpack(str[start..(end_point-1)])
|
412
|
+
start = end_point
|
413
|
+
end_point += length
|
414
|
+
@status_message = str[start..(end_point-1)]
|
415
|
+
return self
|
416
|
+
rescue => exception
|
417
|
+
raise "message DeserializationError: #{exception}" #most likely buffer underfill
|
418
|
+
end
|
419
|
+
end
|
420
|
+
end # end of class
|
421
|
+
end # end of module
|
422
|
+
module Sensor_msgs
|
423
|
+
class SetCameraInfo
|
424
|
+
def self.type
|
425
|
+
'sensor_msgs/SetCameraInfo'
|
426
|
+
end
|
427
|
+
def self.md5sum
|
428
|
+
'bef1df590ed75ed1f393692395e15482'
|
429
|
+
end
|
430
|
+
def self.request_class
|
431
|
+
SetCameraInfoRequest
|
432
|
+
end
|
433
|
+
def self.response_class
|
434
|
+
SetCameraInfoResponse
|
435
|
+
end
|
436
|
+
end
|
437
|
+
end
|