Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OccupancyGridStamped Rviz plugin crashed #25

Closed
fredd2409 opened this issue Aug 16, 2017 · 5 comments
Closed

OccupancyGridStamped Rviz plugin crashed #25

fredd2409 opened this issue Aug 16, 2017 · 5 comments

Comments

@fredd2409
Copy link

Hi, I'm publishing an OcTreeStamped and want to visualize it with RVIZ. However, when I set the topic /octomap for the plugin in RVIZ, RVIZ crashes completely. I've tried it on three different computers with Ubuntu 16.04 and ROS Kinetic. One computer gives "Segmentation fault (core dumped)". The other two only give "process has died [pid 4342, exit code -11...".

Is this a known issue?

@ahornung
Copy link
Member

ahornung commented Aug 16, 2017 via email

@fredd2409
Copy link
Author

I see. I assumed that there was because I can choose the plugin OccupancyGridStamped in RViz and also the code is templated to OcTreeStamped.

So is there are an obvious reason that this wouldn't work with OcTreeStamped? The data structures aren't fundamentally different (actually not at all?), right?

Via debugging, I've located that the segmentation fault occurs in this line:
std::size_t octree_depth = octomap->getTreeDepth();
(Line 492, occupancy_grid_display.cpp)
But the error only occurs with the OcTreeStamped, not with regular OcTree. On the other hand, the getTreeDepth() works fine with OcTreeStamped in other functions.

Any quick ideas? Otherwise I'll try to find a fix myself.

Thanks anyway for the quick reply!

@fredd2409
Copy link
Author

I found the problem. It's that octomap_msgs::msgToMap, or more specifically binaryMsgToMap does not handle OcTreeStamped but only OcTree and ColorOcTree and then returns null. Probably the same issue as here. It works when OcTreeStamped is added to that function.

@ploverpang
Copy link

I found the problem. It's that octomap_msgs::msgToMap, or more specifically binaryMsgToMap does not handle OcTreeStamped but only OcTree and ColorOcTree and then returns null. Probably the same issue as here. It works when OcTreeStamped is added to that function.

Does Anyone fix this bug?

@wxmerkt
Copy link
Member

wxmerkt commented Dec 30, 2019

Apparently it should be fixed, cf. OctoMap/octomap_msgs@2b390b6

Did you encounter this issue? And if so, what versions of octomap_rviz_plugins are you running on which platform?

@wxmerkt wxmerkt closed this as completed Apr 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants