Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
pcl::MeshQuadricDecimationVTK seg fault #967
I am running a continuous loop that get the latest point-cloud from a laser sensor and transform it into a mesh.
Program received signal SIGSEGV, Segmentation fault.
The specific lines in my code are =
For reference, the mesh generation from Point-Cloud is:
The computer is concurrently running a simulator, which hogs a lot of the memory. I am guessing this is an internal memory-leak. I wasn't able to find any similar bugs on the Issue Tracker
Any ideas? And is there any alternative options for the same functionality as MeshQuadricDecimationVTK?
Thanks in advance!
Alright, I compiled VTK from source in DEBUG mode, and the error message is the following:
Line 1101 is the IF statement below:
I narrowed down to the pts[j] variable returning an Invalid Pointer. So as a quick "hack solution" I wrapped the for loop with an if statement that checks for the pointer validity:
This "solved" the problem for me, but it doesn't actually tackle why this->Mesh->GetCellPoints is never initializing the pointer on some edge case.