[Scummvm-git-logs] scummvm master -> 50fe6f508db4b1f840a604a3999cd644941058a9
dreammaster
paulfgilbert at gmail.com
Tue Feb 26 06:45:14 CET 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:
eae00fe6f9 SHERLOCK: 3DO: Fix transparency for characters, and speech dialogs
50fe6f508d SHERLOCK: 3DO: Fix display of map screen
Commit: eae00fe6f9f0eb565f2c38447d705945db0e6ba6
https://github.com/scummvm/scummvm/commit/eae00fe6f9f0eb565f2c38447d705945db0e6ba6
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2019-02-25T21:27:30-08:00
Commit Message:
SHERLOCK: 3DO: Fix transparency for characters, and speech dialogs
Changed paths:
engines/sherlock/scalpel/scalpel_user_interface.cpp
engines/sherlock/surface.cpp
engines/sherlock/surface.h
diff --git a/engines/sherlock/scalpel/scalpel_user_interface.cpp b/engines/sherlock/scalpel/scalpel_user_interface.cpp
index 8dae24e..8f0ebbf 100644
--- a/engines/sherlock/scalpel/scalpel_user_interface.cpp
+++ b/engines/sherlock/scalpel/scalpel_user_interface.cpp
@@ -2105,7 +2105,7 @@ void ScalpelUserInterface::summonWindow(bool slideUp, int height) {
Screen &screen = *_vm->_screen;
// Extract the window that's been drawn on the back buffer
- Surface tempSurface(SHERLOCK_SCREEN_WIDTH, SHERLOCK_SCREEN_HEIGHT - height);
+ Surface tempSurface(SHERLOCK_SCREEN_WIDTH, SHERLOCK_SCREEN_HEIGHT - height, screen._backBuffer1.format);
Common::Rect r(0, height, SHERLOCK_SCREEN_WIDTH, SHERLOCK_SCREEN_HEIGHT);
tempSurface.SHblitFrom(screen._backBuffer1, Common::Point(0, 0), r);
diff --git a/engines/sherlock/surface.cpp b/engines/sherlock/surface.cpp
index cca0126..a5fbca5 100644
--- a/engines/sherlock/surface.cpp
+++ b/engines/sherlock/surface.cpp
@@ -22,6 +22,7 @@
#include "sherlock/surface.h"
#include "sherlock/fonts.h"
+#include "sherlock/sherlock.h"
namespace Sherlock {
@@ -34,6 +35,10 @@ BaseSurface::BaseSurface(int width_, int height_) : Graphics::Screen(width_, hei
create(width_, height_);
}
+BaseSurface::BaseSurface(int width_, int height_, const Graphics::PixelFormat &pf) :
+ Graphics::Screen(width_, height_, pf), Fonts() {
+}
+
void BaseSurface::writeString(const Common::String &str, const Common::Point &pt, uint overrideColor) {
Fonts::writeString(this, str, pt, overrideColor);
}
@@ -62,7 +67,7 @@ void BaseSurface::SHtransBlitFrom(const Graphics::Surface &src, const Common::Po
Common::Rect destRect(pt.x, pt.y, pt.x + src.w * SCALE_THRESHOLD / scaleVal,
pt.y + src.h * SCALE_THRESHOLD / scaleVal);
- Graphics::Screen::transBlitFrom(src, srcRect, destRect, TRANSPARENCY,
+ Graphics::Screen::transBlitFrom(src, srcRect, destRect, IS_3DO ? 0 : TRANSPARENCY,
flipped, overrideColor);
}
diff --git a/engines/sherlock/surface.h b/engines/sherlock/surface.h
index 7514c89..6e2904e 100644
--- a/engines/sherlock/surface.h
+++ b/engines/sherlock/surface.h
@@ -50,6 +50,7 @@ public:
* Constructor
*/
BaseSurface(int width, int height);
+ BaseSurface(int width_, int height_, const Graphics::PixelFormat &pf);
/**
* Draws a surface on this surface
@@ -122,6 +123,7 @@ protected:
public:
Surface() : BaseSurface() {}
Surface(int width_, int height_) : BaseSurface(width_, height_) {}
+ Surface(int width_, int height_, const Graphics::PixelFormat &pf) : BaseSurface(width_, height_, pf) {}
};
} // End of namespace Sherlock
Commit: 50fe6f508db4b1f840a604a3999cd644941058a9
https://github.com/scummvm/scummvm/commit/50fe6f508db4b1f840a604a3999cd644941058a9
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2019-02-25T21:44:54-08:00
Commit Message:
SHERLOCK: 3DO: Fix display of map screen
Changed paths:
engines/sherlock/scalpel/3do/scalpel_3do_screen.cpp
engines/sherlock/scalpel/scalpel_map.cpp
diff --git a/engines/sherlock/scalpel/3do/scalpel_3do_screen.cpp b/engines/sherlock/scalpel/3do/scalpel_3do_screen.cpp
index 163f10d..fb2f6f8 100644
--- a/engines/sherlock/scalpel/3do/scalpel_3do_screen.cpp
+++ b/engines/sherlock/scalpel/3do/scalpel_3do_screen.cpp
@@ -46,6 +46,7 @@ void Scalpel3DOScreen::SHblitFrom(const Graphics::Surface &src, const Common::Po
}
Common::Rect srcRect = srcBounds;
+ srcRect.clip(320, 200);
Common::Rect destRect(pt.x, pt.y, pt.x + srcRect.width(), pt.y + srcRect.height());
if (!srcRect.isValidRect() || !clip(srcRect, destRect))
diff --git a/engines/sherlock/scalpel/scalpel_map.cpp b/engines/sherlock/scalpel/scalpel_map.cpp
index ba14b5b..bf845c3 100644
--- a/engines/sherlock/scalpel/scalpel_map.cpp
+++ b/engines/sherlock/scalpel/scalpel_map.cpp
@@ -56,7 +56,7 @@ const byte *MapPaths::getPath(int srcLocation, int destLocation) {
/*----------------------------------------------------------------*/
-ScalpelMap::ScalpelMap(SherlockEngine *vm): Map(vm), _topLine(g_system->getWidth(), 12) {
+ScalpelMap::ScalpelMap(SherlockEngine *vm): Map(vm), _topLine(g_system->getWidth(), 12, g_system->getScreenFormat()) {
_mapCursors = nullptr;
_shapes = nullptr;
_iconShapes = nullptr;
@@ -332,7 +332,7 @@ void ScalpelMap::setupSprites() {
_cursorIndex = 0;
events.setCursor((*_mapCursors)[_cursorIndex]._frame);
- _iconSave.create((*_shapes)[4]._width, (*_shapes)[4]._height);
+ _iconSave.create((*_shapes)[4]._width, (*_shapes)[4]._height, g_system->getScreenFormat());
Person &p = people[HOLMES];
p._description = " ";
p._type = CHARACTER;
More information about the Scummvm-git-logs
mailing list