I'm using the Simple OpenGL Image Library to load a TGA file and get a GLuint texture ID for use with OpenGL 3.1, rather than through Qt's QImage and QGL wrappers. I added LIBS += C:/Qt/qtcreator-2.5.2/lib/libSOIL.lib and INCLUDEPATH += C:/Qt/qtcreator-2.5.2/include/ to my project's .PRO file. I also put SOIL.h in C:/Qt/qtcreator-2.5.2/include/, and libSOIL.lib in C:/Qt/qtcreator-2.5.2/lib. Lastly, I added #include <SOIL.h> to all headers that required it.
The project compiles fine if I don't call any SOIL functions. The moment I try to call a SOIL function, though, I get a link error talking about an unresolved external symbol in libSOIL.lib. Has anyone gotten SOIL to link properly with Qt Creator 2.5.2? What could be causing the problem I'm seeing? Are there any other methods of loading a TGA file in Qt, aside from writing my own loader from scratch?
Is there a way of using Qt to load a tga file and get back a normal GLuint texture ID?
Bookmarks