BachiLi / redner

Differentiable rendering without approximation.
https://people.csail.mit.edu/tzumao/diffrt/
MIT License
1.39k stars 139 forks source link

Added a "directly_visible" flag to the pyredner_tensorflow object base class, and also to the "generate_quad_light" function. #181

Closed jeffyost2 closed 2 years ago

jeffyost2 commented 2 years ago

This was previously there for pyredner (the pytorch implementation), so this is really just making pyredner_tensorflow consistent with pyredner. At the same time, I noticed that, in pyredner, the default value for this optional argument was "None", which was not aligned with the default values in, for example, area_light.py and envmap.py. In the interest of consistency - although this changes the default behavior in pyredner (the default behavior for either pyredner or pyredner_tensorflow must necessarily change, if we want them to be consistent) - I changed the default for “directly_visible” to be “True” everywhere. (If the change to the default behavior for pyredner is an issue, we’d be happy to take a different approach.)

BachiLi commented 2 years ago

Forgot to merge this. Thanks a lot!