From 9bc82ab1b46f47ac7f0d9920066b2e8ab0b22a86 Mon Sep 17 00:00:00 2001 From: Jacob McNamee Date: Thu, 9 May 2024 21:08:50 -0700 Subject: [PATCH] [client] egl: fix misuse of stride vs. pitch in `texBufferStreamUpdate` --- client/renderers/EGL/texture_buffer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/renderers/EGL/texture_buffer.c b/client/renderers/EGL/texture_buffer.c index c13f4b5d..36e886db 100644 --- a/client/renderers/EGL/texture_buffer.c +++ b/client/renderers/EGL/texture_buffer.c @@ -206,8 +206,8 @@ static bool egl_texBufferStreamUpdate(EGL_Texture * texture, const uint8_t * src = update->buffer + update->pitch * update->height; for(int y = 0; y < update->height; ++y) { - src -= update->stride; - memcpy(dst, src, update->stride); + src -= update->pitch; + memcpy(dst, src, update->pitch); dst += texture->format.pitch; } }