diff options
author | William Leeson <leesonw> | 2021-10-26 09:30:15 +0300 |
---|---|---|
committer | William Leeson <william@blender.org> | 2021-10-26 17:11:27 +0300 |
commit | 366262bef5426fa98e75c96a1562dd16001fba26 (patch) | |
tree | 80a4fd4c204d1e48bc25dd42bf93c6923e5959c4 /intern/cycles/integrator/work_tile_scheduler.cpp | |
parent | 4094868f7301ed06e6fd0710d1e9193796eb857d (diff) |
Distance Scrambling for for Cycles X - Sobol version
Cycles:Distance Scrambling for Cycles Sobol Sampler
This option implements micro jittering an is based on the INRIA
research paper [[ https://hal.inria.fr/hal-01325702/document | on micro jittering ]]
and work by Lukas Stockner for implementing the scrambling distance.
It works by controlling the correlation between pixels by either using
a user supplied value or an adaptive algorithm to limit the maximum
deviation of the sample values between pixels.
This is a follow up of https://developer.blender.org/D12316
The PMJ version can be found here: https://developer.blender.org/D12511
Reviewed By: leesonw
Differential Revision: https://developer.blender.org/D12318
Diffstat (limited to 'intern/cycles/integrator/work_tile_scheduler.cpp')
-rw-r--r-- | intern/cycles/integrator/work_tile_scheduler.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/intern/cycles/integrator/work_tile_scheduler.cpp b/intern/cycles/integrator/work_tile_scheduler.cpp index c874dffde91..2d1ac07db7f 100644 --- a/intern/cycles/integrator/work_tile_scheduler.cpp +++ b/intern/cycles/integrator/work_tile_scheduler.cpp @@ -33,13 +33,17 @@ void WorkTileScheduler::set_max_num_path_states(int max_num_path_states) max_num_path_states_ = max_num_path_states; } -void WorkTileScheduler::reset(const BufferParams &buffer_params, int sample_start, int samples_num) +void WorkTileScheduler::reset(const BufferParams &buffer_params, + int sample_start, + int samples_num, + float scrambling_distance) { /* Image buffer parameters. */ image_full_offset_px_.x = buffer_params.full_x; image_full_offset_px_.y = buffer_params.full_y; image_size_px_ = make_int2(buffer_params.width, buffer_params.height); + scrambling_distance_ = scrambling_distance; offset_ = buffer_params.offset; stride_ = buffer_params.stride; @@ -54,7 +58,8 @@ void WorkTileScheduler::reset(const BufferParams &buffer_params, int sample_star void WorkTileScheduler::reset_scheduler_state() { - tile_size_ = tile_calculate_best_size(image_size_px_, samples_num_, max_num_path_states_); + tile_size_ = tile_calculate_best_size( + image_size_px_, samples_num_, max_num_path_states_, scrambling_distance_); VLOG(3) << "Will schedule tiles of size " << tile_size_; |