-
Notifications
You must be signed in to change notification settings - Fork 672
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
Issue with deleteNode when deleting all nodes #307
Comments
If my question isn't clear, this is what I mean by deleting all nodes:
If we delete all nodes using the method above, there will be one remaining node in the tree that is impossible to delete (the root) |
Yes, this seems like an omission that should be fixed. Looking at the implementation of clear, there's no reason not to delete the root as well. |
I haven't tested it yet, but PR #288 should fix this as well. Does that work for you? |
Looking back at the changelog, this issue was fixed long ago with #11 (v1.6.0) and it's probably a regression. |
I am running on |
I have the same issu, and when I delete all nodes, I try to updateNode failed. |
I have implemented a procedure for a fading memory octomap, meaning that it will forget things that it saw very long ago by deleting those nodes using
deleteNode
.If I end up deleting all nodes from the octree, I noticed that the root node remains alive, and that the octree is saying that my whole volume is occupied.
After I delete all nodes from the octree, only one node remains, and that one is the one whose size is equal to
tree.getResolution() * pow(2.0, 16.0)
(i.e., the root). This node cannot be deleted, asdeleteNodeRecurs
does not delete a node ifnode != this->root
.My questions are:
deleteNodeRecurs
does not delete the root...deleteNodeRecurs
?The text was updated successfully, but these errors were encountered: