Fix: Draw: Freeze Culling
Bind the frozen culling data as well. Reviewed By: fclem Differential Revision: https://developer.blender.org/D17010
This commit is contained in:
parent
8b660e1cbf
commit
f8328ec172
|
@ -258,7 +258,8 @@ void View::compute_visibility(ObjectBoundsBuf &bounds, uint resource_len, bool d
|
|||
GPU_shader_uniform_1i(shader, "visibility_word_per_draw", word_per_draw);
|
||||
GPU_storagebuf_bind(bounds, GPU_shader_get_ssbo(shader, "bounds_buf"));
|
||||
GPU_storagebuf_bind(visibility_buf_, GPU_shader_get_ssbo(shader, "visibility_buf"));
|
||||
GPU_uniformbuf_bind((frozen_) ? data_freeze_ : data_, DRW_VIEW_UBO_SLOT);
|
||||
GPU_uniformbuf_bind(frozen_ ? data_freeze_ : data_, DRW_VIEW_UBO_SLOT);
|
||||
GPU_uniformbuf_bind(frozen_ ? culling_freeze_ : culling_, DRW_VIEW_CULLING_UBO_SLOT);
|
||||
GPU_compute_dispatch(shader, divide_ceil_u(resource_len, DRW_VISIBILITY_GROUP_SIZE), 1, 1);
|
||||
GPU_memory_barrier(GPU_BARRIER_SHADER_STORAGE);
|
||||
}
|
||||
|
@ -266,6 +267,7 @@ void View::compute_visibility(ObjectBoundsBuf &bounds, uint resource_len, bool d
|
|||
if (frozen_) {
|
||||
/* Bind back the non frozen data. */
|
||||
GPU_uniformbuf_bind(data_, DRW_VIEW_UBO_SLOT);
|
||||
GPU_uniformbuf_bind(culling_, DRW_VIEW_CULLING_UBO_SLOT);
|
||||
}
|
||||
|
||||
GPU_debug_group_end();
|
||||
|
|
Loading…
Reference in New Issue