From f42a343e85c90a86140664a5974b5266dcf3fa55 Mon Sep 17 00:00:00 2001 From: Samuliak Date: Sat, 6 Jul 2024 09:59:35 +0200 Subject: [PATCH] add: comment --- src/host_shaders/metal_copy_to_lut_texture.metal | 1 + 1 file changed, 1 insertion(+) diff --git a/src/host_shaders/metal_copy_to_lut_texture.metal b/src/host_shaders/metal_copy_to_lut_texture.metal index 1c996516..ef993b64 100644 --- a/src/host_shaders/metal_copy_to_lut_texture.metal +++ b/src/host_shaders/metal_copy_to_lut_texture.metal @@ -3,6 +3,7 @@ using namespace metal; constant ushort lutTextureWidth [[function_constant(0)]]; +// The copy is done in a vertex shader instead of a compute kernel, since dispatching compute would require ending the render pass vertex void vertexCopyToLutTexture(uint vid [[vertex_id]], texture1d_array out [[texture(0)]], constant ushort* data [[buffer(0)]]) { out.write(data[vid], vid % lutTextureWidth, vid / lutTextureWidth); }