From a4ed6c58b0989155e5be4864daf53b7e3d62f31e Mon Sep 17 00:00:00 2001 From: Dimitris Panokostas Date: Sun, 25 Nov 2018 19:43:32 +0100 Subject: [PATCH] Ensure P96 pixbytes value is updated when locking --- src/osdep/amiberry_gfx.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/osdep/amiberry_gfx.cpp b/src/osdep/amiberry_gfx.cpp index d1ba0980..9d85d2b6 100644 --- a/src/osdep/amiberry_gfx.cpp +++ b/src/osdep/amiberry_gfx.cpp @@ -1386,6 +1386,7 @@ void gfx_set_picasso_modeinfo(uae_u32 w, uae_u32 h, uae_u32 depth, RGBFTYPE rgbf picasso_vidinfo.height = h; picasso_vidinfo.depth = screen->format->BitsPerPixel; // Native depth picasso_vidinfo.extra_mem = 1; + picasso_vidinfo.rowbytes = screen->pitch; picasso_vidinfo.pixbytes = screen->format->BytesPerPixel; // Native bytes picasso_vidinfo.offset = 0; @@ -1411,6 +1412,7 @@ uae_u8* gfx_lock_picasso() if (SDL_MUSTLOCK(screen)) SDL_LockSurface(screen); + picasso_vidinfo.pixbytes = screen->format->BytesPerPixel; picasso_vidinfo.rowbytes = screen->pitch; return static_cast(screen->pixels); }