没有找到'vtkPolyDataMapper'的重写 [英] no override found for 'vtkPolyDataMapper'

查看:1244
本文介绍了没有找到'vtkPolyDataMapper'的重写的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在我的代码中使用vtk,但我运行示例时遇到问题。我几乎没有线索的原因,因为这是我第一次使用它,我不是很有经验。
我使用visual studio 2012和x64平台。
因为我真的不知道我应该使用哪些库,我把所有的添加到附加依赖。
的例子在此链接中给出。
的问题是,当我运行它时,窗口会显示此消息。

I'm trying to use vtk in my code, but I'm having problems running an example. I have almost no clue about the reasons since it's the first time I'm using it and I'm not very experienced. I'm using visual studio 2012 and x64 platform. Since I don't really know which libs should I use I added all of them to the "Additional Dependencies". The example is given in this link. The problem is that when I run it, the window shows this message

Generic Warning: In C:\location\VTK6.0.0\Rendering\Core\vtkPolyDataMapper.cxx, line 27
Error: no override found for 'vtkPolyDataMapper'.

与此行对应

// Return NULL if no override is supplied.
vtkAbstractObjectFactoryNewMacro(vtkPolyDataMapper)

和错误是Visual Studio的显示是

And the error that visual studio shows is

First-chance exception at 0x000007F7AA106C8F in Test.exe: 0xC0000005: Access violation reading location 0x0000000000000000.



有谁知道如何解决这个问题,或者至少这个错误是什么意思?

Does anyone know how to solve this problem or at least what does this error mean?

推荐答案

按照 VTK迁移指南,如果你不使用CMake编译你的代码,你需要添加一些 #define 。对于VTK 6.0,这些线路需要之前任何其他VTK #include

According to the VTK migration guide, if you are not using CMake to compile your code, you need to add some #defines. For VTK 6.0, these lines need to go before any other VTK #includes:

#define vtkRenderingCore_AUTOINIT 4(vtkInteractionStyle,vtkRenderingFreeType,vtkRenderingFreeTypeOpenGL,vtkRenderingOpenGL)
#define vtkRenderingVolume_AUTOINIT 1(vtkRenderingVolumeOpenGL)

这篇关于没有找到'vtkPolyDataMapper'的重写的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆