Fixed RGBA16F DDS loading.

This commit is contained in:
bkaradzic
2013-01-26 23:00:35 -08:00
parent a674d734d3
commit 4dc9be09d3
7 changed files with 100 additions and 62 deletions

View File

@@ -23,6 +23,7 @@ namespace bgfx
#define DDS_ATI1 BX_MAKEFOURCC('A', 'T', 'I', '1')
#define DDS_ATI2 BX_MAKEFOURCC('A', 'T', 'I', '2')
#define D3DFMT_A16B16G16R16 36
#define D3DFMT_A16B16G16R16F 113
#define DDSD_CAPS 0x00000001
@@ -495,11 +496,17 @@ bool parseDds(Dds& _dds, const Memory* _mem)
bpp = 4;
break;
case D3DFMT_A16B16G16R16F:
case D3DFMT_A16B16G16R16:
type = TextureFormat::RGBA16;
blockSize = 8;
bpp = 64;
break;
case D3DFMT_A16B16G16R16F:
type = TextureFormat::RGBA16F;
blockSize = 8;
bpp = 64;
break;
}
}
else