Normalization of dpdu/dpdv in Triangle::GetShadingGeometry causing wrong bump mapping #20

Open
mmp opened this Issue Apr 6, 2014 · 0 comments

Projects

None yet

1 participant

@mmp
Owner
mmp commented Apr 6, 2014

(From mantis bug tracker, reported by Bachi)

Triangle::GetShadingGeometry compute shading coordinate system by interpolating given per-vertex normal/tangents, and use the axes of the shading frame as the dpdu/dpdv values in the returned DifferentialGeometry.

However, the magnitude of dpdu/dpdv is lost due to normalization, and this will affect bump mapping calculation since it depends on the magnitude of dpdu/dpdv.

One way to fix this is to separate dpdu/dpdv and shading coordinate system in the DifferentialGeometry structure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment