SDL: gpu: Fix Z offset for D3D12 realigned 3D texture uploads

From b0d2a4f35528bd08e0a0cb5f7840ff38f3b1f684 Mon Sep 17 00:00:00 2001
From: Caleb Cornett <[EMAIL REDACTED]>
Date: Sun, 2 Mar 2025 00:04:57 -0500
Subject: [PATCH] gpu: Fix Z offset for D3D12 realigned 3D texture uploads

---
 src/gpu/d3d12/SDL_gpu_d3d12.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gpu/d3d12/SDL_gpu_d3d12.c b/src/gpu/d3d12/SDL_gpu_d3d12.c
index be13d8dac5e96..467cffce11518 100644
--- a/src/gpu/d3d12/SDL_gpu_d3d12.c
+++ b/src/gpu/d3d12/SDL_gpu_d3d12.c
@@ -5815,7 +5815,7 @@ static void D3D12_UploadToTexture(
                 &destinationLocation,
                 destination->x,
                 destination->y,
-                sliceIndex,
+                destination->z + sliceIndex,
                 &sourceLocation,
                 NULL);
         }