rosruby_msgs 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- 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,325 @@
|
|
|
1
|
+
# autogenerated by genmsg_ruby from CameraInfo.msg. Do not edit.
|
|
2
|
+
require 'ros/message'
|
|
3
|
+
|
|
4
|
+
require "std_msgs/Header"
|
|
5
|
+
require "sensor_msgs/RegionOfInterest"
|
|
6
|
+
|
|
7
|
+
module Sensor_msgs
|
|
8
|
+
|
|
9
|
+
class CameraInfo <::ROS::Message
|
|
10
|
+
def self.md5sum
|
|
11
|
+
"c9a58c1b0b154e0e6da7578cb991d214"
|
|
12
|
+
end
|
|
13
|
+
|
|
14
|
+
def self.type
|
|
15
|
+
"sensor_msgs/CameraInfo"
|
|
16
|
+
end
|
|
17
|
+
|
|
18
|
+
def has_header?
|
|
19
|
+
true
|
|
20
|
+
end
|
|
21
|
+
|
|
22
|
+
def message_definition
|
|
23
|
+
"# This message defines meta information for a camera. It should be in a
|
|
24
|
+
# camera namespace on topic \"camera_info\" and accompanied by up to five
|
|
25
|
+
# image topics named:
|
|
26
|
+
#
|
|
27
|
+
# image_raw - raw data from the camera driver, possibly Bayer encoded
|
|
28
|
+
# image - monochrome, distorted
|
|
29
|
+
# image_color - color, distorted
|
|
30
|
+
# image_rect - monochrome, rectified
|
|
31
|
+
# image_rect_color - color, rectified
|
|
32
|
+
#
|
|
33
|
+
# The image_pipeline contains packages (image_proc, stereo_image_proc)
|
|
34
|
+
# for producing the four processed image topics from image_raw and
|
|
35
|
+
# camera_info. The meaning of the camera parameters are described in
|
|
36
|
+
# detail at http://www.ros.org/wiki/image_pipeline/CameraInfo.
|
|
37
|
+
#
|
|
38
|
+
# The image_geometry package provides a user-friendly interface to
|
|
39
|
+
# common operations using this meta information. If you want to, e.g.,
|
|
40
|
+
# project a 3d point into image coordinates, we strongly recommend
|
|
41
|
+
# using image_geometry.
|
|
42
|
+
#
|
|
43
|
+
# If the camera is uncalibrated, the matrices D, K, R, P should be left
|
|
44
|
+
# zeroed out. In particular, clients may assume that K[0] == 0.0
|
|
45
|
+
# indicates an uncalibrated camera.
|
|
46
|
+
|
|
47
|
+
#######################################################################
|
|
48
|
+
# Image acquisition info #
|
|
49
|
+
#######################################################################
|
|
50
|
+
|
|
51
|
+
# Time of image acquisition, camera coordinate frame ID
|
|
52
|
+
Header header # Header timestamp should be acquisition time of image
|
|
53
|
+
# Header frame_id should be optical frame of camera
|
|
54
|
+
# origin of frame should be optical center of camera
|
|
55
|
+
# +x should point to the right in the image
|
|
56
|
+
# +y should point down in the image
|
|
57
|
+
# +z should point into the plane of the image
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
#######################################################################
|
|
61
|
+
# Calibration Parameters #
|
|
62
|
+
#######################################################################
|
|
63
|
+
# These are fixed during camera calibration. Their values will be the #
|
|
64
|
+
# same in all messages until the camera is recalibrated. Note that #
|
|
65
|
+
# self-calibrating systems may \"recalibrate\" frequently. #
|
|
66
|
+
# #
|
|
67
|
+
# The internal parameters can be used to warp a raw (distorted) image #
|
|
68
|
+
# to: #
|
|
69
|
+
# 1. An undistorted image (requires D and K) #
|
|
70
|
+
# 2. A rectified image (requires D, K, R) #
|
|
71
|
+
# The projection matrix P projects 3D points into the rectified image.#
|
|
72
|
+
#######################################################################
|
|
73
|
+
|
|
74
|
+
# The image dimensions with which the camera was calibrated. Normally
|
|
75
|
+
# this will be the full camera resolution in pixels.
|
|
76
|
+
uint32 height
|
|
77
|
+
uint32 width
|
|
78
|
+
|
|
79
|
+
# The distortion model used. Supported models are listed in
|
|
80
|
+
# sensor_msgs/distortion_models.h. For most cameras, \"plumb_bob\" - a
|
|
81
|
+
# simple model of radial and tangential distortion - is sufficent.
|
|
82
|
+
string distortion_model
|
|
83
|
+
|
|
84
|
+
# The distortion parameters, size depending on the distortion model.
|
|
85
|
+
# For \"plumb_bob\", the 5 parameters are: (k1, k2, t1, t2, k3).
|
|
86
|
+
float64[] D
|
|
87
|
+
|
|
88
|
+
# Intrinsic camera matrix for the raw (distorted) images.
|
|
89
|
+
# [fx 0 cx]
|
|
90
|
+
# K = [ 0 fy cy]
|
|
91
|
+
# [ 0 0 1]
|
|
92
|
+
# Projects 3D points in the camera coordinate frame to 2D pixel
|
|
93
|
+
# coordinates using the focal lengths (fx, fy) and principal point
|
|
94
|
+
# (cx, cy).
|
|
95
|
+
float64[9] K # 3x3 row-major matrix
|
|
96
|
+
|
|
97
|
+
# Rectification matrix (stereo cameras only)
|
|
98
|
+
# A rotation matrix aligning the camera coordinate system to the ideal
|
|
99
|
+
# stereo image plane so that epipolar lines in both stereo images are
|
|
100
|
+
# parallel.
|
|
101
|
+
float64[9] R # 3x3 row-major matrix
|
|
102
|
+
|
|
103
|
+
# Projection/camera matrix
|
|
104
|
+
# [fx' 0 cx' Tx]
|
|
105
|
+
# P = [ 0 fy' cy' Ty]
|
|
106
|
+
# [ 0 0 1 0]
|
|
107
|
+
# By convention, this matrix specifies the intrinsic (camera) matrix
|
|
108
|
+
# of the processed (rectified) image. That is, the left 3x3 portion
|
|
109
|
+
# is the normal camera intrinsic matrix for the rectified image.
|
|
110
|
+
# It projects 3D points in the camera coordinate frame to 2D pixel
|
|
111
|
+
# coordinates using the focal lengths (fx', fy') and principal point
|
|
112
|
+
# (cx', cy') - these may differ from the values in K.
|
|
113
|
+
# For monocular cameras, Tx = Ty = 0. Normally, monocular cameras will
|
|
114
|
+
# also have R = the identity and P[1:3,1:3] = K.
|
|
115
|
+
# For a stereo pair, the fourth column [Tx Ty 0]' is related to the
|
|
116
|
+
# position of the optical center of the second camera in the first
|
|
117
|
+
# camera's frame. We assume Tz = 0 so both cameras are in the same
|
|
118
|
+
# stereo image plane. The first camera always has Tx = Ty = 0. For
|
|
119
|
+
# the right (second) camera of a horizontal stereo pair, Ty = 0 and
|
|
120
|
+
# Tx = -fx' * B, where B is the baseline between the cameras.
|
|
121
|
+
# Given a 3D point [X Y Z]', the projection (x, y) of the point onto
|
|
122
|
+
# the rectified image is given by:
|
|
123
|
+
# [u v w]' = P * [X Y Z 1]'
|
|
124
|
+
# x = u / w
|
|
125
|
+
# y = v / w
|
|
126
|
+
# This holds for both images of a stereo pair.
|
|
127
|
+
float64[12] P # 3x4 row-major matrix
|
|
128
|
+
|
|
129
|
+
|
|
130
|
+
#######################################################################
|
|
131
|
+
# Operational Parameters #
|
|
132
|
+
#######################################################################
|
|
133
|
+
# These define the image region actually captured by the camera #
|
|
134
|
+
# driver. Although they affect the geometry of the output image, they #
|
|
135
|
+
# may be changed freely without recalibrating the camera. #
|
|
136
|
+
#######################################################################
|
|
137
|
+
|
|
138
|
+
# Binning refers here to any camera setting which combines rectangular
|
|
139
|
+
# neighborhoods of pixels into larger \"super-pixels.\" It reduces the
|
|
140
|
+
# resolution of the output image to
|
|
141
|
+
# (width / binning_x) x (height / binning_y).
|
|
142
|
+
# The default values binning_x = binning_y = 0 is considered the same
|
|
143
|
+
# as binning_x = binning_y = 1 (no subsampling).
|
|
144
|
+
uint32 binning_x
|
|
145
|
+
uint32 binning_y
|
|
146
|
+
|
|
147
|
+
# Region of interest (subwindow of full camera resolution), given in
|
|
148
|
+
# full resolution (unbinned) image coordinates. A particular ROI
|
|
149
|
+
# always denotes the same window of pixels on the camera sensor,
|
|
150
|
+
# regardless of binning settings.
|
|
151
|
+
# The default setting of roi (all values 0) is considered the same as
|
|
152
|
+
# full resolution (roi.width = width, roi.height = height).
|
|
153
|
+
RegionOfInterest roi
|
|
154
|
+
|
|
155
|
+
================================================================================
|
|
156
|
+
MSG: std_msgs/Header
|
|
157
|
+
# Standard metadata for higher-level stamped data types.
|
|
158
|
+
# This is generally used to communicate timestamped data
|
|
159
|
+
# in a particular coordinate frame.
|
|
160
|
+
#
|
|
161
|
+
# sequence ID: consecutively increasing ID
|
|
162
|
+
uint32 seq
|
|
163
|
+
#Two-integer timestamp that is expressed as:
|
|
164
|
+
# * stamp.secs: seconds (stamp_secs) since epoch
|
|
165
|
+
# * stamp.nsecs: nanoseconds since stamp_secs
|
|
166
|
+
# time-handling sugar is provided by the client library
|
|
167
|
+
time stamp
|
|
168
|
+
#Frame this data is associated with
|
|
169
|
+
# 0: no frame
|
|
170
|
+
# 1: global frame
|
|
171
|
+
string frame_id
|
|
172
|
+
|
|
173
|
+
================================================================================
|
|
174
|
+
MSG: sensor_msgs/RegionOfInterest
|
|
175
|
+
# This message is used to specify a region of interest within an image.
|
|
176
|
+
#
|
|
177
|
+
# When used to specify the ROI setting of the camera when the image was
|
|
178
|
+
# taken, the height and width fields should either match the height and
|
|
179
|
+
# width fields for the associated image; or height = width = 0
|
|
180
|
+
# indicates that the full resolution image was captured.
|
|
181
|
+
|
|
182
|
+
uint32 x_offset # Leftmost pixel of the ROI
|
|
183
|
+
# (0 if the ROI includes the left edge of the image)
|
|
184
|
+
uint32 y_offset # Topmost pixel of the ROI
|
|
185
|
+
# (0 if the ROI includes the top edge of the image)
|
|
186
|
+
uint32 height # Height of ROI
|
|
187
|
+
uint32 width # Width of ROI
|
|
188
|
+
|
|
189
|
+
# True if a distinct rectified ROI should be calculated from the \"raw\"
|
|
190
|
+
# ROI in this message. Typically this should be False if the full image
|
|
191
|
+
# is captured (ROI not used), and True if a subwindow is captured (ROI
|
|
192
|
+
# used).
|
|
193
|
+
bool do_rectify
|
|
194
|
+
|
|
195
|
+
"
|
|
196
|
+
end
|
|
197
|
+
attr_accessor :header, :height, :width, :distortion_model, :D, :K, :R, :P, :binning_x, :binning_y, :roi
|
|
198
|
+
|
|
199
|
+
@@struct_L6C = ::ROS::Struct.new("L6C")
|
|
200
|
+
@@struct_L3 = ::ROS::Struct.new("L3")
|
|
201
|
+
@@struct_d12 = ::ROS::Struct.new("d12")
|
|
202
|
+
@@struct_L2 = ::ROS::Struct.new("L2")
|
|
203
|
+
@@struct_d9 = ::ROS::Struct.new("d9")
|
|
204
|
+
|
|
205
|
+
@@struct_L = ::ROS::Struct.new("L")
|
|
206
|
+
@@slot_types = ['Header','uint32','uint32','string','float64[]','float64[9]','float64[9]','float64[12]','uint32','uint32','sensor_msgs/RegionOfInterest']
|
|
207
|
+
|
|
208
|
+
def initialize
|
|
209
|
+
# Constructor. Any message fields that are implicitly/explicitly
|
|
210
|
+
# set to None will be assigned a default value. The recommend
|
|
211
|
+
# use is keyword arguments as this is more robust to future message
|
|
212
|
+
# changes. You cannot mix in-order arguments and keyword arguments.
|
|
213
|
+
#
|
|
214
|
+
# The available fields are:
|
|
215
|
+
# header,height,width,distortion_model,D,K,R,P,binning_x,binning_y,roi
|
|
216
|
+
#
|
|
217
|
+
# @param args: complete set of field values, in .msg order
|
|
218
|
+
# @param kwds: use keyword arguments corresponding to message field names
|
|
219
|
+
# to set specific fields.
|
|
220
|
+
#
|
|
221
|
+
|
|
222
|
+
# message fields cannot be None, assign default values for those that are
|
|
223
|
+
@header = Std_msgs::Header.new
|
|
224
|
+
@height = 0
|
|
225
|
+
@width = 0
|
|
226
|
+
@distortion_model = ''
|
|
227
|
+
@D = []
|
|
228
|
+
@K = [0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0]
|
|
229
|
+
@R = [0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0]
|
|
230
|
+
@P = [0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0]
|
|
231
|
+
@binning_x = 0
|
|
232
|
+
@binning_y = 0
|
|
233
|
+
@roi = Sensor_msgs::RegionOfInterest.new
|
|
234
|
+
end
|
|
235
|
+
|
|
236
|
+
def _get_types
|
|
237
|
+
# internal API method
|
|
238
|
+
return @slot_types
|
|
239
|
+
end
|
|
240
|
+
|
|
241
|
+
def serialize(buff)
|
|
242
|
+
# serialize message into buffer
|
|
243
|
+
# @param buff: buffer
|
|
244
|
+
# @type buff: StringIO
|
|
245
|
+
begin
|
|
246
|
+
buff.write(@@struct_L3.pack(@header.seq, @header.stamp.secs, @header.stamp.nsecs))
|
|
247
|
+
_x = @header.frame_id
|
|
248
|
+
length = _x.length
|
|
249
|
+
buff.write([length, _x].pack("La#{length}"))
|
|
250
|
+
buff.write(@@struct_L2.pack(@height, @width))
|
|
251
|
+
_x = @distortion_model
|
|
252
|
+
length = _x.length
|
|
253
|
+
buff.write([length, _x].pack("La#{length}"))
|
|
254
|
+
length = @D.length
|
|
255
|
+
buff.write(@@struct_L.pack(length))
|
|
256
|
+
pattern = "d#{length}"
|
|
257
|
+
buff.write(*@D.pack(pattern))
|
|
258
|
+
buff.write(@@struct_d9.pack(*@K))
|
|
259
|
+
buff.write(@@struct_d9.pack(*@R))
|
|
260
|
+
buff.write(@@struct_d12.pack(*@P))
|
|
261
|
+
buff.write(@@struct_L6C.pack(@binning_x, @binning_y, @roi.x_offset, @roi.y_offset, @roi.height, @roi.width, @roi.do_rectify))
|
|
262
|
+
rescue => exception
|
|
263
|
+
raise "some erro in serialize: #{exception}"
|
|
264
|
+
|
|
265
|
+
end
|
|
266
|
+
end
|
|
267
|
+
|
|
268
|
+
def deserialize(str)
|
|
269
|
+
# unpack serialized message in str into this message instance
|
|
270
|
+
# @param str: byte array of serialized message
|
|
271
|
+
# @type str: str
|
|
272
|
+
|
|
273
|
+
begin
|
|
274
|
+
if @header == nil
|
|
275
|
+
@header = Std_msgs::Header.new
|
|
276
|
+
end
|
|
277
|
+
if @roi == nil
|
|
278
|
+
@roi = Sensor_msgs::RegionOfInterest.new
|
|
279
|
+
end
|
|
280
|
+
end_point = 0
|
|
281
|
+
start = end_point
|
|
282
|
+
end_point += ROS::Struct::calc_size('L3')
|
|
283
|
+
(@header.seq, @header.stamp.secs, @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
|
+
@header.frame_id = str[start..(end_point-1)]
|
|
290
|
+
start = end_point
|
|
291
|
+
end_point += ROS::Struct::calc_size('L2')
|
|
292
|
+
(@height, @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
|
+
@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
|
+
@D = str[start..(end_point-1)].unpack(pattern)
|
|
306
|
+
start = end_point
|
|
307
|
+
end_point += 8
|
|
308
|
+
@K = @@struct_d9.unpack(str[start..(end_point-1)])
|
|
309
|
+
start = end_point
|
|
310
|
+
end_point += 8
|
|
311
|
+
@R = @@struct_d9.unpack(str[start..(end_point-1)])
|
|
312
|
+
start = end_point
|
|
313
|
+
end_point += 8
|
|
314
|
+
@P = @@struct_d12.unpack(str[start..(end_point-1)])
|
|
315
|
+
start = end_point
|
|
316
|
+
end_point += ROS::Struct::calc_size('L6C')
|
|
317
|
+
(@binning_x, @binning_y, @roi.x_offset, @roi.y_offset, @roi.height, @roi.width, @roi.do_rectify,) = @@struct_L6C.unpack(str[start..(end_point-1)])
|
|
318
|
+
@roi.do_rectify = bool(@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
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
# autogenerated by genmsg_ruby from ChannelFloat32.msg. Do not edit.
|
|
2
|
+
require 'ros/message'
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
module Sensor_msgs
|
|
6
|
+
|
|
7
|
+
class ChannelFloat32 <::ROS::Message
|
|
8
|
+
def self.md5sum
|
|
9
|
+
"3d40139cdd33dfedcb71ffeeeb42ae7f"
|
|
10
|
+
end
|
|
11
|
+
|
|
12
|
+
def self.type
|
|
13
|
+
"sensor_msgs/ChannelFloat32"
|
|
14
|
+
end
|
|
15
|
+
|
|
16
|
+
def has_header?
|
|
17
|
+
false
|
|
18
|
+
end
|
|
19
|
+
|
|
20
|
+
def message_definition
|
|
21
|
+
"# This message is used by the PointCloud message to hold optional data
|
|
22
|
+
# associated with each point in the cloud. The length of the values
|
|
23
|
+
# array should be the same as the length of the points array in the
|
|
24
|
+
# PointCloud, and each value should be associated with the corresponding
|
|
25
|
+
# point.
|
|
26
|
+
|
|
27
|
+
# Channel names in existing practice include:
|
|
28
|
+
# \"u\", \"v\" - row and column (respectively) in the left stereo image.
|
|
29
|
+
# This is opposite to usual conventions but remains for
|
|
30
|
+
# historical reasons. The newer PointCloud2 message has no
|
|
31
|
+
# such problem.
|
|
32
|
+
# \"rgb\" - For point clouds produced by color stereo cameras. uint8
|
|
33
|
+
# (R,G,B) values packed into the least significant 24 bits,
|
|
34
|
+
# in order.
|
|
35
|
+
# \"intensity\" - laser or pixel intensity.
|
|
36
|
+
# \"distance\"
|
|
37
|
+
|
|
38
|
+
# The channel name should give semantics of the channel (e.g.
|
|
39
|
+
# \"intensity\" instead of \"value\").
|
|
40
|
+
string name
|
|
41
|
+
|
|
42
|
+
# The values array should be 1-1 with the elements of the associated
|
|
43
|
+
# PointCloud.
|
|
44
|
+
float32[] values
|
|
45
|
+
|
|
46
|
+
"
|
|
47
|
+
end
|
|
48
|
+
attr_accessor :name, :values
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
@@struct_L = ::ROS::Struct.new("L")
|
|
52
|
+
@@slot_types = ['string','float32[]']
|
|
53
|
+
|
|
54
|
+
def initialize
|
|
55
|
+
# Constructor. Any message fields that are implicitly/explicitly
|
|
56
|
+
# set to None will be assigned a default value. The recommend
|
|
57
|
+
# use is keyword arguments as this is more robust to future message
|
|
58
|
+
# changes. You cannot mix in-order arguments and keyword arguments.
|
|
59
|
+
#
|
|
60
|
+
# The available fields are:
|
|
61
|
+
# name,values
|
|
62
|
+
#
|
|
63
|
+
# @param args: complete set of field values, in .msg order
|
|
64
|
+
# @param kwds: use keyword arguments corresponding to message field names
|
|
65
|
+
# to set specific fields.
|
|
66
|
+
#
|
|
67
|
+
|
|
68
|
+
# message fields cannot be None, assign default values for those that are
|
|
69
|
+
@name = ''
|
|
70
|
+
@values = []
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
def _get_types
|
|
74
|
+
# internal API method
|
|
75
|
+
return @slot_types
|
|
76
|
+
end
|
|
77
|
+
|
|
78
|
+
def serialize(buff)
|
|
79
|
+
# serialize message into buffer
|
|
80
|
+
# @param buff: buffer
|
|
81
|
+
# @type buff: StringIO
|
|
82
|
+
begin
|
|
83
|
+
_x = @name
|
|
84
|
+
length = _x.length
|
|
85
|
+
buff.write([length, _x].pack("La#{length}"))
|
|
86
|
+
length = @values.length
|
|
87
|
+
buff.write(@@struct_L.pack(length))
|
|
88
|
+
pattern = "f#{length}"
|
|
89
|
+
buff.write(*@values.pack(pattern))
|
|
90
|
+
rescue => exception
|
|
91
|
+
raise "some erro in serialize: #{exception}"
|
|
92
|
+
|
|
93
|
+
end
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
def deserialize(str)
|
|
97
|
+
# unpack serialized message in str into this message instance
|
|
98
|
+
# @param str: byte array of serialized message
|
|
99
|
+
# @type str: str
|
|
100
|
+
|
|
101
|
+
begin
|
|
102
|
+
end_point = 0
|
|
103
|
+
start = end_point
|
|
104
|
+
end_point += 4
|
|
105
|
+
(length,) = @@struct_L.unpack(str[start..(end_point-1)])
|
|
106
|
+
start = end_point
|
|
107
|
+
end_point += length
|
|
108
|
+
@name = str[start..(end_point-1)]
|
|
109
|
+
start = end_point
|
|
110
|
+
end_point += 4
|
|
111
|
+
(length,) = @@struct_L.unpack(str[start..(end_point-1)])
|
|
112
|
+
pattern = "f#{length}"
|
|
113
|
+
start = end_point
|
|
114
|
+
end_point += ROS::Struct::calc_size("#{pattern}")
|
|
115
|
+
@values = str[start..(end_point-1)].unpack(pattern)
|
|
116
|
+
return self
|
|
117
|
+
rescue => exception
|
|
118
|
+
raise "message DeserializationError: #{exception}" #most likely buffer underfill
|
|
119
|
+
end
|
|
120
|
+
end
|
|
121
|
+
end # end of class
|
|
122
|
+
end # end of module
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
# autogenerated by genmsg_ruby from CompressedImage.msg. Do not edit.
|
|
2
|
+
require 'ros/message'
|
|
3
|
+
|
|
4
|
+
require "std_msgs/Header"
|
|
5
|
+
|
|
6
|
+
module Sensor_msgs
|
|
7
|
+
|
|
8
|
+
class CompressedImage <::ROS::Message
|
|
9
|
+
def self.md5sum
|
|
10
|
+
"8f7a12909da2c9d3332d540a0977563f"
|
|
11
|
+
end
|
|
12
|
+
|
|
13
|
+
def self.type
|
|
14
|
+
"sensor_msgs/CompressedImage"
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
def has_header?
|
|
18
|
+
true
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
def message_definition
|
|
22
|
+
"# This message contains a compressed image
|
|
23
|
+
|
|
24
|
+
Header header # Header timestamp should be acquisition time of image
|
|
25
|
+
# Header frame_id should be optical frame of camera
|
|
26
|
+
# origin of frame should be optical center of cameara
|
|
27
|
+
# +x should point to the right in the image
|
|
28
|
+
# +y should point down in the image
|
|
29
|
+
# +z should point into to plane of the image
|
|
30
|
+
|
|
31
|
+
string format # Specifies the format of the data
|
|
32
|
+
# Acceptable values:
|
|
33
|
+
# jpeg, png
|
|
34
|
+
uint8[] data # Compressed image buffer
|
|
35
|
+
|
|
36
|
+
================================================================================
|
|
37
|
+
MSG: std_msgs/Header
|
|
38
|
+
# Standard metadata for higher-level stamped data types.
|
|
39
|
+
# This is generally used to communicate timestamped data
|
|
40
|
+
# in a particular coordinate frame.
|
|
41
|
+
#
|
|
42
|
+
# sequence ID: consecutively increasing ID
|
|
43
|
+
uint32 seq
|
|
44
|
+
#Two-integer timestamp that is expressed as:
|
|
45
|
+
# * stamp.secs: seconds (stamp_secs) since epoch
|
|
46
|
+
# * stamp.nsecs: nanoseconds since stamp_secs
|
|
47
|
+
# time-handling sugar is provided by the client library
|
|
48
|
+
time stamp
|
|
49
|
+
#Frame this data is associated with
|
|
50
|
+
# 0: no frame
|
|
51
|
+
# 1: global frame
|
|
52
|
+
string frame_id
|
|
53
|
+
|
|
54
|
+
"
|
|
55
|
+
end
|
|
56
|
+
attr_accessor :header, :format, :data
|
|
57
|
+
|
|
58
|
+
@@struct_L3 = ::ROS::Struct.new("L3")
|
|
59
|
+
|
|
60
|
+
@@struct_L = ::ROS::Struct.new("L")
|
|
61
|
+
@@slot_types = ['Header','string','uint8[]']
|
|
62
|
+
|
|
63
|
+
def initialize
|
|
64
|
+
# Constructor. Any message fields that are implicitly/explicitly
|
|
65
|
+
# set to None will be assigned a default value. The recommend
|
|
66
|
+
# use is keyword arguments as this is more robust to future message
|
|
67
|
+
# changes. You cannot mix in-order arguments and keyword arguments.
|
|
68
|
+
#
|
|
69
|
+
# The available fields are:
|
|
70
|
+
# header,format,data
|
|
71
|
+
#
|
|
72
|
+
# @param args: complete set of field values, in .msg order
|
|
73
|
+
# @param kwds: use keyword arguments corresponding to message field names
|
|
74
|
+
# to set specific fields.
|
|
75
|
+
#
|
|
76
|
+
|
|
77
|
+
# message fields cannot be None, assign default values for those that are
|
|
78
|
+
@header = Std_msgs::Header.new
|
|
79
|
+
@format = ''
|
|
80
|
+
@data = ''
|
|
81
|
+
end
|
|
82
|
+
|
|
83
|
+
def _get_types
|
|
84
|
+
# internal API method
|
|
85
|
+
return @slot_types
|
|
86
|
+
end
|
|
87
|
+
|
|
88
|
+
def serialize(buff)
|
|
89
|
+
# serialize message into buffer
|
|
90
|
+
# @param buff: buffer
|
|
91
|
+
# @type buff: StringIO
|
|
92
|
+
begin
|
|
93
|
+
buff.write(@@struct_L3.pack(@header.seq, @header.stamp.secs, @header.stamp.nsecs))
|
|
94
|
+
_x = @header.frame_id
|
|
95
|
+
length = _x.length
|
|
96
|
+
buff.write([length, _x].pack("La#{length}"))
|
|
97
|
+
_x = @format
|
|
98
|
+
length = _x.length
|
|
99
|
+
buff.write([length, _x].pack("La#{length}"))
|
|
100
|
+
_x = @data
|
|
101
|
+
length = _x.length
|
|
102
|
+
# - if encoded as a list instead, serialize as bytes instead of string
|
|
103
|
+
if type(_x) in [list, tuple]
|
|
104
|
+
buff.write([length, *_x].pack("La#{length}"))
|
|
105
|
+
else
|
|
106
|
+
buff.write([length, _x].pack("La#{length}"))
|
|
107
|
+
end
|
|
108
|
+
rescue => exception
|
|
109
|
+
raise "some erro in serialize: #{exception}"
|
|
110
|
+
|
|
111
|
+
end
|
|
112
|
+
end
|
|
113
|
+
|
|
114
|
+
def deserialize(str)
|
|
115
|
+
# unpack serialized message in str into this message instance
|
|
116
|
+
# @param str: byte array of serialized message
|
|
117
|
+
# @type str: str
|
|
118
|
+
|
|
119
|
+
begin
|
|
120
|
+
if @header == nil
|
|
121
|
+
@header = Std_msgs::Header.new
|
|
122
|
+
end
|
|
123
|
+
end_point = 0
|
|
124
|
+
start = end_point
|
|
125
|
+
end_point += ROS::Struct::calc_size('L3')
|
|
126
|
+
(@header.seq, @header.stamp.secs, @header.stamp.nsecs,) = @@struct_L3.unpack(str[start..(end_point-1)])
|
|
127
|
+
start = end_point
|
|
128
|
+
end_point += 4
|
|
129
|
+
(length,) = @@struct_L.unpack(str[start..(end_point-1)])
|
|
130
|
+
start = end_point
|
|
131
|
+
end_point += length
|
|
132
|
+
@header.frame_id = str[start..(end_point-1)]
|
|
133
|
+
start = end_point
|
|
134
|
+
end_point += 4
|
|
135
|
+
(length,) = @@struct_L.unpack(str[start..(end_point-1)])
|
|
136
|
+
start = end_point
|
|
137
|
+
end_point += length
|
|
138
|
+
@format = str[start..(end_point-1)]
|
|
139
|
+
start = end_point
|
|
140
|
+
end_point += 4
|
|
141
|
+
(length,) = @@struct_L.unpack(str[start..(end_point-1)])
|
|
142
|
+
start = end_point
|
|
143
|
+
end_point += length
|
|
144
|
+
@data = str[start..(end_point-1)]
|
|
145
|
+
return self
|
|
146
|
+
rescue => exception
|
|
147
|
+
raise "message DeserializationError: #{exception}" #most likely buffer underfill
|
|
148
|
+
end
|
|
149
|
+
end
|
|
150
|
+
end # end of class
|
|
151
|
+
end # end of module
|