Function etsi_its_cpm_ts_msgs::access::setUTMPositionOfPerceivedObject
Defined in File cpm_ts_setters.h
Function Documentation
-
inline void etsi_its_cpm_ts_msgs::access::setUTMPositionOfPerceivedObject(CollectivePerceptionMessage &cpm, PerceivedObject &object, const gm::PointStamped &utm_position, const uint16_t x_confidence = CoordinateConfidence::UNAVAILABLE, const uint16_t y_confidence = CoordinateConfidence::UNAVAILABLE, const uint16_t z_confidence = CoordinateConfidence::UNAVAILABLE)
Sets the position of a perceived object based on a UTM position.
This function sets the position of a perceived object using the provided UTM position and the CPM’s reference position. It also allows specifying confidence values for the x, y, and z coordinates.
- Parameters:
cpm – The CPM to get the reference position from.
object – The PerceivedObject to set the position for.
utm_position – gm::PointStamped representing the UTM position of the object including the frame_id (utm_<zone><N/S>).
x_confidence – The confidence value in meters for the x coordinate (default: CoordinateConfidence::UNAVAILABLE).
y_confidence – The confidence value in meters for the y coordinate (default: CoordinateConfidence::UNAVAILABLE).
z_confidence – The confidence value in meters for the z coordinate (default: CoordinateConfidence::UNAVAILABLE).
- Throws:
std::invalid_argument – if the UTM-Position frame_id does not match the reference position frame_id.