Changeset View
Changeset View
Standalone View
Standalone View
intern/cycles/session/session.cpp
| Show First 20 Lines • Show All 372 Lines • ▼ Show 20 Lines | if (switched_to_new_tile) { | ||||
| path_trace_->reset(buffer_params_, tile_params, did_reset); | path_trace_->reset(buffer_params_, tile_params, did_reset); | ||||
| } | } | ||||
| const int resolution = render_work.resolution_divider; | const int resolution = render_work.resolution_divider; | ||||
| const int width = max(1, buffer_params_.full_width / resolution); | const int width = max(1, buffer_params_.full_width / resolution); | ||||
| const int height = max(1, buffer_params_.full_height / resolution); | const int height = max(1, buffer_params_.full_height / resolution); | ||||
| { | |||||
| /* Load render kernels, before device update where we upload data to the GPU. | |||||
| * Do it outside of the scene mutex since the heavy part of the loading (i.e. kernel | |||||
| * compilation) does not depend on the scene and some other functionality (like display | |||||
| * driver) might be waiting on the scene mutex to synchronize display pass. | |||||
| * | |||||
| * The scene will lock itself for the short period if it needs to update kernel features. */ | |||||
| scene_lock.unlock(); | |||||
| scene->load_kernels(progress); | |||||
| scene_lock.lock(); | |||||
| } | |||||
| if (update_scene(width, height)) { | if (update_scene(width, height)) { | ||||
| profiler.reset(scene->shaders.size(), scene->objects.size()); | profiler.reset(scene->shaders.size(), scene->objects.size()); | ||||
| } | } | ||||
| /* Unlock scene mutex before loading denoiser kernels, since that may attempt to activate | /* Unlock scene mutex before loading denoiser kernels, since that may attempt to activate | ||||
| * graphics interop, which can deadlock when the scene mutex is still being held. */ | * graphics interop, which can deadlock when the scene mutex is still being held. */ | ||||
| scene_lock.unlock(); | scene_lock.unlock(); | ||||
| ▲ Show 20 Lines • Show All 331 Lines • Show Last 20 Lines | |||||