Go to the documentation of this file.
17 #ifndef IGNITION_MSGS_UTILITY_HH_
18 #define IGNITION_MSGS_UTILITY_HH_
24 #include <ignition/math/AxisAlignedBox.hh>
25 #include <ignition/math/Color.hh>
26 #include <ignition/math/Inertial.hh>
27 #include <ignition/math/Pose3.hh>
28 #include <ignition/math/Plane.hh>
29 #include <ignition/math/SphericalCoordinates.hh>
30 #include <ignition/math/Vector3.hh>
75 math::Color
Convert(
const msgs::Color &_c);
94 math::SphericalCoordinates
Convert(
95 const msgs::SphericalCoordinates &_coord);
101 IGNITION_MSGS_VISIBLE
102 math::AxisAlignedBox
Convert(
const msgs::AxisAlignedBox &_b);
108 IGNITION_MSGS_VISIBLE
109 msgs::AxisAlignedBox
Convert(
const math::AxisAlignedBox &_b);
114 IGNITION_MSGS_VISIBLE
120 IGNITION_MSGS_VISIBLE
121 bool Convert(
const msgs::Boolean &_m);
126 IGNITION_MSGS_VISIBLE
127 int32_t
Convert(
const msgs::Int32 &_m);
132 IGNITION_MSGS_VISIBLE
133 uint32_t
Convert(
const msgs::UInt32 &_m);
138 IGNITION_MSGS_VISIBLE
139 int64_t
Convert(
const msgs::Int64 &_m);
144 IGNITION_MSGS_VISIBLE
145 uint64_t
Convert(
const msgs::UInt64 &_m);
150 IGNITION_MSGS_VISIBLE
151 double Convert(
const msgs::Double &_m);
156 IGNITION_MSGS_VISIBLE
157 float Convert(
const msgs::Float &_m);
162 IGNITION_MSGS_VISIBLE
163 std::chrono::steady_clock::duration
Convert(
const msgs::Time &_time);
168 IGNITION_MSGS_VISIBLE
174 IGNITION_MSGS_VISIBLE
180 IGNITION_MSGS_VISIBLE
186 IGNITION_MSGS_VISIBLE
192 IGNITION_MSGS_VISIBLE
193 msgs::Color
Convert(
const math::Color &_c);
198 IGNITION_MSGS_VISIBLE
204 IGNITION_MSGS_VISIBLE
211 IGNITION_MSGS_VISIBLE
212 msgs::SphericalCoordinates
Convert(
213 const math::SphericalCoordinates &_coord);
218 IGNITION_MSGS_VISIBLE
224 IGNITION_MSGS_VISIBLE
230 IGNITION_MSGS_VISIBLE
231 msgs::Boolean
Convert(
const bool &_b);
236 IGNITION_MSGS_VISIBLE
237 msgs::Int32
Convert(
const int32_t &_i);
242 IGNITION_MSGS_VISIBLE
243 msgs::UInt32
Convert(
const uint32_t &_u);
248 IGNITION_MSGS_VISIBLE
249 msgs::Int64
Convert(
const int64_t &_i);
254 IGNITION_MSGS_VISIBLE
255 msgs::UInt64
Convert(
const uint64_t &_u);
260 IGNITION_MSGS_VISIBLE
261 msgs::Double
Convert(
const double &_d);
266 IGNITION_MSGS_VISIBLE
267 msgs::Float
Convert(
const float &_f);
273 IGNITION_MSGS_VISIBLE
275 const std::chrono::steady_clock::duration &_time_point);
281 IGNITION_MSGS_VISIBLE
288 IGNITION_MSGS_VISIBLE
294 IGNITION_MSGS_VISIBLE
300 IGNITION_MSGS_VISIBLE
306 IGNITION_MSGS_VISIBLE
313 IGNITION_MSGS_VISIBLE
320 IGNITION_MSGS_VISIBLE
327 IGNITION_MSGS_VISIBLE
333 IGNITION_MSGS_VISIBLE
339 IGNITION_MSGS_VISIBLE
345 IGNITION_MSGS_VISIBLE
351 IGNITION_MSGS_VISIBLE
357 IGNITION_MSGS_VISIBLE
358 void Set(msgs::Color *_c,
const math::Color &_v);
363 IGNITION_MSGS_VISIBLE
369 IGNITION_MSGS_VISIBLE
376 IGNITION_MSGS_VISIBLE
377 void Set(msgs::SphericalCoordinates *_sc,
378 const math::SphericalCoordinates &_m);
383 IGNITION_MSGS_VISIBLE
389 IGNITION_MSGS_VISIBLE
395 IGNITION_MSGS_VISIBLE
396 void Set(msgs::Boolean *_p,
const bool &_v);
401 IGNITION_MSGS_VISIBLE
402 void Set(msgs::Int32 *_p,
const int32_t &_v);
407 IGNITION_MSGS_VISIBLE
408 void Set(msgs::UInt32 *_p,
const uint32_t &_v);
413 IGNITION_MSGS_VISIBLE
414 void Set(msgs::Int64 *_p,
const int64_t &_v);
419 IGNITION_MSGS_VISIBLE
420 void Set(msgs::UInt64 *_p,
const uint64_t &_v);
425 IGNITION_MSGS_VISIBLE
426 void Set(msgs::Double *_p,
const double &_v);
431 IGNITION_MSGS_VISIBLE
432 void Set(msgs::Float *_p,
const float &_v);
437 IGNITION_MSGS_VISIBLE
438 void Set(msgs::AxisAlignedBox *_b,
const math::AxisAlignedBox &_v);
455 IGNITION_MSGS_VISIBLE
465 IGNITION_MSGS_VISIBLE
479 IGNITION_MSGS_VISIBLE
481 msgs::FuelMetadata &_meta);
494 IGNITION_MSGS_VISIBLE
Geometry_Type Type
Definition: build/ignition-msgs8/include/ignition/msgs/geometry.pb.h:210
std::string ToString(const msgs::Discovery::Type &_t)
Convert a Discovery::Type to a string. This can be used for debugging purposes.
MassMatrix3< double > MassMatrix3d
msgs::PixelFormatType ConvertPixelFormatType(const std::string &_str)
Convert a string to a msgs::PixelFormatType enum.
void Set(msgs::Vector3d *_pt, const ignition::math::Vector3d &_v)
Set a msgs::Vector3d from an ignition::math::Vector3d.
msgs::Geometry::Type ConvertGeometryType(const std::string &_str)
Convert a string to a msgs::Geometry::Type enum.
msgs::Material::ShaderType ConvertShaderType(const std::string &_str)
Convert a string to a msgs::Material::ShaderType enum.
PointCloudPacked_Field_DataType DataType
Definition: build/ignition-msgs8/include/ignition/msgs/pointcloud_packed.pb.h:194
msgs::Joint::Type ConvertJointType(const std::string &_str)
Convert a string to a msgs::Joint::Type enum.
PixelFormatType
Definition: build/ignition-msgs8/include/ignition/msgs/image.pb.h:76
Inertial< double > Inertiald
Discovery_Type Type
Definition: build/ignition-msgs8/include/ignition/msgs/discovery.pb.h:982
#define IGNITION_MSGS_VERSION_NAMESPACE
Definition: build/ignition-msgs8/include/ignition/msgs/config.hh:11
ignition::math::Vector3d Convert(const msgs::Vector3d &_v)
Convert a msgs::Vector3d to an ignition::math::Vector.
bool ConvertFuelMetadata(const std::string &_modelConfigStr, msgs::FuelMetadata &_meta)
Convert the contents of a model.config file, in the form of an XML string, to a FuelMetadata message.
void InitPointCloudPacked(msgs::PointCloudPacked &_msg, const std::string &_frameId, bool _memoryAligned, const std::vector< std::pair< std::string, msgs::PointCloudPacked::Field::DataType >> &_fields)
This function will set the header and field members of a PointCloudPacked message....
Joint_Type Type
Definition: build/ignition-msgs8/include/ignition/msgs/joint.pb.h:425
Material_ShaderType ShaderType
Definition: build/ignition-msgs8/include/ignition/msgs/material.pb.h:663