venus: add struct vn_command_buffer_builder

We are going to remember more states.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11067>
This commit is contained in:
Chia-I Wu
2021-05-05 12:15:31 -07:00
committed by Marge Bot
parent 67d2939e4a
commit fb549d21d8
2 changed files with 15 additions and 10 deletions
+8 -3
View File
@@ -33,18 +33,23 @@ enum vn_command_buffer_state {
VN_COMMAND_BUFFER_STATE_INVALID,
};
struct vn_command_buffer_builder {
/* for scrubbing VK_IMAGE_LAYOUT_PRESENT_SRC_KHR */
uint32_t image_barrier_count;
VkImageMemoryBarrier *image_barriers;
};
struct vn_command_buffer {
struct vn_object_base base;
struct vn_device *device;
/* for scrubbing VK_IMAGE_LAYOUT_PRESENT_SRC_KHR */
VkAllocationCallbacks allocator;
uint32_t image_barrier_count;
VkImageMemoryBarrier *image_barriers;
struct list_head head;
struct vn_command_buffer_builder builder;
enum vn_command_buffer_state state;
struct vn_cs_encoder cs;
};