Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Mours <pmours@nvidia.com>2020-02-17 18:15:56 +0300
committerPatrick Mours <pmours@nvidia.com>2020-02-17 18:15:56 +0300
commitab3a6e050c856345d10f8e36155913288559e4dc (patch)
treed2a8b18edbb301a2c0725f100b1e0cb8018f0f19
parent3a53ae8d4bd3b18bdf0a9468742518584f8f49c1 (diff)
Fix artifacts with Cycles viewport denoising when rendering with multiple CUDA devices
Rendering with multiple CUDA devices but denoising with OptiX caused parts of the image to go missing at the start while the resolution was scaled. This is because the copy operation in `MultiDevice::map_neighbor_tiles` which slices the copy across all devices would slice based on the full resolution and not the scaled one and therefore copy incorrect data between devices. Since this is not the recommended way of using viewport denoising anyway, simply avoid those incorrect copies for now by disabling denoising while the resolution is scaled. Doing both rendering and denoising with OptiX is not affected by this, since it avoids those copies altogether anyway.
-rw-r--r--intern/cycles/render/session.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/intern/cycles/render/session.cpp b/intern/cycles/render/session.cpp
index b41844cb132..acf9ca68889 100644
--- a/intern/cycles/render/session.cpp
+++ b/intern/cycles/render/session.cpp
@@ -1115,6 +1115,13 @@ void Session::denoise()
return;
}
+ /* Cannot denoise with resolution divider and separate denoising devices.
+ * It breaks the copy in 'MultiDevice::map_neighbor_tiles' (which operates on the full buffer
+ * dimensions and not the scaled ones). */
+ if (!params.device.denoising_devices.empty() && tile_manager.state.resolution_divider > 1) {
+ return;
+ }
+
/* Add separate denoising task. */
DeviceTask task(DeviceTask::DENOISE);