I fully expect rogerborg to come in here and scold me for overlooking something simple... in fact I'm kind of hoping for it
Here's my situation:
I've been looking to implement a sort of ribbon/trail effect for some time, and after searching the forums a lot I found varmint's solution, which looked good but only works with OpenGL. I was having issues with OpenGL earlier that seem to be resolved so I decided to give varmint's code a shot.
Now it seems no matter what I do, I get a linker error:
Code: Select all
1>CMotionTrailSceneNode.obj : error LNK2019: unresolved external symbol "public: unsigned int __thiscall irr::video::COpenGLTexture::getOpenGLTextureName(void)const " (?getOpenGLTextureName@COpenGLTexture@video@irr@@QBEIXZ) referenced in function "public: virtual void __thiscall irr::scene::CMotionTrailSceneNode::render(void)" (?render@CMotionTrailSceneNode@scene@irr@@UAEXXZ)
1>C:\Documents and Settings\RJ Layton\Desktop\thesis\mars\Debug\mars.exe : fatal error LNK1120: 1 unresolved externalsCode: Select all
const video::ITexture* texture = trailMaterial.getTexture(0);
if (texture) {
*** glBindTexture(GL_TEXTURE_2D, static_cast<const video::COpenGLTexture*>(texture)->getOpenGLTextureName()); ***
}
If I comment out the line, the program compiles fine. If I take out the command entirely and just supply an integer there it works fine as well. However, I can't seem to get that line to work on its own.
I've tried compiling the Irrlicht engine with the CMotionTrailSceneNode stuff (and IMotionTrailSceneNode) and following varmint's instructions, but I get this error. I've tried just including all of this source into my own code and including it in main.cpp, and the same error occurs.
I've been trying this and that to remedy it but nothing has worked. I'm sure the solution is simple but I can't figure it out