| 30 | } |
| 31 | }; |
| 32 | VulkanRasterSort::VulkanRasterSort(Backend* bn) : VulkanBasicExecution(bn) { |
| 33 | mContent = new Content(static_cast<VulkanBackend*>(bn)); |
| 34 | auto extra = static_cast<VulkanBackend*>(bn); |
| 35 | mLocalSize = std::min(mLocalSize, extra->device().getMaxComputeWorkGroupInvocations()); |
| 36 | { |
| 37 | std::vector<uint32_t> spc = {(uint32_t)256, 1, 1}; |
| 38 | std::vector<VkDescriptorType> types { |
| 39 | VK_DESCRIPTOR_TYPE_STORAGE_BUFFER, |
| 40 | VK_DESCRIPTOR_TYPE_STORAGE_BUFFER, |
| 41 | VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER |
| 42 | }; |
| 43 | if (extra->device().getLocalMemorySize() > 0) { |
| 44 | mContent->cumsum = extra->getPipelineFactory()->getPipeline("glsl_cumsum_comp", types, spc); |
| 45 | } else { |
| 46 | mContent->cumsum = extra->getPipelineFactory()->getPipeline("glsl_cumsum_single_comp", types, spc); |
| 47 | } |
| 48 | } |
| 49 | mRadixSort.reset(new VulkanRadixSort(bn, 16)); |
| 50 | } |
| 51 | VulkanRasterSort:: ~VulkanRasterSort() { |
| 52 | delete mContent; |
| 53 | } |
nothing calls this directly
no test coverage detected