mirror of
https://github.com/MobileGL-Dev/MobileGL
synced 2026-09-12 06:08:30 +09:00
[Fix] (MG_Util): GL_FLOAT_32_UNSIGNED_INT_24_8_REV is 8 bytes per pixel
The packed-type size table listed the D32F+S8 client format at 4 bytes, so every GL_DEPTH32F_STENCIL8 upload copied only half its client data - the top half of such textures stayed zero (packed_depth_stencil verify_read_pixels/clear_buffer.depth32f_stencil8 now pass).
This commit is contained in:
@@ -255,8 +255,10 @@ namespace MobileGL {
|
|||||||
case TexturePixelDataType::UnsignedInt101111Rev:
|
case TexturePixelDataType::UnsignedInt101111Rev:
|
||||||
case TexturePixelDataType::UnsignedInt5999Rev:
|
case TexturePixelDataType::UnsignedInt5999Rev:
|
||||||
case TexturePixelDataType::UnsignedInt248:
|
case TexturePixelDataType::UnsignedInt248:
|
||||||
case TexturePixelDataType::Float32UnsignedInt248Rev:
|
|
||||||
return 4;
|
return 4;
|
||||||
|
case TexturePixelDataType::Float32UnsignedInt248Rev:
|
||||||
|
// A 32-bit float depth word followed by a 32-bit word holding stencil.
|
||||||
|
return 8;
|
||||||
default:
|
default:
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user