Issue with glObjectLabel function availability on macOS

40 views
Skip to first unread message

Martin Štrympl

unread,
Feb 24, 2025, 9:14:53 AMFeb 24
to angleproject
We have an app on macOS that uses ANGLE OpenGL ES for Metal translation.

We checked if the "KHR_debug" extension is available, and we got true.
We try to load the function glObjectLabel and eglGetProcAddress returns a pointer to it.

And when we call it, it always logs an error: OpenGL ES 3.2 Required.

How should we correctly check if the glObjectLabel function is available and usable?

The extension "KHR_debug" requires OpenlGL 1.1. So it does not sound like checking the OpenGL ES version is the correct way to fix this.

Shahbaz Youssefi

unread,
Feb 24, 2025, 9:20:07 AMFeb 24
to angleproject
Hi,

`glObjectLabel` is a GLES3.2 entry point. `glObjectLabelKHR` is the entry point exposed by KHR_debug. So the entry point you'd want to load/call is "glObjectLabelKHR" (including the suffix).

FYI, in most cases, the functionality of `glFooSUFFIX` and the promoted `glFoo` are identical, but technically they are considered to be different entry points with (potentially) different behavior. This is why the GL driver cannot return the entry point for `glFooSUFFIX` when you query `glFoo` and "just make it work". Validation for each entry point is naturally different in their version/extension check.

Cheers,

Martin Štrympl

unread,
Feb 24, 2025, 10:49:09 AMFeb 24
to angleproject
Thanks. It fixed the issue.  :)
Reply all
Reply to author
Forward
0 new messages