eglGetProcAddress allways non null

Hi, I am trying to enable the buffer mapping extension.
The extension is present, but I cannot get the function pointer.

Worse, eglGetProcAddress(“BullShit”) returns an arbitrary value and not 0, thus making any debugging impossible.

Where do I do wrong?

Regards Christoph

try nulling the pointer before calling eglGetProcAddress - i believe it doesn’t do anything in the extension doesn’t exist, therefore a null pointer will remain null

Hello and thank you for your reply,

unfortunately eglGetProcAddress does return a non 0 value thus overwriting the pointer.

You’re right - we tested on latest code, not what you would have in your device -

The actual situation is this:

In older versions of the Tegra Android driver, querying for a non-existent entry-point will always return what appears to be a valid function pointer. Although this is controversial (and unhelpful) it is allowed by the egl spec.

In recent versions of the Tegra Android driver if an entry-point doesn’t exist eglGetProcAddress will return 0.

To help resolve your problem it would be helpful if you can provide source fragments showing how you query entry-points (and which strings you query exactly), so we can review and investigate further.

Well, since I do not want to burden you with my nonsense, it suffices to say, that i put DEBUG(“%u”, eglGetProcAddress(“BullShit”)) anywhere in the code, including the draw() routine as well as the init() section.
Of course I tried with other strings including the “mapbufferOES” stuff and empty “” Strings.

Which, by the way, did not work. That was also the initial reason why I investigated the getproc… routine in the first place.

If you cold point me in the right direction on how to use the map buffer stuff properly I would be very grateful.

Regards Christoph