diff options
author | Hyunjun Ko <[email protected]> | 2020-02-20 15:46:57 +0900 |
---|---|---|
committer | Marge Bot <[email protected]> | 2020-03-12 03:10:16 +0000 |
commit | 4a45c84672f7eafef23c6210f3d8dd56ae020242 (patch) | |
tree | bd7b63caac72fda6804c5d6f8df739f524202305 /src/freedreno | |
parent | 9ff1959ca5d24afe48bec20edf7e3d059d254134 (diff) |
turnip: Implement an empty function vkCmdDrawIndirectByteCountEXT
TODO. We should implement this since indirect draw is enabled.
Signed-off-by: Hyunjun Ko <[email protected]>
Reviewed-by: Jonathan Marek <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/3942>
Diffstat (limited to 'src/freedreno')
-rw-r--r-- | src/freedreno/vulkan/tu_cmd_buffer.c | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/freedreno/vulkan/tu_cmd_buffer.c b/src/freedreno/vulkan/tu_cmd_buffer.c index 4367f8e4dfb..d3e04889feb 100644 --- a/src/freedreno/vulkan/tu_cmd_buffer.c +++ b/src/freedreno/vulkan/tu_cmd_buffer.c @@ -2706,6 +2706,12 @@ struct tu_draw_info */ struct tu_buffer *count_buffer; uint64_t count_buffer_offset; + + /** + * Stream output parameters resource. + */ + struct tu_buffer *streamout_buffer; + uint64_t streamout_buffer_offset; }; #define ENABLE_ALL (CP_SET_DRAW_STATE__0_BINNING | CP_SET_DRAW_STATE__0_GMEM | CP_SET_DRAW_STATE__0_SYSMEM) @@ -3938,6 +3944,28 @@ tu_CmdDrawIndexedIndirect(VkCommandBuffer commandBuffer, tu_draw(cmd_buffer, &info); } +void tu_CmdDrawIndirectByteCountEXT(VkCommandBuffer commandBuffer, + uint32_t instanceCount, + uint32_t firstInstance, + VkBuffer _counterBuffer, + VkDeviceSize counterBufferOffset, + uint32_t counterOffset, + uint32_t vertexStride) +{ + TU_FROM_HANDLE(tu_cmd_buffer, cmd_buffer, commandBuffer); + TU_FROM_HANDLE(tu_buffer, buffer, _counterBuffer); + + struct tu_draw_info info = {}; + + info.instance_count = instanceCount; + info.first_instance = firstInstance; + info.streamout_buffer = buffer; + info.streamout_buffer_offset = counterBufferOffset; + info.stride = vertexStride; + + tu_draw(cmd_buffer, &info); +} + struct tu_dispatch_info { /** |