Skip to content

asahi: Decompress with format reinterpretation

Alyssa Rosenzweig requested to merge alyssa/mesa:agx/decompress-trans into main

The internal layout used with compression partially depends on the pixel format. Some limited reinterpretation is definitely allowed (linear vs sRGB views of the same physical format are documented by Apple as allowed). Some reinterpretations are definitely forbidden (R8G8B8A8 vs R32, I think). At some point we'll need to work out the exact rule. I suspect the answer is that "you can reinterpret iff the Channels field matches". Meaning that R8G8B8A8_UNORM and B8G8R8A8_SINT would be compatible, but not R16G16_UNORM. But I haven't tested that.

I'm not sure off hand if texture views are possible with the GL versions we're about to ship (definitely possible with gles3.1, which is where these commits come from). But just in case let's get it right.

Merge request reports