Hi.
I was looking through the files into \blender\intern\cycles\kernel\closure\
, and I noticed that each closure files contain at least two functions:
bsdf_..._eval()
and
bsdf_..._sample()
.
I couldn’t figure out on my own what the difference is between them. I was able to guess that sample()
produces the “final” color of the pixel, but why is eval()
needed? At first I thought it was a geometric term, but further analysis of the code did not confirm my theory either.
Could you explain what they do?