Merge branch 'blender-v4.0-release'
This commit is contained in:
@@ -663,6 +663,16 @@ void EEVEE_render_draw(EEVEE_Data *vedata, RenderEngine *engine, RenderLayer *rl
|
||||
/* Perform render step between samples to allow
|
||||
* flushing of freed GPUBackend resources. */
|
||||
GPU_render_step();
|
||||
if (GPU_type_matches_ex(GPU_DEVICE_ANY, GPU_OS_ANY, GPU_DRIVER_ANY, GPU_BACKEND_METAL)) {
|
||||
if (render_samples > 0 && ((render_samples % 64) == 0)) {
|
||||
/* Allow GPU to sync with CPU to prevent overly large command submissions being in-flight
|
||||
* simultaneously. Reduces total in-flight memory required for rendering. */
|
||||
GPU_finish();
|
||||
}
|
||||
else {
|
||||
GPU_flush();
|
||||
}
|
||||
}
|
||||
|
||||
RE_engine_update_progress(engine, float(render_samples++) / float(tot_sample));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user