google / nerfactor

Neural Factorization of Shape and Reflectance Under an Unknown Illumination
https://xiuming.info/projects/nerfactor/
Apache License 2.0
437 stars 56 forks source link

Potential bug in the Microfacet BRDF model #18

Closed leehsiu closed 2 years ago

leehsiu commented 2 years ago

https://github.com/google/nerfactor/blob/0831990245125736c803651ea918cb62a2866b32/brdf/microfacet/microfacet.py#L57
The shadow term is calculated as g = self._get_g(pts2c, h, normal, alpha=alpha) # NxL

However, according two Equ.(23) in the original BTDF paper it should be G(v,m)G(l,m).

Here only half part is calculated.

xiumingzhang commented 2 years ago

Which "Equ.(23)"?