Re: Question on bump mapping

74 views
Skip to first unread message

Matt Pharr

unread,
Jan 28, 2023, 11:28:15 AM1/28/23
to pb...@googlegroups.com
The second term is adding a scaled version of the surface normal to the geometric dpdu to get the shading dpdu. Then the cross product of the shading dpdu and dpdv give you the shading normal.

Thanks,
Matt

On Jul 25, 2022, at 10:59 AM, John Myslinski <jbmys...@gmail.com> wrote:

Hi All,

Question on how the math regarding bump mapping works out.

Looking at pbrt-v3, section 9.3, specifically the fragment where we "Compute bump-mapped differential geometry" and the following formula...

dpdu = si->shading.dpdu + (uDisplace - displace) / du * Vector3f(si->shading.n) + displace * Vector3f(si->shading.dndu)

Assuming I have a flat plane at y=0, my shading normal will be Normal3f(0,1,0) so the x and y components of the 2nd term in the above formula will always be 0. Then as stated in the book, the third term has minimal impact. So then how do we end up with our bump mapped dpdu not (approximately) equal to shading.dpdu?

Are my shading normal assumptions off? Did I mess up my math somewhere? Am I fundamentally misunderstanding how bump mapping is supposed to work?

Appreciate any insights here, Thanks, John
 

--
You received this message because you are subscribed to the Google Groups "pbrt" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pbrt+uns...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pbrt/3d7a41c0-5dc6-4a2c-a0b9-9092239b31d4n%40googlegroups.com.

Reply all
Reply to author
Forward
0 new messages