Add direct dispatch for Bitonic Sort when using small input buffer

This commit is contained in:
Wojtek Figat
2025-08-08 17:03:39 +02:00
parent 0ea555b041
commit 519a9c0a14
5 changed files with 66 additions and 52 deletions

View File

@@ -18,7 +18,7 @@ private:
GPUBuffer* _dispatchArgsBuffer = nullptr;
GPUConstantBuffer* _cb;
GPUShaderProgramCS* _indirectArgsCS;
GPUShaderProgramCS* _preSortCS;
ComputeShaderPermutation<2> _preSortCS;
GPUShaderProgramCS* _innerSortCS;
GPUShaderProgramCS* _outerSortCS;
GPUShaderProgramCS* _copyIndicesCS;
@@ -46,7 +46,7 @@ public:
#if COMPILE_WITH_DEV_ENV
void OnShaderReloading(Asset* obj)
{
_preSortCS = nullptr;
_preSortCS.Clear();
_innerSortCS = nullptr;
_outerSortCS = nullptr;
invalidateResources();