67
67
#include < regex>
68
68
#include < sstream>
69
69
70
- namespace awf_2d_overlay_vehicle
70
+ namespace autoware_vehicle_overlay_rviz_plugin
71
71
{
72
72
OverlayTextDisplay::OverlayTextDisplay ()
73
73
: texture_width_(0 ),
@@ -105,15 +105,15 @@ OverlayTextDisplay::OverlayTextDisplay()
105
105
hor_alignment_property_ = new rviz_common::properties::EnumProperty (
106
106
" hor_alignment" , " left" , " horizontal alignment of the overlay" , this ,
107
107
SLOT (updateHorizontalAlignment ()));
108
- hor_alignment_property_->addOption (" left" , rviz_2d_overlay_msgs ::msg::OverlayText::LEFT);
109
- hor_alignment_property_->addOption (" center" , rviz_2d_overlay_msgs ::msg::OverlayText::CENTER);
110
- hor_alignment_property_->addOption (" right" , rviz_2d_overlay_msgs ::msg::OverlayText::RIGHT);
108
+ hor_alignment_property_->addOption (" left" , autoware_overlay_msgs ::msg::OverlayText::LEFT);
109
+ hor_alignment_property_->addOption (" center" , autoware_overlay_msgs ::msg::OverlayText::CENTER);
110
+ hor_alignment_property_->addOption (" right" , autoware_overlay_msgs ::msg::OverlayText::RIGHT);
111
111
ver_alignment_property_ = new rviz_common::properties::EnumProperty (
112
112
" ver_alignment" , " top" , " vertical alignment of the overlay" , this ,
113
113
SLOT (updateVerticalAlignment ()));
114
- ver_alignment_property_->addOption (" top" , rviz_2d_overlay_msgs ::msg::OverlayText::TOP);
115
- ver_alignment_property_->addOption (" center" , rviz_2d_overlay_msgs ::msg::OverlayText::CENTER);
116
- ver_alignment_property_->addOption (" bottom" , rviz_2d_overlay_msgs ::msg::OverlayText::BOTTOM);
114
+ ver_alignment_property_->addOption (" top" , autoware_overlay_msgs ::msg::OverlayText::TOP);
115
+ ver_alignment_property_->addOption (" center" , autoware_overlay_msgs ::msg::OverlayText::CENTER);
116
+ ver_alignment_property_->addOption (" bottom" , autoware_overlay_msgs ::msg::OverlayText::BOTTOM);
117
117
width_property_ = new rviz_common::properties::IntProperty (
118
118
" width" , 128 , " width position" , this , SLOT (updateWidth ()));
119
119
width_property_->setMin (0 );
@@ -212,7 +212,7 @@ void OverlayTextDisplay::update(float /*wall_dt*/, float /*ros_dt*/)
212
212
213
213
overlay_->updateTextureSize (texture_width_, texture_height_);
214
214
{
215
- awf_2d_overlay_vehicle ::ScopedPixelBuffer buffer = overlay_->getBuffer ();
215
+ autoware_vehicle_overlay_rviz_plugin ::ScopedPixelBuffer buffer = overlay_->getBuffer ();
216
216
QImage Hud = buffer.getQImage (*overlay_, bg_color_);
217
217
QPainter painter (&Hud);
218
218
painter.setRenderHint (QPainter::Antialiasing, true );
@@ -288,7 +288,7 @@ void OverlayTextDisplay::reset()
288
288
}
289
289
}
290
290
291
- void OverlayTextDisplay::processMessage (rviz_2d_overlay_msgs ::msg::OverlayText::ConstSharedPtr msg)
291
+ void OverlayTextDisplay::processMessage (autoware_overlay_msgs ::msg::OverlayText::ConstSharedPtr msg)
292
292
{
293
293
if (!isEnabled ()) {
294
294
return ;
@@ -297,13 +297,13 @@ void OverlayTextDisplay::processMessage(rviz_2d_overlay_msgs::msg::OverlayText::
297
297
static int count = 0 ;
298
298
std::stringstream ss;
299
299
ss << " OverlayTextDisplayObject" << count++;
300
- overlay_.reset (new awf_2d_overlay_vehicle ::OverlayObject (ss.str ()));
300
+ overlay_.reset (new autoware_vehicle_overlay_rviz_plugin ::OverlayObject (ss.str ()));
301
301
overlay_->show ();
302
302
}
303
303
if (overlay_) {
304
- if (msg->action == rviz_2d_overlay_msgs ::msg::OverlayText::DELETE) {
304
+ if (msg->action == autoware_overlay_msgs ::msg::OverlayText::DELETE) {
305
305
overlay_->hide ();
306
- } else if (msg->action == rviz_2d_overlay_msgs ::msg::OverlayText::ADD) {
306
+ } else if (msg->action == autoware_overlay_msgs ::msg::OverlayText::ADD) {
307
307
overlay_->show ();
308
308
}
309
309
}
@@ -550,7 +550,8 @@ void OverlayTextDisplay::updateLineWidth()
550
550
}
551
551
}
552
552
553
- } // namespace awf_2d_overlay_vehicle
553
+ } // namespace autoware_vehicle_overlay_rviz_plugin
554
554
555
555
#include < pluginlib/class_list_macros.hpp>
556
- PLUGINLIB_EXPORT_CLASS (awf_2d_overlay_vehicle::OverlayTextDisplay, rviz_common::Display)
556
+ PLUGINLIB_EXPORT_CLASS (
557
+ autoware_vehicle_overlay_rviz_plugin::OverlayTextDisplay, rviz_common::Display)
0 commit comments