7
$\begingroup$

It is no secret that according to the official documentation extensions are not available under OpenGL ES 2.0. Nevertheless, the glext.h file present in the NDK platform-include directories makes me think that extensions are indeed available. I know that working with OpenGL under NDK doesn't differ from working with standalone OpenGL. So, if I make something like a JNI bridge between my java engine interface and these extensions, I could use them.

So the question is: what architectural solution should I use if I want to use available OpenGL ES extensions on ES2.0 devices?

$\endgroup$
3
  • $\begingroup$ Just noting that I've definitely used extensions via GLES 2.0 on android (and in native code) so you shouldn't have any issues on that part of your solution. $\endgroup$ Aug 10 '15 at 18:37
  • $\begingroup$ Are we considering very specific programming questions like these? This is a very API-specific programming question and doesn't even involve anything related to rendering techniques or usage of an API to implement them. $\endgroup$
    – yuriks
    Aug 11 '15 at 0:46
  • $\begingroup$ @yuriks Yes, I think we should definitely except if they are very specific programming questions related to computer graphics. In fact, I think that specific programming questions are what we are lacking the most so far (probably because these are harder to come up with if you don't encounter them right then and there). $\endgroup$ Aug 11 '15 at 8:30
5
$\begingroup$

I have encountered devices that advertise certain extensions via glGetString(GL_EXTENSIONS) and do not expose the entry points. I have also encountered the opposite, the extension was not in the extension strings but the entry points were there and it worked. It depends on whether the vendor has disabled any features in the driver from the GPU provider.

You will need to check both the extension strings and check if the entry point is not NULL via eglGetProcAddress.

Apart from that, each extension should conform to the Khronos registry of extensions so you can include gl2ext.h directly from there if you wanted.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.