[Scummvm-git-logs] scummvm master -> 40fc49256dc766d98789f57ee967bc94b7e46c8a
sev-
noreply at scummvm.org
Mon Jan 16 16:57:09 UTC 2023
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
40fc49256d SLUDGE: Make sure initial backdrop gets its alpha channel stored
Commit: 40fc49256dc766d98789f57ee967bc94b7e46c8a
https://github.com/scummvm/scummvm/commit/40fc49256dc766d98789f57ee967bc94b7e46c8a
Author: Sebastian Krzyszkowiak (dos at dosowisko.net)
Date: 2023-01-16T17:57:04+01:00
Commit Message:
SLUDGE: Make sure initial backdrop gets its alpha channel stored
OpenSLUDGE draws the first backdrop image with alpha channel
intact. Afterwards, next images are blended with previous backdrop
contents.
So far ScummVM always did the later part, but never the former,
which caused parallax to not work as it relies on alpha channel
being propagated into backdrop (which gets initiallly filled
with opaque black, so it had no chance to ever be transparent).
Fix that by clearing the area the first backdrop image is about
to get blitted into with full transparency.
Changed paths:
engines/sludge/backdrop.cpp
diff --git a/engines/sludge/backdrop.cpp b/engines/sludge/backdrop.cpp
index 0479bc6f0c4..a6710d7496f 100644
--- a/engines/sludge/backdrop.cpp
+++ b/engines/sludge/backdrop.cpp
@@ -430,6 +430,9 @@ bool GraphicsManager::loadHSI(int num, Common::SeekableReadStream *stream, int x
return false;
}
+ if (!_backdropExists)
+ _backdropSurface.fillRect(Common::Rect(x, y, x + tmp.w, y + tmp.h), _renderSurface.format.ARGBToColor(0, 0, 0, 0));
+
// copy surface loaded to backdrop
Graphics::TransparentSurface tmp_trans(tmp, false);
tmp_trans.blit(_backdropSurface, x, y);
More information about the Scummvm-git-logs
mailing list