[Scummvm-git-logs] scummvm master -> 32b0541931d1aa03f03433312edac79c56aaa832

mistydemeo noreply at scummvm.org
Thu Mar 27 02:55:20 UTC 2025


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:
32b0541931 DIRECTOR: fix invalid cropping in virtual desktop


Commit: 32b0541931d1aa03f03433312edac79c56aaa832
    https://github.com/scummvm/scummvm/commit/32b0541931d1aa03f03433312edac79c56aaa832
Author: Misty De Meo (mistydemeo at gmail.com)
Date: 2025-03-26T19:52:41-07:00

Commit Message:
DIRECTOR: fix invalid cropping in virtual desktop

The mismatch between rect locations meant that, if the virtual
desktop was on, windows would have a bit of their content to the
top and bottom clipped out.

Changed paths:
    engines/director/window.cpp


diff --git a/engines/director/window.cpp b/engines/director/window.cpp
index 3877db41bb8..94d57168ae3 100644
--- a/engines/director/window.cpp
+++ b/engines/director/window.cpp
@@ -165,7 +165,12 @@ bool Window::render(bool forceRedraw, Graphics::ManagedSurface *blitTo) {
 
 	for (auto &i : _dirtyRects) {
 		Common::Rect r = i;
-		r.clip(getInnerDimensions());
+		// The inner dimensions are relative to the virtual desktop while
+		// r isn't, so we need to move the window to be relative to the
+		// same sapce.
+		Common::Rect windowRect = getInnerDimensions();
+		windowRect.moveTo(r.left, r.top);
+		r.clip(windowRect);
 
 		_dirtyChannels = _currentMovie->getScore()->getSpriteIntersections(r);
 




More information about the Scummvm-git-logs mailing list