No override found for vtkRenderer/ vtkRenderWindow

2019-05-10 14:09发布

问题:

I'm new to vtk and when I was running a small example, it generates two errors,

No override found for vtkRenderer

No override found for vtkRenderWindow

I googled this problem and couldn't find a proper solution.

回答1:

I had such a problem when I was trying to make a VTK project without CMake, the solution was to use those two lines:

#include <vtkAutoInit.h> 
VTK_MODULE_INIT(vtkRenderingOpenGL2)

So if you are using CMake, then you probably have skipped some step while building your VTK environment.



标签: cmake vtk