Monte Carlo code where it divide the number of samples #1197
-
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
This is split over a few different files. An integrator will typically return a "weight" for each sample, and its value is usually 1. These weights are accumulated into their own channel in the film, like RGB values. Finally the weight is divided out when developing the film. So effectively, this weight channel is equivalent to For your questions about varying spp, it is handled implicitly. The function |
Beta Was this translation helpful? Give feedback.
Hi @NhatMinh2001
This is split over a few different files. An integrator will typically return a "weight" for each sample, and its value is usually 1. These weights are accumulated into their own channel in the film, like RGB values. Finally the weight is divided out when developing the film. So effectively, this weight channel is equivalent to
spp
.For your questions about varying spp, it is handled implicitly. The function
Sensor.sample_rays()
generates the rays with a constant spp, but it could do so according to a completely arbitrary distribution. So if you want to do some adaptive sampling like technique, modifiying thesample_rays()
method should be enough. The change in distributi…