appleseed icon indicating copy to clipboard operation
appleseed copied to clipboard

Converting normal map values to vectors; numerical errors

Open lorentzo opened this issue 3 years ago • 1 comments

Perturbed normals are encoded in normal map pixels as RGB vectors. To obtain a perturbed normal conversion from RGB to unit vector is required. The problem appears when one (or more) of RGB channel has a value of 128 which should exactly be 0 in converted vector. But in this case, converted vector not 0 but close to 0, more specifically: 0.003921 or -0.003921.

Below is the normal map baked in Blender which has this specific cases: simple5_DX_values

For example, pixel value of (128, 128, 255) should be converted to (0,0,1) but it it has values of (0.003921, -0.003921, 0.999985).

lorentzo avatar Jul 27 '20 16:07 lorentzo

I wanna work on to this project can you assign it to me.

imSanko avatar Dec 09 '20 07:12 imSanko