Carma-platform v4.2.0
CARMA Platform is built on robot operating system (ROS) and utilizes open source software (OSS) that enables Cooperative Driving Automation (CDA) features to allow Automated Driving Systems to interact and cooperate with infrastructure and other vehicles through communication.
object_visualizer_config.hpp
Go to the documentation of this file.
1#pragma once
2
3/*
4 * Copyright (C) 2022 LEIDOS.
5 *
6 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
7 * use this file except in compliance with the License. You may obtain a copy of
8 * the License at
9 *
10 * http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
14 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
15 * License for the specific language governing permissions and limitations under
16 * the License.
17 */
18
19#include <iostream>
20#include <vector>
21
23{
24
28 struct Config
29 {
32
35
36 // Unsigned int: Visualization marker shape: CUBE=1, SPHERE=2, CYLINDER=3
37 uint8_t marker_shape = 2;
38
40 std::string external_objects_viz_ns = "external_objects";
41
43 std::string roadway_obstacles_viz_ns = "roadway_obstacles";
44
47
49 std::string pedestrian_icon_path = "package://object_visualizer/meshes/pedestrian.stl";
50
53
54 // Stream operator for this config
55 friend std::ostream &operator<<(std::ostream &output, const Config &c)
56 {
57 output << "object_visualizer::Config { " << std::endl
58 << "enable_external_objects_viz: " << c.enable_external_objects_viz << std::endl
59 << "enable_roadway_objects_viz: " << c.enable_roadway_objects_viz << std::endl
60 << "external_objects_viz_ns: " << c.external_objects_viz_ns << std::endl
61 << "roadway_obstacles_viz_ns: " << c.roadway_obstacles_viz_ns << std::endl
62 << "marker_shape: " << static_cast<int>(c.marker_shape) << std::endl
63 << "use_pedestrian_icon: " << c.use_pedestrian_icon << std::endl
64 << "pedestrian_icon_path: " << c.pedestrian_icon_path << std::endl
65 << "pedestrian_icon_scale: " << c.pedestrian_icon_scale << std::endl
66 << "}" << std::endl;
67 return output;
68 }
69 };
70
71} // object_visualizer
Stuct containing the algorithm configuration values for object_visualizer.
std::string pedestrian_icon_path
Path to the model file for pedestrian visualization.
double pedestrian_icon_scale
Scale factor to apply to the pedestrian icon model.
std::string external_objects_viz_ns
External Objects marker rviz namespace.
friend std::ostream & operator<<(std::ostream &output, const Config &c)
bool enable_roadway_objects_viz
If true then RViz markers will be forwarded for received carma_perception_msgs/RoadwayObstacleList me...
bool enable_external_objects_viz
If true then RViz markers will be forwarded for received carma_perception_msgs/ExternalObjectList mes...
bool use_pedestrian_icon
If true, pedestrians will be visualized using specialized icons/models instead of basic markers.
std::string roadway_obstacles_viz_ns
Roadway Obstacles marker rviz namespace.