File tree Expand file tree Collapse file tree 2 files changed +17
-1
lines changed
GafferCycles/IECoreCyclesPreview Expand file tree Collapse file tree 2 files changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -4165,6 +4165,20 @@ class CyclesRenderer final : public IECoreScenePreview::Renderer
41654165 m_sessionParams.device = device_fallback;
41664166 }
41674167
4168+ if ( m_sessionParams.denoising .use )
4169+ {
4170+ /* Add additional denoising devices if we are rendering and denoising
4171+ * with different devices. */
4172+ m_sessionParams.device .add_denoising_devices ( m_sessionParams.denoising .type );
4173+
4174+ /* Check if denoiser is supported by device. */
4175+ if ( !( m_sessionParams.device .denoisers & m_sessionParams.denoising .type ) )
4176+ {
4177+ IECore::msg ( IECore::Msg::Warning, " CyclesRenderer" , " Chosen denoising is not compatible with device." );
4178+ m_sessionParams.denoising .use = false ;
4179+ }
4180+ }
4181+
41684182 if ( m_session )
41694183 {
41704184 // A trick to retain the same pointer when re-creating a session.
Original file line number Diff line number Diff line change @@ -82,13 +82,15 @@ static py::list getDevices()
8282 d[" id" ] = device.id ;
8383 d[" num" ] = device.num ;
8484 d[" display_device" ] = device.display_device ;
85- // d["advanced_shading"] = device.advanced_shading;
8685 d[" has_half_images" ] = device.has_half_images ;
8786 d[" has_volume_decoupled" ] = device.has_volume_decoupled ;
87+ d[" has_adaptive_stop_per_sample" ] = device.has_adaptive_stop_per_sample ;
8888 d[" has_osl" ] = device.has_osl ;
8989 d[" use_split_kernel" ] = device.use_split_kernel ;
9090 d[" has_profiling" ] = device.has_profiling ;
9191 d[" cpu_threads" ] = device.cpu_threads ;
92+ d[" has_peer_memory" ] = device.has_peer_memory ;
93+ d[" denoisers" ] = device.denoisers ;
9294
9395 if ( device.type == ccl::DEVICE_OPTIX )
9496 py::scope ().attr ( " hasOptixDenoise" ) = true ;
You can’t perform that action at this time.
0 commit comments