table of contents
- trixie 3.2.10+ds-1
- testing 3.4.20+ds-1
- unstable 3.4.22+ds2-1
- experimental 3.5~git20261111~e7a4fa6+ds-1
| SDL_GL_ExtensionSupported(3) | SDL3 FUNCTIONS | SDL_GL_ExtensionSupported(3) |
NAME¶
SDL_GL_ExtensionSupported - Check if an OpenGL extension is supported for the current context.
SYNOPSIS¶
#include <SDL3/SDL_video.h>
bool SDL_GL_ExtensionSupported(const char *extension);
DESCRIPTION¶
This function operates on the current GL context; you must have created a context and it must be current before calling this function. Do not assume that all contexts you create will have the same set of extensions available, or that recreating an existing context will offer the same extensions again.
While it's probably not a massive overhead, this function is not an O(1) operation. Check the extensions you care about after creating the GL context and save that information somewhere instead of calling the function every time you need to know.
FUNCTION PARAMETERS¶
- extension
- the name of the extension to check.
RETURN VALUE¶
Returns true if the extension is supported, false otherwise.
THREAD SAFETY¶
It is safe to call this function from any thread (as long as a unique GL context was made current for that thread).
AVAILABILITY¶
This function is available since SDL 3.2.0.
| SDL 3.4.22 | Simple Directmedia Layer |