fixed loading of some dds
This commit is contained in:
parent
375a6385b2
commit
f449344fa8
1 changed files with 2 additions and 1 deletions
|
@ -1503,7 +1503,8 @@ bool loadTexture(TextureHandle handle, const void* input, int input_size, u32 fl
|
|||
|
||||
if (li->compressed) {
|
||||
u32 size = DDS::sizeDXTC(width, height, internal_format);
|
||||
if (!is_dds10 && (size != hdr.dwPitchOrLinearSize || (hdr.dwFlags & DDS::DDSD_LINEARSIZE) == 0)) {
|
||||
if (!is_dds10 && !is_cubemap && (size != hdr.dwPitchOrLinearSize || (hdr.dwFlags & DDS::DDSD_LINEARSIZE) == 0)) {
|
||||
logError("Renderer") << "Unsupported format " << debug_name;
|
||||
CHECK_GL(glDeleteTextures(1, &texture));
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue