MCPcopy Create free account
hub / github.com/WolfireGames/overgrowth / IsCompressedGLFormat

Function IsCompressedGLFormat

Source/Graphics/textures.cpp:102–124  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

100}
101
102bool IsCompressedGLFormat(GLenum format) {
103 switch (format) {
104 case GL_COMPRESSED_RGB_S3TC_DXT1_EXT:
105 case GL_COMPRESSED_RGBA_S3TC_DXT1_EXT:
106 case GL_COMPRESSED_RGBA_S3TC_DXT3_EXT:
107 case GL_COMPRESSED_RGBA_S3TC_DXT5_EXT:
108 case GL_COMPRESSED_SRGB_S3TC_DXT1_EXT:
109 case GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT:
110 case GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT:
111 case GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT:
112 return true;
113 case GL_DEPTH_COMPONENT24:
114 case GL_RGB8:
115 case GL_RGBA8:
116 case GL_RGBA:
117 case GL_SRGB8:
118 case GL_SRGB8_ALPHA8:
119 return false;
120 default:
121 LOG_ASSERT(false);
122 return false;
123 }
124}
125
126bool GetLinearGLFormat(GLenum format) {
127 switch (format) {

Callers 1

makeTextureInternalMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected