GL_APPLE_texture_format_BGRA8888

Valid APIs

OpenGL ES 3.0

Description

Typically, textures in OpenGL ES run in RGBA order; this extension adds BGRA8888 as an acceptable external format so that textures in this byte order can be used instead. This avoids byte swizzling when loading RGBA internal format textures, which may be stored in BGRA order internally.

Example

// Create a BGRA8888 texture
glTexImage2D(GL_TEXTURE_2D, 0, GL_BGRA_EXT, 1024, 1024, 0, GL_BGRA_EXT, GL_UNSIGNED_BYTE, pixelData);