From fef3f0826f46947b6056bab598f7102abdf08a34 Mon Sep 17 00:00:00 2001 From: jackson broussard Date: Sat, 7 Mar 2026 12:39:25 -0800 Subject: [PATCH] Correct Metal backend index buffer offset for indexed draw call --- backends/gpu/metal/sources/commandlist.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backends/gpu/metal/sources/commandlist.m b/backends/gpu/metal/sources/commandlist.m index 6b67bff42..6456d46bb 100644 --- a/backends/gpu/metal/sources/commandlist.m +++ b/backends/gpu/metal/sources/commandlist.m @@ -189,7 +189,7 @@ void kore_metal_command_list_draw_indexed(kore_gpu_command_list *list, uint32_t indexCount:index_count indexType:list->metal.sixteen_bit_indices ? MTLIndexTypeUInt16 : MTLIndexTypeUInt32 indexBuffer:index_buffer - indexBufferOffset:first_index + indexBufferOffset:first_index * (list->metal.sixteen_bit_indices ? sizeof(uint16_t) : sizeof(uint32_t)) instanceCount:instance_count baseVertex:base_vertex baseInstance:first_instance];