1 Star 0 Fork 9

zhangxingrong/rviz

forked from src-openEuler/rviz 
Create your Gitee Account
Explore and code with more than 12 million developers,Free private repositories !:)
Sign up
This repository doesn't specify license. Please pay attention to the specific project description and its upstream code dependency when using it.
Clone or Download
0004-MapDisplay-Fix-crash-after-map-update.patch 1.35 KB
Copy Edit Raw Blame History
zhangxingrong authored 2024-07-25 14:34 . add some upstream patchs
From 93ac44b26babb298046694efe78f8f986f7219e9 Mon Sep 17 00:00:00 2001
From: Stefan Fabian <github@stefanfabian.me>
Date: Thu, 25 May 2023 14:41:08 +0200
Subject: [PATCH] MapDisplay: Fix crash after map update (#1793)
---
src/rviz/default_plugin/map_display.cpp | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/rviz/default_plugin/map_display.cpp b/src/rviz/default_plugin/map_display.cpp
index 3d0841ad91..a7802e4861 100644
--- a/src/rviz/default_plugin/map_display.cpp
+++ b/src/rviz/default_plugin/map_display.cpp
@@ -221,7 +221,10 @@ void Swatch::updateData()
MapDisplay::MapDisplay() : Display(), loaded_(false), resolution_(0.0f), width_(0), height_(0)
{
- connect(this, SIGNAL(mapUpdated()), this, SLOT(showMap()));
+ // HACK: Using a direct connection triggers a segfault on NVIDIA hardware (#1793) when rendering
+ // *and* having performed a depth rendering before (e.g. due to raycasting for selections)
+ // A queued connection delays the update of renderables after the current VisualizationManager::onUpdate() call
+ connect(this, SIGNAL(mapUpdated()), this, SLOT(showMap()), Qt::QueuedConnection);
topic_property_ = new RosTopicProperty(
"Topic", "", QString::fromStdString(ros::message_traits::datatype<nav_msgs::OccupancyGrid>()),
"nav_msgs::OccupancyGrid topic to subscribe to.", this, SLOT(updateTopic()));
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/zhangxingrong/rviz.git
git@gitee.com:zhangxingrong/rviz.git
zhangxingrong
rviz
rviz
master

Search