11 #ifndef GL_COMPRESSED_RGBA_S3TC_DXT1_EXT
12 #define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1
14 #ifndef GL_COMPRESSED_RGBA_S3TC_DXT5_EXT
15 #define GL_COMPRESSED_RGBA_S3TC_DXT5_EXT 0x83F3
17 #ifndef GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT
18 #define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT 0x8C4D
20 #ifndef GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT
21 #define GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT 0x8C4F
23 #ifndef GL_COMPRESSED_RG_RGTC2
24 #define GL_COMPRESSED_RG_RGTC2 0x8DBD
26 #ifndef GL_COMPRESSED_RGBA_BPTC_UNORM
27 #define GL_COMPRESSED_RGBA_BPTC_UNORM 0x8E8C
29 #ifndef GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM
30 #define GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM 0x8E8D
32 #ifndef GL_COMPRESSED_RGB8_ETC2
33 #define GL_COMPRESSED_RGB8_ETC2 0x9274
35 #ifndef GL_COMPRESSED_SRGB8_ETC2
36 #define GL_COMPRESSED_SRGB8_ETC2 0x9275
38 #ifndef GL_COMPRESSED_RGBA8_ETC2_EAC
39 #define GL_COMPRESSED_RGBA8_ETC2_EAC 0x9278
41 #ifndef GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC
42 #define GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC 0x9279
44 #ifndef GL_COMPRESSED_RGBA_ASTC_4x4_KHR
45 #define GL_COMPRESSED_RGBA_ASTC_4x4_KHR 0x93B0
47 #ifndef GL_COMPRESSED_RGBA_ASTC_8x8_KHR
48 #define GL_COMPRESSED_RGBA_ASTC_8x8_KHR 0x93B7
50 #ifndef GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR
51 #define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR 0x93D0
53 #ifndef GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR
54 #define GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR 0x93D7
61 case GL_FRAMEBUFFER_UNDEFINED:
62 return "GL_FRAMEBUFFER_UNDEFINED";
63 case GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT:
64 return "GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT";
65 case GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:
66 return "GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT";
67 case GL_FRAMEBUFFER_UNSUPPORTED:
68 return "GL_FRAMEBUFFER_UNSUPPORTED";
69 case GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE:
70 return "GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE";
72 return "Unknown error code: " + std::to_string(status);
80 switch (pixel_format) {
84 format.
type = GL_UNSIGNED_BYTE;
89 format.
type = GL_UNSIGNED_BYTE;
95 format.
type = GL_UNSIGNED_BYTE;
106 format.
type = GL_UNSIGNED_BYTE;
111 format.
type = GL_FLOAT;
116 format.
type = GL_FLOAT;
121 format.
type = GL_HALF_FLOAT;
132 format.
type = GL_UNSIGNED_INT_24_8;
std::optional< PixelFormatGLES > ToPixelFormatGLES(PixelFormat pixel_format, bool supports_bgra)
std::string DebugToFramebufferError(int status)
PixelFormat
The Pixel formats supported by Impeller. The naming convention denotes the usage of the component,...