Benjamin Hopfer Software Solutions

Problems and solutions of a freelancing software engineer

16 September 2015

vtkBioeng for vtk 6.2

by Benjamin Hopfer

For an upcoming mesh collision problem in one of my C++/vtk/Qt projects I wanted to try the collision filter in the vtkBioeng package (website, git repository). However, the current source code is not compileable with vtk 6.x, because backwards compatibility with vtk 4.x code was removed.

I therefore adapted the CMake scripts and source code myself to make it compile with vtk 6.2. Since I’m not an expert in vtk module development, I don’t want to integrate my changes into the original repository and therefore uploaded the changes to my own public git repository.

I basically just applied all the steps listed in the migration guides from the following sources:

Output of vtkbioeng test case
Output of vtkbioeng test case

I’m pretty sure some additional work can and needs to be done, especially in the CMake script, but these changes seem to work well enough for me. You can see the output of the first test case on the right.

Known issues:

Update 2020-02-26: I’m moving my website to GitHub pages and in the process I’m tidying up the wording of this article and getting rid of the comment section. However, I’m migrating useful old comments onto here as well (anonymized):


M., June 23, 2016 at 10:59:
Great, I Just had to add a definition in vtkCollisionDetectionFilter.h :
#define VTK_LARGE_FLOAT 1.0e+38F;
to compile it with vtk 6.3

I’m trying it now…


G., November 25, 2016 at 09:43:
Thanks for all you efforts , it will grately help ful all the vtk comunity

G., November 28, 2016 at 17:04:
Hi, i am getting folowing error when confugure using cmake , am unble resolve this please tell if have any idea

Error : VTK_MAKE_INSTANTIATOR2

G., November 28, 2016 at 17:15:
Hi, i am getting folowing error when confugure using cmake , am unble resolve this please tell if have any idea

Error : VTK_MAKE_INSTANTIATOR3

note: sorry for last message

(I couldn’t find the solution for this person)


A. (Maintainer of vtkbioeng), June 25, 2018 at 18:00:
Thanks Benjamin that s been on my todo list for a while. I ll test out your 6.2 migration and integrate your code.

tags: C++ - vtk