Enhanced the sampling precision of 88 texture formats.
diff --git a/src/Shader/SamplerCore.cpp b/src/Shader/SamplerCore.cpp
index 1c428f2..6224d45 100644
--- a/src/Shader/SamplerCore.cpp
+++ b/src/Shader/SamplerCore.cpp
@@ -1572,9 +1572,8 @@
case FORMAT_G8R8:
case FORMAT_V8U8:
case FORMAT_A8L8:
- // FIXME: Unpack properly to 0.16 format
- c.y = c.x;
- c.x = c.x << 8;
+ c.y = (c.x & Short4(0xFF00, 0xFF00, 0xFF00, 0xFF00)) | As<Short4>(As<UShort4>(c.x) >> 8);
+ c.x = (c.x & Short4(0x00FF, 0x00FF, 0x00FF, 0x00FF)) | (c.x << 8);
break;
default:
ASSERT(false);