Blender Git Loki

Git Commits -> Revision 51e8983

Revision 51e8983 by Stefan Werner (master)
March 5, 2020, 11:21 (GMT)
Adaptive Sampling for Cycles.

This feature takes some inspiration from
"RenderMan: An Advanced Path Tracing Architecture for Movie Rendering" and
"A Hierarchical Automatic Stopping Condition for Monte Carlo Global Illumination"

The basic principle is as follows:
While samples are being added to a pixel, the adaptive sampler writes half
of the samples to a separate buffer. This gives it two separate estimates
of the same pixel, and by comparing their difference it estimates convergence.
Once convergence drops below a given threshold, the pixel is considered done.

When a pixel has not converged yet and needs more samples than the minimum,
its immediate neighbors are also set to take more samples. This is done in order
to more reliably detect sharp features such as caustics. A 3x3 box filter that
is run periodically over the tile buffer is used for that purpose.

After a tile has finished rendering, the values of all passes are scaled as if
they were rendered with the full number of samples. This way, any code operating
on these buffers, for example the denoiser, does not need to be changed for
per-pixel sample counts.

Reviewed By: brecht, #cycles

Differential Revision: https://developer.blender.org/D4686

Commit Details:

Full Hash: 51e898324de30c0985a80e5bc067358b5ccedbfc
Parent Commit: 4ccbbd3
Lines Changed: +1215, -46

9 Added Paths:

/intern/cycles/kernel/kernels/opencl/kernel_adaptive_adjust_samples.cl (+23, -0) (View)
/intern/cycles/kernel/kernels/opencl/kernel_adaptive_filter_x.cl (+23, -0) (View)
/intern/cycles/kernel/kernels/opencl/kernel_adaptive_filter_y.cl (+23, -0) (View)
/intern/cycles/kernel/kernels/opencl/kernel_adaptive_stopping.cl (+23, -0) (View)
/intern/cycles/kernel/kernel_adaptive_sampling.h (+231, -0) (View)
/intern/cycles/kernel/split/kernel_adaptive_adjust_samples.h (+44, -0) (View)
/intern/cycles/kernel/split/kernel_adaptive_filter_x.h (+30, -0) (View)
/intern/cycles/kernel/split/kernel_adaptive_filter_y.h (+29, -0) (View)
/intern/cycles/kernel/split/kernel_adaptive_stopping.h (+37, -0) (View)

36 Modified Paths:

/intern/cycles/blender/addon/engine.py (+1, -0) (Diff)
/intern/cycles/blender/addon/properties.py (+24, -1) (Diff)
/intern/cycles/blender/addon/ui.py (+10, -1) (Diff)
/intern/cycles/blender/blender_session.cpp (+2, -1) (Diff)
/intern/cycles/blender/blender_sync.cpp (+30, -1) (Diff)
/intern/cycles/blender/blender_sync.h (+3, -1) (Diff)
/intern/cycles/device/cuda/device_cuda.h (+22, -0) (Diff)
/intern/cycles/device/cuda/device_cuda_impl.cpp (+126, -0) (Diff)
/intern/cycles/device/device_cpu.cpp (+61, -1) (Diff)
/intern/cycles/device/device_optix.cpp (+22, -5) (Diff)
/intern/cycles/device/device_split_kernel.cpp (+63, -4) (Diff)
/intern/cycles/device/device_split_kernel.h (+4, -0) (Diff)
/intern/cycles/device/device_task.cpp (+55, -0) (Diff)
/intern/cycles/device/device_task.h (+14, -0) (Diff)
/intern/cycles/device/opencl/device_opencl.h (+1, -0) (Diff)
/intern/cycles/device/opencl/device_opencl_impl.cpp (+9, -1) (Diff)
/intern/cycles/kernel/CMakeLists.txt (+9, -0) (Diff)
/intern/cycles/kernel/kernels/cpu/kernel_cpu.h (+4, -0) (Diff)
/intern/cycles/kernel/kernels/cpu/kernel_cpu_impl.h (+8, -0) (Diff)
/intern/cycles/kernel/kernels/cuda/kernel.cu (+70, -0) (Diff)
/intern/cycles/kernel/kernels/cuda/kernel_split.cu (+8, -0) (Diff)
/intern/cycles/kernel/kernels/opencl/kernel_split_bundle.cl (+4, -0) (Diff)
/intern/cycles/kernel/kernel_passes.h (+38, -1) (Diff)
/intern/cycles/kernel/kernel_path.h (+9, -0) (Diff)
/intern/cycles/kernel/kernel_path_branched.h (+8, -0) (Diff)
/intern/cycles/kernel/kernel_types.h (+16, -2) (Diff)
/intern/cycles/kernel/kernel_work_stealing.h (+57, -27) (Diff)
/intern/cycles/render/buffers.cpp (+21, -0) (Diff)
/intern/cycles/render/film.cpp (+14, -0) (Diff)
/intern/cycles/render/film.h (+2, -0) (Diff)
/intern/cycles/render/integrator.cpp (+20, -0) (Diff)
/intern/cycles/render/integrator.h (+3, -0) (Diff)
/intern/cycles/render/session.cpp (+4, -0) (Diff)
/intern/cycles/render/session.h (+3, -0) (Diff)
/intern/cycles/util/util_atomic.h (+2, -0) (Diff)
/intern/cycles/util/util_types.h (+5, -0) (Diff)
Tehnyt: Miika HämäläinenViimeksi päivitetty: 07.11.2014 14:18MiikaH:n Sivut a.k.a. MiikaHweb | 2003-2021