Type of Normal Maps in MDL


when the function base::tangent_space_normal_texture() is used, what type of normal
map is expected as input? a DirectX-normal map or an openGL-normal map (inverse G component)?
From the MDL sample “carpet_berber_white.mdl” file: “carpet_bump_normal.png”
to me it seems that is a DirectX normal map. Is that correct ?

Thank you.

essentially base::tangent_space_normal texture is not limiteded to specific normalmap formats, with flip_tangent_u, flip_tangent_v (flip_tangent_v should do the trick for you) you can adapt to the format you prefer and using “scale” and “offset” you can even get exotic formats (range -1 to 1 for example) to work

1 Like