I’m creating a native android project using eclipse. It uses opengl es 1.1.
I’m having a problem using functions defined in “glext.h”. I’m able to use macros defined in “glext.h”, but when I try to use any function defined in “glext.h”, it says its unable to resolve that function.
I know glext.h is deprecated, but i’m following along with a book and i’d like to get this working. I used the books source code, and had the same problem.
What can i do to use the functions defined in glext.h?
When you include the header file, you get only what’s in that header file. In your case, you get the macros, which are entirely included in the header file, and the function declarations. Those just declare that the function exists, it’s not the actual code, which is the function definition.
To get access to the actual functions (the definitions), you need to link to a library. The unresolved functions error means that the compiler knows the function exists, but the linker doesn’t know where to find it.
I think your solution may just be to link the OpenGL ES 1.x library. To do so, check your
Android.mkfile, and make sure the line that setsLOCAL_LDLIBSincludes-lGLESv1_CM. Like this:That links the logger, the dynamic linker, and the OpenGL ES 1.x libraries.
I’m getting my information from here. I couldn’t find a canonical source on Google’s site.