diff options
author | Bas Nieuwenhuizen <[email protected]> | 2017-05-13 18:05:36 +0200 |
---|---|---|
committer | Bas Nieuwenhuizen <[email protected]> | 2017-05-13 23:05:25 +0200 |
commit | d4e4c36c7c96d3e38b7f3ce6f3aac9956b6c9df8 (patch) | |
tree | bd3eacf912c13c6c23a236d6e28d6e2520f8d449 /src | |
parent | 8efaae3e196976dee82c922bf6fd7da0c1e6a5a5 (diff) |
radv: Save descriptor set even if vertex buffers are not saved.
Totally independent.
Signed-off-by: Bas Nieuwenhuizen <[email protected]>
Reviewed-by: Dave Airlie <[email protected]>
Fixes: 0e6d532d327 "radv/meta: add support for save/restore meta without vertex data."
Diffstat (limited to 'src')
-rw-r--r-- | src/amd/vulkan/radv_meta.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/amd/vulkan/radv_meta.c b/src/amd/vulkan/radv_meta.c index 973316103aa..4f359bd6a9d 100644 --- a/src/amd/vulkan/radv_meta.c +++ b/src/amd/vulkan/radv_meta.c @@ -36,6 +36,7 @@ radv_meta_save_novertex(struct radv_meta_saved_state *state, uint32_t dynamic_mask) { state->old_pipeline = cmd_buffer->state.pipeline; + state->old_descriptor_set0 = cmd_buffer->state.descriptors[0]; state->dynamic_mask = dynamic_mask; radv_dynamic_state_copy(&state->dynamic, &cmd_buffer->state.dynamic, @@ -50,9 +51,9 @@ radv_meta_restore(const struct radv_meta_saved_state *state, struct radv_cmd_buffer *cmd_buffer) { cmd_buffer->state.pipeline = state->old_pipeline; + cmd_buffer->state.descriptors[0] = state->old_descriptor_set0; + cmd_buffer->state.descriptors_dirty |= (1u << 0); if (state->vertex_saved) { - cmd_buffer->state.descriptors[0] = state->old_descriptor_set0; - cmd_buffer->state.descriptors_dirty |= (1u << 0); memcpy(cmd_buffer->state.vertex_bindings, state->old_vertex_bindings, sizeof(state->old_vertex_bindings)); cmd_buffer->state.vb_dirty |= (1 << RADV_META_VERTEX_BINDING_COUNT) - 1; |