From 3fb7221df29626a4004225a3b8dd6536f977ce3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Branimir=20Karad=C5=BEi=C4=87?= Date: Fri, 13 Feb 2015 09:33:56 -0800 Subject: [PATCH] Cleanup. --- src/image.cpp | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/src/image.cpp b/src/image.cpp index 9da6372e..ed3b7ca8 100644 --- a/src/image.cpp +++ b/src/image.cpp @@ -12,6 +12,13 @@ namespace bgfx { static const ImageBlockInfo s_imageBlockInfo[] = { + // +------------------ bits per pixel + // | +--------------- block width + // | | +------------ block height + // | | | +-------- block size + // | | | | +----- min blocks x + // | | | | | +-- min blocks y + // | | | | | | { 4, 4, 4, 8, 1, 1 }, // BC1 { 8, 4, 4, 16, 1, 1 }, // BC2 { 8, 4, 4, 16, 1, 1 }, // BC3 @@ -1384,8 +1391,11 @@ namespace bgfx static TranslateDdsPixelFormat s_translateDdsPixelFormat[] = { - { 32, { 0x00ff0000, 0x0000ff00, 0x000000ff, 0xff000000 }, TextureFormat::BGRA8 }, - { 32, { 0x00ff0000, 0x0000ff00, 0x000000ff, 0x00000000 }, TextureFormat::BGRA8 }, + { 32, { 0x00ff0000, 0x0000ff00, 0x000000ff, 0xff000000 }, TextureFormat::BGRA8 }, + { 32, { 0x00ff0000, 0x0000ff00, 0x000000ff, 0x00000000 }, TextureFormat::BGRA8 }, + { 32, { 0x000003ff, 0x000ffc00, 0x3ff00000, 0xc0000000 }, TextureFormat::RGB10A2 }, + { 32, { 0x0000ffff, 0xffff0000, 0x00000000, 0x00000000 }, TextureFormat::RG16 }, + { 32, { 0xffffffff, 0x00000000, 0x00000000, 0x00000000 }, TextureFormat::R32 }, }; bool imageParseDds(ImageContainer& _imageContainer, bx::ReaderSeekerI* _reader)