building VTK in windows 10, visual studio 2019, lways crashes what am i doing wrong?

I have followed various tutorials including one where I build it with QT

and building it as a standalone

or running a stand alone application without QT

I even just copy and pasted the sample from here:

But everytime i run an application including the one from above, i get CRASHES on mere declaration alone.

here is the crash when using the CylinderExample from above.

I tried building the latest 9.1.0 and even the version before that VTK-8.2.0
I cant seem to make it work!

when using QT, and declaring a QVTKOpenGLWidget, the crash is in the constructor itself, Exception occured yada yada.

What am i doing wrong to get myself started with VTK?
this is just sad, I already spent a whole day just setting this one up

This most commonly happens when your test application finds some unrelated VTK DLLs in your path.

In general, it is advisable to keep your PATH environment variable mostly empty (have nothing but some Windows system folders). If you want to make sure your executable does not pick up unrelated DLLs then you can put the DLLs in the same folder as the executable, or use manifests.

1 Like