mirror of
https://github.com/dhewm/dhewm3.git
synced 2025-04-07 10:36:36 +00:00
Fix FormatIsDXT() check
there are lots of values between GL_COMPRESSED_RGBA_S3TC_DXT5_EXT (0x83F3) and GL_COMPRESSED_RGBA_BPTC_UNORM (0x8E8C). We don't support them as valid compressed formats. (strictly speaking BPTC is not DXT so the function name doesn't fit 100% anymore, but DXT1-5 is now BC1-3 and BPTC is BC7 so.. close enough.)
This commit is contained in:
parent
8fd317ab4c
commit
06d919b410
1 changed files with 3 additions and 2 deletions
|
@ -37,8 +37,9 @@ PROBLEM: compressed textures may break the zero clamp rule!
|
|||
*/
|
||||
|
||||
static bool FormatIsDXT( int internalFormat ) {
|
||||
if ( internalFormat < GL_COMPRESSED_RGB_S3TC_DXT1_EXT
|
||||
|| internalFormat > GL_COMPRESSED_RGBA_BPTC_UNORM ) {
|
||||
if ( (internalFormat < GL_COMPRESSED_RGB_S3TC_DXT1_EXT
|
||||
|| internalFormat > GL_COMPRESSED_RGBA_S3TC_DXT5_EXT)
|
||||
&& internalFormat != GL_COMPRESSED_RGBA_BPTC_UNORM ) {
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
|
Loading…
Reference in a new issue