We are trying to compressed our textures suing batch files babylon provide and pvrtextool but generated compressed textures are too dark as gamma space is being removed. Here is the playground link with Linear-RGB: https://www.babylonjs-playground.com/#5FLDS#13
So according to docs, we should be compressing texture with Linear-RGB but for testing purposes we tried sRGB encoding but excepted results is only working inside desktop. ‘astc.ktx’ are still dark when running inside iOS or android. Here is the link with sRGB compressed textures : https://www.babylonjs-playground.com/#5FLDS#14
Is this a pvrtextool issue as according to one of their devs, only their GUI display is broken.
If your albedo texture is in linear space, you should instruct the system because by default it expects this texture to be in gamma space. Simply do newMat.baseTexture.gammaSpace = false to tell the texture is in linear space. That way, your first PG will produce the same result than your second PG.
Note however it’s a mistake to encode the metallic/roughness and normal textures in sRGB space: those ones should always be in linear space.
Hi,
Thanks for reply and detailed explanation.
That certainly helps with basecolor texture but we are still seeing irregularities with metallic/roughness and normal textures. This is the result without using compression textures and its a same results we are seeing inside substance designer : https://www.babylonjs-playground.com/#5FLDS#19
Roughness is very dark or reflective with compressed textures as compared to raw texture.
We are exporting as ‘raw’ from substance designer/painter. Should be export in linear space?
No, haven’t tried that as it still in experimental stage. I tried exporting the greyscale 127,127,127 from photoshop and tried to compressed that but pvrtextool is converting those values to 54,54,54 so whatever format I create the texture in, its always converting those values. I also tried bringing that texture inside unreal engine as unreal also likes the metallic/roughness to be in linear space. Texture value inside ue4 kept it 127,127,127. Even the texture is already in linear space, its does the conversion which is converting values to be low.
Is there a setting inside pvrtextool that can keep those values same ?
Hi,
Want to clarify couple of things regarding ktx2 format. So is ktx2 format same as .basis format ? Is there a tutorial or documentation from where i can create ktx2 format ? Is ktx2 supported on all platform?