Trying to implement support for basis textures in heaps, and realized that on iOS and PVRTC textures they sometimes render wrong if the source image doesn’t have premultiplied alpha.
I tried updating our png’s to have PMA and everything then works, however colors become a bit darker.
Applying a shader that does
pixelColor.rbg /= pixelColor.a corrects the output.
However applying the shader when it is needed is a bit cumbersome, and it would be nice to at least be able to flag texture/pixels for if they are PMA to make a generic way to handle it.
In heaps there are flags for AlphaPremultiplied for both Pixels and Texture, however they don’t seem to have any effect, and is not used anywhere in source other then being set in some places.
Am I missing something on how the flags works, or are they just placeholders for planned functionality?
Anyone using PMA with success and have some hints?