diff options
author | Bastien Bouclet | 2019-10-14 21:22:40 +0200 |
---|---|---|
committer | Bastien Bouclet | 2019-10-14 21:24:25 +0200 |
commit | dfc0a5127e354ea959edc508db2316505785d85e (patch) | |
tree | dcee931502d65aa31e56fb96d046d75daa2eed73 /backends/platform | |
parent | f22e07825f9dfeec96edffe8ef435ffbfb75ef84 (diff) | |
download | scummvm-rg350-dfc0a5127e354ea959edc508db2316505785d85e.tar.gz scummvm-rg350-dfc0a5127e354ea959edc508db2316505785d85e.tar.bz2 scummvm-rg350-dfc0a5127e354ea959edc508db2316505785d85e.zip |
3DS: Fix OSystem::grabOverlay
Fixes the transparency effects in the GUI.
Diffstat (limited to 'backends/platform')
-rw-r--r-- | backends/platform/3ds/osystem-graphics.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/backends/platform/3ds/osystem-graphics.cpp b/backends/platform/3ds/osystem-graphics.cpp index 15fabc7a01..8e7ae89486 100644 --- a/backends/platform/3ds/osystem-graphics.cpp +++ b/backends/platform/3ds/osystem-graphics.cpp @@ -415,8 +415,11 @@ void OSystem_3DS::clearOverlay() { } void OSystem_3DS::grabOverlay(void *buf, int pitch) { + byte *dst = (byte *)buf; + for (int y = 0; y < getOverlayHeight(); ++y) { - memcpy(buf, _overlay.getBasePtr(0, y), pitch); + memcpy(dst, _overlay.getBasePtr(0, y), getOverlayWidth() * _pfGameTexture.bytesPerPixel); + dst += pitch; } } |