[Scummvm-git-logs] scummvm master -> 904e58c35b00c02bf869c17abb9f037e76d4a1a4
digitall
547637+digitall at users.noreply.github.com
Thu Oct 3 06:00:07 CEST 2019
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:
7cc908f0ac DIRECTOR: Fix MSVC Warnings
904e58c35b SLUDGE: Really Fix MSVC Warnings
Commit: 7cc908f0ac049a9be9cd425a38124c6238ad3629
https://github.com/scummvm/scummvm/commit/7cc908f0ac049a9be9cd425a38124c6238ad3629
Author: D G Turner (digitall at scummvm.org)
Date: 2019-10-03T04:56:46+01:00
Commit Message:
DIRECTOR: Fix MSVC Warnings
Changed paths:
engines/director/lingo/lingo-gr.cpp
engines/director/lingo/lingo-gr.y
engines/director/lingo/lingo-lex.cpp
diff --git a/engines/director/lingo/lingo-gr.cpp b/engines/director/lingo/lingo-gr.cpp
index 744049e..9f4fe49 100644
--- a/engines/director/lingo/lingo-gr.cpp
+++ b/engines/director/lingo/lingo-gr.cpp
@@ -2290,7 +2290,7 @@ yyreduce:
WRITE_UINT32(&finish, (yyvsp[(7) - (11)].code) - (yyvsp[(1) - (11)].code));
WRITE_UINT32(&body, (yyvsp[(9) - (11)].code) - (yyvsp[(1) - (11)].code));
WRITE_UINT32(&end, (yyvsp[(10) - (11)].code) - (yyvsp[(1) - (11)].code));
- WRITE_UINT32(&inc, -1);
+ WRITE_UINT32(&inc, (uint32)-1);
(*g_lingo->_currentScript)[(yyvsp[(1) - (11)].code) + 1] = init; /* initial count value */
(*g_lingo->_currentScript)[(yyvsp[(1) - (11)].code) + 2] = finish;/* final count value */
(*g_lingo->_currentScript)[(yyvsp[(1) - (11)].code) + 3] = body; /* body of loop */
diff --git a/engines/director/lingo/lingo-gr.y b/engines/director/lingo/lingo-gr.y
index 08af780..9741055 100644
--- a/engines/director/lingo/lingo-gr.y
+++ b/engines/director/lingo/lingo-gr.y
@@ -236,7 +236,7 @@ stmt: stmtoneliner
WRITE_UINT32(&finish, $7 - $1);
WRITE_UINT32(&body, $9 - $1);
WRITE_UINT32(&end, $10 - $1);
- WRITE_UINT32(&inc, -1);
+ WRITE_UINT32(&inc, (uint32)-1);
(*g_lingo->_currentScript)[$1 + 1] = init; /* initial count value */
(*g_lingo->_currentScript)[$1 + 2] = finish;/* final count value */
(*g_lingo->_currentScript)[$1 + 3] = body; /* body of loop */
diff --git a/engines/director/lingo/lingo-lex.cpp b/engines/director/lingo/lingo-lex.cpp
index 1f5d81d..7b98269 100644
--- a/engines/director/lingo/lingo-lex.cpp
+++ b/engines/director/lingo/lingo-lex.cpp
@@ -333,7 +333,7 @@ void yyfree (void * );
/* Begin user sect3 */
-#define yywrap(n) 1
+#define yywrap() 1
#define YY_SKIP_YYWRAP
typedef unsigned char YY_CHAR;
@@ -1648,7 +1648,7 @@ case YY_STATE_EOF(INITIAL):
{
(yy_did_buffer_switch_on_eof) = 0;
- if ( yywrap( ) )
+ if ( yywrap() )
{
/* Note: because we've taken care in
* yy_get_next_buffer() to have set up
@@ -1947,7 +1947,7 @@ static int yy_get_next_buffer (void)
case EOB_ACT_END_OF_FILE:
{
- if ( yywrap( ) )
+ if ( yywrap() )
return 0;
if ( ! (yy_did_buffer_switch_on_eof) )
Commit: 904e58c35b00c02bf869c17abb9f037e76d4a1a4
https://github.com/scummvm/scummvm/commit/904e58c35b00c02bf869c17abb9f037e76d4a1a4
Author: D G Turner (digitall at scummvm.org)
Date: 2019-10-03T04:57:18+01:00
Commit Message:
SLUDGE: Really Fix MSVC Warnings
Changed paths:
engines/sludge/backdrop.cpp
engines/sludge/sprites.cpp
engines/sludge/thumbnail.cpp
diff --git a/engines/sludge/backdrop.cpp b/engines/sludge/backdrop.cpp
index 618e8e9..b7671da 100644
--- a/engines/sludge/backdrop.cpp
+++ b/engines/sludge/backdrop.cpp
@@ -388,8 +388,7 @@ bool GraphicsManager::loadLightMap(int v) {
if (_lightMapMode == LIGHTMAPMODE_HOTSPOT) {
return fatal("Light map width and height don't match scene width and height. That is required for lightmaps in HOTSPOT mode.");
} else if (_lightMapMode == LIGHTMAPMODE_PIXEL) {
- uint tmpColor = TS_ARGB(255, 255, 255, 255);
- tmp.blit(_lightMap, 0, 0, Graphics::FLIP_NONE, nullptr, tmpColor, (int)_sceneWidth, (int)_sceneHeight);
+ tmp.blit(_lightMap, 0, 0, Graphics::FLIP_NONE, nullptr, TS_ARGB((uint)255, (uint)255, (uint)255, (uint)255), (int)_sceneWidth, (int)_sceneHeight);
} else {
_lightMap.copyFrom(tmp);
}
diff --git a/engines/sludge/sprites.cpp b/engines/sludge/sprites.cpp
index 4b63fee..bdf725f 100644
--- a/engines/sludge/sprites.cpp
+++ b/engines/sludge/sprites.cpp
@@ -339,8 +339,7 @@ void GraphicsManager::blendColor(Graphics::Surface *blitted, uint32 color, Graph
Graphics::TransparentSurface tmp;
tmp.create(blitted->w, blitted->h, blitted->format);
tmp.fillRect(Common::Rect(0, 0, tmp.w, tmp.h), color);
- uint tmpColor = TS_ARGB(255, 255, 255, 255);
- tmp.blit(*blitted, 0, 0, Graphics::FLIP_NONE, nullptr, tmpColor, (int)blitted->w, (int)blitted->h, mode);
+ tmp.blit(*blitted, 0, 0, Graphics::FLIP_NONE, nullptr, TS_ARGB((uint)255, (uint)255, (uint)255, (uint)255), (int)blitted->w, (int)blitted->h, mode);
tmp.free();
}
@@ -373,11 +372,10 @@ Graphics::Surface *GraphicsManager::applyLightmapToSprite(Graphics::Surface *&bl
Graphics::TransparentSurface tmp(_lightMap, false);
Common::Rect rect_none(x1, y1, x1 + diffX, y1 + diffY);
Common::Rect rect_h(_sceneWidth - x1 - diffX, y1, _sceneWidth - x1, y1 + diffY);
- uint tmpColor = TS_ARGB(255, 255, 255, 255);
tmp.blit(*blitted, 0, 0,
(mirror ? Graphics::FLIP_H : Graphics::FLIP_NONE),
(mirror ? &rect_h : &rect_none),
- tmpColor,
+ TS_ARGB((uint)255, (uint)255, (uint)255, (uint)255),
(int)blitted->w, (int)blitted->h, Graphics::BLEND_MULTIPLY);
}
} else {
@@ -461,8 +459,7 @@ bool GraphicsManager::scaleSprite(Sprite &single, const SpritePalette &fontPal,
// Use Transparent surface to scale and blit
if (!_zBuffer->numPanels) {
Graphics::TransparentSurface tmp(*blitted, false);
- uint tmpColor = TS_ARGB(255, 255, 255, 255);
- tmp.blit(_renderSurface, x1, y1, (mirror ? Graphics::FLIP_H : Graphics::FLIP_NONE), nullptr, tmpColor, diffX, diffY);
+ tmp.blit(_renderSurface, x1, y1, (mirror ? Graphics::FLIP_H : Graphics::FLIP_NONE), nullptr, TS_ARGB((uint)255, (uint)255, (uint)255, (uint)255), diffX, diffY);
if (ptr) {
ptr->free();
delete ptr;
@@ -523,8 +520,7 @@ void GraphicsManager::displaySpriteLayers() {
SpriteLayer::iterator it;
for (it = _spriteLayers->layer[i].begin(); it != _spriteLayers->layer[i].end(); ++it) {
Graphics::TransparentSurface tmp(*(*it)->surface, false);
- uint tmpColor = TS_ARGB(255, 255, 255, 255);
- tmp.blit(_renderSurface, (*it)->x, (*it)->y, (*it)->flip, nullptr, tmpColor, (*it)->width, (*it)->height);
+ tmp.blit(_renderSurface, (*it)->x, (*it)->y, (*it)->flip, nullptr, TS_ARGB((uint)255, (uint)255, (uint)255, (uint)255), (*it)->width, (*it)->height);
}
}
killSpriteLayers();
@@ -579,8 +575,7 @@ void GraphicsManager::fixScaleSprite(int x, int y, Sprite &single, const SpriteP
// draw sprite
if (!_zBuffer->numPanels) {
Graphics::TransparentSurface tmp(single.surface, false);
- uint tmpColor = TS_ARGB(255, 255, 255, 255);
- tmp.blit(_renderSurface, x1, y1, (mirror ? Graphics::FLIP_H : Graphics::FLIP_NONE), nullptr, tmpColor, diffX, diffY);
+ tmp.blit(_renderSurface, x1, y1, (mirror ? Graphics::FLIP_H : Graphics::FLIP_NONE), nullptr, TS_ARGB((uint)255, (uint)255, (uint)255, (uint)255), diffX, diffY);
if (ptr) {
ptr->free();
delete ptr;
diff --git a/engines/sludge/thumbnail.cpp b/engines/sludge/thumbnail.cpp
index 2c086b3..c6bce5a 100644
--- a/engines/sludge/thumbnail.cpp
+++ b/engines/sludge/thumbnail.cpp
@@ -120,8 +120,7 @@ void GraphicsManager::showThumbnail(const Common::String &filename, int atX, int
if (fileHeight + atY > (int)_sceneHeight)
fileHeight = _sceneHeight - atY;
- uint tmpColor = TS_ARGB(255, 255, 255, 255);
- thumbnail.blit(_backdropSurface, atX, atY, Graphics::FLIP_NONE, nullptr, tmpColor, fileWidth, fileHeight);
+ thumbnail.blit(_backdropSurface, atX, atY, Graphics::FLIP_NONE, nullptr, TS_ARGB((uint)255, (uint)255, (uint)255, (uint)255), fileWidth, fileHeight);
thumbnail.free();
}
}
More information about the Scummvm-git-logs
mailing list