summaryrefslogtreecommitdiff
path: root/examples/reflection-api/compute-simple.slang
diff options
context:
space:
mode:
Diffstat (limited to 'examples/reflection-api/compute-simple.slang')
-rw-r--r--examples/reflection-api/compute-simple.slang5
1 files changed, 4 insertions, 1 deletions
diff --git a/examples/reflection-api/compute-simple.slang b/examples/reflection-api/compute-simple.slang
index 3d8872180..00d45d857 100644
--- a/examples/reflection-api/compute-simple.slang
+++ b/examples/reflection-api/compute-simple.slang
@@ -1,5 +1,8 @@
// compute-simple.slang
+static const uint THREADGROUP_SIZE_X = 8;
+static const uint THREADGROUP_SIZE_Y = THREADGROUP_SIZE_X;
+
struct ImageProcessingOptions
{
float3 tintColor;
@@ -10,7 +13,7 @@ struct ImageProcessingOptions
}
[shader("compute")]
-[numthreads(8, 8)]
+[numthreads(THREADGROUP_SIZE_X, THREADGROUP_SIZE_Y)]
void processImage(
uint3 threadID : SV_DispatchThreadID,
uniform Texture2D inputImage,