Crash while calling Update method of class vtkIntersectionPolyDataFilter
This issue was created automatically from an original Mantis Issue. Further discussion may take place here.
I want to report a possible bug leading to a crash with the Python wrapped class vtkIntersectionPolyDataFilter.
I use the python wrapped class vtkIntersectionPolyDataFilter to detect collision between 2 vtkpolydata models. My models are two cylinders, there is an inner cylinder and an outer cylinder for which I want to detect contact. Outer cylinder is motionless and inner cylinder can move inside the outer cylinder. Sometimes the inner cylinder can collide the outer cylinder. For the some set of translation and rotation, the inner cylinder slighty touch the outer cylinder and the program crash.
To show this, I have included a zip file containing 4 files:
- Two STL binary files containing each one cylinder (I know I could have used vtkCylinderSource)
- A python script that reproduces the bug, with the dataset leading to the bug: vtkBug.py. This script loads the stl, create an instance of a developped class named VtkDetectCollision, and evalutes the possible collision
- A python paraview script that shows the crashing example in Paraview. It loads the STL data and apply the transformation on the inner cylinder that leads to a crash.
I have detected the problem on Windows 7 64 bits with Python 2.7.10 64 bits and VTK 6.2.0 I have detected the problem for this platform However I have tried with version 6.1.0 on Windows 7 64Bits and it succeeds: it does not crash and seems to produce correct results. I also tried on Debian 8 32 Bits with vtk6python VTK 6.1.0, and it also succeeds.
SUM UP: FAIL : Windows 7 64 Bits python 2.7.10 + VTK-6.2.0-cp27-none-win_amd64.whl (http://www.lfd.uci.edu/~gohlke/pythonlibs/) WORK : Windows 7 64 Bits python 2.7.10 + VTK-6.1.0-cp27-none-win_amd64.whl (http://www.lfd.uci.edu/~gohlke/pythonlibs/) WORK : Debian 8 32 Bits with vtk6python
I work with slightly different geometries, and I also experience crash with windows with 6.1.0; The problem may come from a tolerance problem, or a accuracy problem on the geometric part of the VTK vtkIntersectionPolyDataFilter Has somebody any idea of what may be wrong with my example Is the only way to debug this, it to move my example to C++ and use the debugger?
Best regards Guillaume Jacquenot