convertVelocity3dWithConfidence.h
Go to the documentation of this file.
1 
55 #pragma once
56 
60 #ifdef ROS1
61 #include <etsi_its_denm_ts_msgs/Velocity3dWithConfidence.h>
62 namespace denm_ts_msgs = etsi_its_denm_ts_msgs;
63 #else
64 #include <etsi_its_denm_ts_msgs/msg/velocity3d_with_confidence.hpp>
65 namespace denm_ts_msgs = etsi_its_denm_ts_msgs::msg;
66 #endif
67 
68 
70 
71 void toRos_Velocity3dWithConfidence(const denm_ts_Velocity3dWithConfidence_t& in, denm_ts_msgs::Velocity3dWithConfidence& out) {
72  switch (in.present) {
74  toRos_VelocityPolarWithZ(in.choice.polarVelocity, out.polar_velocity);
75  out.choice = denm_ts_msgs::Velocity3dWithConfidence::CHOICE_POLAR_VELOCITY;
76  break;
78  toRos_VelocityCartesian(in.choice.cartesianVelocity, out.cartesian_velocity);
79  out.choice = denm_ts_msgs::Velocity3dWithConfidence::CHOICE_CARTESIAN_VELOCITY;
80  break;
81  default: break;
82  }
83 }
84 
85 void toStruct_Velocity3dWithConfidence(const denm_ts_msgs::Velocity3dWithConfidence& in, denm_ts_Velocity3dWithConfidence_t& out) {
86  memset(&out, 0, sizeof(denm_ts_Velocity3dWithConfidence_t));
87  switch (in.choice) {
88  case denm_ts_msgs::Velocity3dWithConfidence::CHOICE_POLAR_VELOCITY:
89  toStruct_VelocityPolarWithZ(in.polar_velocity, out.choice.polarVelocity);
90  out.present = denm_ts_Velocity3dWithConfidence_PR::denm_ts_Velocity3dWithConfidence_PR_polarVelocity;
91  break;
92  case denm_ts_msgs::Velocity3dWithConfidence::CHOICE_CARTESIAN_VELOCITY:
93  toStruct_VelocityCartesian(in.cartesian_velocity, out.choice.cartesianVelocity);
94  out.present = denm_ts_Velocity3dWithConfidence_PR::denm_ts_Velocity3dWithConfidence_PR_cartesianVelocity;
95  break;
96  default: break;
97  }
98 }
99 
100 }
etsi_its_denm_ts_conversion::toRos_Velocity3dWithConfidence
void toRos_Velocity3dWithConfidence(const denm_ts_Velocity3dWithConfidence_t &in, denm_ts_msgs::Velocity3dWithConfidence &out)
Definition: convertVelocity3dWithConfidence.h:71
denm_ts_Velocity3dWithConfidence::choice
union denm_ts_Velocity3dWithConfidence::denm_ts_Velocity3dWithConfidence_u choice
denm_ts_Velocity3dWithConfidence.h
denm_ts_Velocity3dWithConfidence::denm_ts_Velocity3dWithConfidence_u::polarVelocity
denm_ts_VelocityPolarWithZ_t polarVelocity
etsi_its_denm_ts_conversion::toStruct_Velocity3dWithConfidence
void toStruct_Velocity3dWithConfidence(const denm_ts_msgs::Velocity3dWithConfidence &in, denm_ts_Velocity3dWithConfidence_t &out)
Definition: convertVelocity3dWithConfidence.h:85
etsi_its_denm_ts_conversion::toStruct_VelocityCartesian
void toStruct_VelocityCartesian(const denm_ts_msgs::VelocityCartesian &in, denm_ts_VelocityCartesian_t &out)
Definition: convertVelocityCartesian.h:82
etsi_its_denm_ts_conversion
Definition: convertAcceleration3dWithConfidence.h:69
etsi_its_denm_ts_conversion::toStruct_VelocityPolarWithZ
void toStruct_VelocityPolarWithZ(const denm_ts_msgs::VelocityPolarWithZ &in, denm_ts_VelocityPolarWithZ_t &out)
Definition: convertVelocityPolarWithZ.h:84
denm_ts_Velocity3dWithConfidence_PR_cartesianVelocity
denm_ts_Velocity3dWithConfidence_PR_cartesianVelocity
denm_ts_Velocity3dWithConfidence
etsi_its_denm_ts_conversion::toRos_VelocityCartesian
void toRos_VelocityCartesian(const denm_ts_VelocityCartesian_t &in, denm_ts_msgs::VelocityCartesian &out)
Definition: convertVelocityCartesian.h:73
convertVelocityCartesian.h
denm_ts_Velocity3dWithConfidence_PR_polarVelocity
denm_ts_Velocity3dWithConfidence_PR_polarVelocity
convertVelocityPolarWithZ.h
denm_ts_Velocity3dWithConfidence::denm_ts_Velocity3dWithConfidence_u::cartesianVelocity
denm_ts_VelocityCartesian_t cartesianVelocity
denm_ts_Velocity3dWithConfidence::present
denm_ts_Velocity3dWithConfidence_PR present
etsi_its_denm_ts_conversion::toRos_VelocityPolarWithZ
void toRos_VelocityPolarWithZ(const denm_ts_VelocityPolarWithZ_t &in, denm_ts_msgs::VelocityPolarWithZ &out)
Definition: convertVelocityPolarWithZ.h:75


etsi_its_denm_ts_conversion
Author(s): Jean-Pierre Busch , Guido Küppers , Lennart Reiher
autogenerated on Sun May 18 2025 02:29:08