[Scummvm-git-logs] scummvm master -> 04162799805e2f37de6c08e494cb9e76eb6972e0

lephilousophe noreply at scummvm.org
Tue Jan 24 18:43:08 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:
0416279980 OPENGL: Fix glitch when shaking screen


Commit: 04162799805e2f37de6c08e494cb9e76eb6972e0
    https://github.com/scummvm/scummvm/commit/04162799805e2f37de6c08e494cb9e76eb6972e0
Author: Le Philousophe (lephilousophe at users.noreply.github.com)
Date: 2023-01-24T19:40:48+01:00

Commit Message:
OPENGL: Fix glitch when shaking screen

Everything was converted to unsigned instead of the opposite.

Changed paths:
    backends/graphics/opengl/opengl-graphics.cpp


diff --git a/backends/graphics/opengl/opengl-graphics.cpp b/backends/graphics/opengl/opengl-graphics.cpp
index 13b9572f121..15c536b7fb7 100644
--- a/backends/graphics/opengl/opengl-graphics.cpp
+++ b/backends/graphics/opengl/opengl-graphics.cpp
@@ -1489,8 +1489,8 @@ void OpenGLGraphicsManager::recalculateDisplayAreas() {
 	                          _gameDrawRect.width(),
 	                          _gameDrawRect.height());
 
-	_shakeOffsetScaled = Common::Point(_gameScreenShakeXOffset * _gameDrawRect.width() / _currentState.gameWidth,
-		_gameScreenShakeYOffset * _gameDrawRect.height() / _currentState.gameHeight);
+	_shakeOffsetScaled = Common::Point(_gameScreenShakeXOffset * _gameDrawRect.width() / (int)_currentState.gameWidth,
+		_gameScreenShakeYOffset * _gameDrawRect.height() / (int)_currentState.gameHeight);
 
 	// Update the cursor position to adjust for new display area.
 	setMousePosition(_cursorX, _cursorY);




More information about the Scummvm-git-logs mailing list