[Scummvm-git-logs] scummvm master -> 7f6189b7b9c78e7595221b2e490c6d3c6c61a302
Strangerke
noreply at scummvm.org
Mon May 20 14:55:46 UTC 2024
This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
7b76ec5f73 BAGEL: Initialize variables in CBagPanBitmap
7f6189b7b9 BAGEL: Fix for two mostly false positives (null dereferencing before check a value which isn't null, and an error in var
Commit: 7b76ec5f73c584cb5a08683ae7cb271ae7fc0aa7
https://github.com/scummvm/scummvm/commit/7b76ec5f73c584cb5a08683ae7cb271ae7fc0aa7
Author: Strangerke (arnaud.boutonne at gmail.com)
Date: 2024-05-20T15:27:29+01:00
Commit Message:
BAGEL: Initialize variables in CBagPanBitmap
Changed paths:
engines/bagel/baglib/pan_bitmap.cpp
diff --git a/engines/bagel/baglib/pan_bitmap.cpp b/engines/bagel/baglib/pan_bitmap.cpp
index b05acfc3dc1..8f30f7fafe8 100644
--- a/engines/bagel/baglib/pan_bitmap.cpp
+++ b/engines/bagel/baglib/pan_bitmap.cpp
@@ -56,17 +56,21 @@ CBagPanBitmap::CBagPanBitmap(const char *pszFileName, CBofPalette *pPalette, con
int nW = width();
int nH = height();
+ _bPanorama = false;
+ _pCosineTable = nullptr;
+ _bActiveScrolling = false; // The scrolling is not active
+ _xDirection = kDirNONE; // Direction is not moving
+ _xFOVAngle = 0;
+ _nCorrWidth = 0;
+ _nNumDegrees = 0;
+
+
if (nW && nH) {
CBofRect xMaxViewSize(0, 0, nW - 1, nH - 1);
if (nW > 1000) {
xMaxViewSize.left = (long)(nW / MAX_DIV_VIEW);
_bPanorama = true;
- } else
- _bPanorama = false;
-
- _pCosineTable = nullptr;
- _bActiveScrolling = false; // The scrolling is not active
- _xDirection = kDirNONE; // Direction is not moving
+ }
pPalette = getPalette();
@@ -98,6 +102,7 @@ CBagPanBitmap::CBagPanBitmap(const char *pszFileName, CBofPalette *pPalette, con
return;
}
+
_bIsValid = false;
}
Commit: 7f6189b7b9c78e7595221b2e490c6d3c6c61a302
https://github.com/scummvm/scummvm/commit/7f6189b7b9c78e7595221b2e490c6d3c6c61a302
Author: Strangerke (arnaud.boutonne at gmail.com)
Date: 2024-05-20T15:55:38+01:00
Commit Message:
BAGEL: Fix for two mostly false positives (null dereferencing before check a value which isn't null, and an error in variable names)
Changed paths:
engines/bagel/baglib/movie_object.cpp
engines/bagel/spacebar/filter.cpp
diff --git a/engines/bagel/baglib/movie_object.cpp b/engines/bagel/baglib/movie_object.cpp
index ef1f3c19665..9e93faa961d 100644
--- a/engines/bagel/baglib/movie_object.cpp
+++ b/engines/bagel/baglib/movie_object.cpp
@@ -342,9 +342,7 @@ bool CBagMovieObject::runObject() {
// Movies usually mark the transition from one view to another
// but not necessarily a change of sdev's, so make sure we repaint the
// backdrop
- if (pMainWin) {
- pMainWin->setPreFilterPan(true);
- }
+ pMainWin->setPreFilterPan(true);
} else if (nMovFileType == MovieFileType::SOUND) {
CBofSound *pSound = new CBofSound(CBofApp::getApp()->getMainWindow(), sFileName, SOUND_WAVE);
diff --git a/engines/bagel/spacebar/filter.cpp b/engines/bagel/spacebar/filter.cpp
index 37ff0b49100..a11c25ca9ea 100644
--- a/engines/bagel/spacebar/filter.cpp
+++ b/engines/bagel/spacebar/filter.cpp
@@ -638,9 +638,9 @@ static bool ZzazzlFilter(CBofBitmap *pBmp, CBofRect *pRect) {
CBofBitmap *pMiniBitmap = new CBofBitmap(dx, dy, pPal);
- CBofRect dstRect(g_engine->viewRect);
- CBofRect srcRect = pMiniBitmap->getRect();
- pBmp->paint(pMiniBitmap, &srcRect, &dstRect);
+ CBofRect srcRect(g_engine->viewRect);
+ CBofRect dstRect = pMiniBitmap->getRect();
+ pBmp->paint(pMiniBitmap, &dstRect, &srcRect);
CBofRect &filterRect = CMainWindow::getFilterRect();
filterRect.setRect(g_engine->viewRect.left, g_engine->viewRect.top, g_engine->viewRect.left + dx, g_engine->viewRect.top + dy);
More information about the Scummvm-git-logs
mailing list