Vulkan handle and associated information. Command buffer context stores array of handles that are referenced by the tagged commands. VulkanTypedHandle is stored in unpacked form to avoid structure padding gaps.
| 67 | // Command buffer context stores array of handles that are referenced by the tagged commands. |
| 68 | // VulkanTypedHandle is stored in unpacked form to avoid structure padding gaps. |
| 69 | struct HandleRecord { |
| 70 | uint64_t handle = 0; |
| 71 | VulkanObjectType type = kVulkanObjectTypeUnknown; |
| 72 | uint32_t index = vvl::kNoIndex32; |
| 73 | |
| 74 | HandleRecord() = default; |
| 75 | explicit HandleRecord(const VulkanTypedHandle &typed_handle, uint32_t index = vvl::kNoIndex32) |
| 76 | : handle(typed_handle.handle), type(typed_handle.type), index(index) {} |
| 77 | bool IsIndexed() const { return index != vvl::kNoIndex32; } |
| 78 | |
| 79 | VulkanTypedHandle TypedHandle() const { |
| 80 | VulkanTypedHandle typed_handle; |
| 81 | typed_handle.handle = handle; |
| 82 | typed_handle.type = type; |
| 83 | return typed_handle; |
| 84 | } |
| 85 | }; |
| 86 | |
| 87 | enum class SubCommandType { kNone, kSubpassTransition, kLoadOp, kStoreOp, kResolveOp, kIndex }; |
| 88 |