From 4728c1d50f13e6601f540b7414f733e4901ba061 Mon Sep 17 00:00:00 2001 From: Mehmet Dogru <48479081+mehmetdogru@users.noreply.github.com> Date: Wed, 29 Mar 2023 13:20:02 +0300 Subject: [PATCH] fix(tier4_screen_capture_rviz_plugin): fix extra/missing naming components (#3207) Signed-off-by: Mehmet Dogru <42mehmetdogru42@gmail.com> --- .../src/screen_capture_panel.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/common/tier4_screen_capture_rviz_plugin/src/screen_capture_panel.cpp b/common/tier4_screen_capture_rviz_plugin/src/screen_capture_panel.cpp index 88fbdc483f89c..9e3ea7ed3ab4d 100644 --- a/common/tier4_screen_capture_rviz_plugin/src/screen_capture_panel.cpp +++ b/common/tier4_screen_capture_rviz_plugin/src/screen_capture_panel.cpp @@ -28,7 +28,7 @@ void setFormatDate(QLabel * line, double time) char buffer[128]; auto seconds = static_cast(time); strftime(buffer, sizeof(buffer), "%Y-%m-%d-%H-%M-%S", localtime(&seconds)); - line->setText(QString("- ") + QString(buffer) + QString(".mp4")); + line->setText(QString("- ") + QString(buffer)); } AutowareScreenCapturePanel::AutowareScreenCapturePanel(QWidget * parent) @@ -104,7 +104,8 @@ void AutowareScreenCapturePanel::onRateChanged() {} void AutowareScreenCapturePanel::onClickScreenCapture() { - const std::string time_text = "capture/" + ros_time_label_->text().toStdString(); + const std::string time_text = + "capture/" + file_name_prefix_->text().toStdString() + ros_time_label_->text().toStdString(); getDisplayContext()->getViewManager()->getRenderPanel()->getRenderWindow()->captureScreenShot( time_text + ".png"); }