- Home /
Signed Float Textures
Are ARGB32 Texture signed, i.e. can pixels from this texture have negative values?
I have an OpenEXR image, with some negative pixels, but when I import it within Unity and use it in a shader negative values seem to be clamped to 0...
The image has a native ARGBFloat format. Sadly the best I can do using Unity's importer is to load it with a ARGB32 format. Is it possible that this conversion is causing the problem?
The picture below shows my current import settings. Linear color space is selected. Thanks.
Does setting Encode as RGB$$anonymous$$ to 'on'/'auto' help?
Not really. As you can see at this page https://docs.unity3d.com/ScriptReference/TextureImporterSettings-rgbm.html encoding simply packs values in the range [0, 8] to values in the range of [0, 1]. Then, in the shader, to obtain values in the original range, the DecodeHDR function is used. However, my values can be negative, therefore not in the range [0,8].
Your answer
Follow this Question
Related Questions
Replace a sprite by another in every game object using it 1 Answer
Editing lightmaps through code 0 Answers
Texture broken in build but normal in edit mode 1 Answer
Texture looks different in different devices? 0 Answers
Texture/Materials are not loading ,Textures are not showing up on my materials 0 Answers