diff options
author | Nipun Garg | 2019-07-13 04:48:38 +0530 |
---|---|---|
committer | Eugene Sandulenko | 2019-09-03 17:17:18 +0200 |
commit | c5d1ea304b38f22fc7927ef16875b1ef82036886 (patch) | |
tree | 6bccd33004c6ad2d884615f79e418d0a9ea2445f /engines | |
parent | 1feb91b2f8fd4b22ab6911466d136ea342e4c054 (diff) | |
download | scummvm-rg350-c5d1ea304b38f22fc7927ef16875b1ef82036886.tar.gz scummvm-rg350-c5d1ea304b38f22fc7927ef16875b1ef82036886.tar.bz2 scummvm-rg350-c5d1ea304b38f22fc7927ef16875b1ef82036886.zip |
HDB: Unstubbing updateVideo()
Diffstat (limited to 'engines')
-rw-r--r-- | engines/hdb/gfx.cpp | 13 | ||||
-rw-r--r-- | engines/hdb/gfx.h | 4 | ||||
-rw-r--r-- | engines/hdb/hdb.h | 10 |
3 files changed, 18 insertions, 9 deletions
diff --git a/engines/hdb/gfx.cpp b/engines/hdb/gfx.cpp index 00fa48ba9c..19109c368c 100644 --- a/engines/hdb/gfx.cpp +++ b/engines/hdb/gfx.cpp @@ -203,9 +203,18 @@ void Gfx::updateVideo() { updateFade(); g_hdb->checkProgress(); - debug(9, "STUB: Gfx::updateVideo incomplete"); - warning("STUB: Blit the Backbuffer to the primary surface"); + if (!g_hdb->_progressGfx) + return; + + int left = kScreenWidth / 2 - g_hdb->_progressGfx->_width / 2; + + Common::Rect clip(g_hdb->_progressGfx->getSurface()->getBounds()); + clip.moveTo(left, kProgressY); + clip.clip(g_hdb->_gfx->_globalSurface.getBounds()); + if (!clip.isEmpty()) { + g_system->copyRectToScreen(g_hdb->_gfx->_globalSurface.getBasePtr(clip.left, clip.top), g_hdb->_gfx->_globalSurface.pitch, clip.left, clip.top, clip.width(), clip.height()); + } while (g_system->getMillis() - timer < 16) {}; } diff --git a/engines/hdb/gfx.h b/engines/hdb/gfx.h index 371174b113..36204c59f9 100644 --- a/engines/hdb/gfx.h +++ b/engines/hdb/gfx.h @@ -257,12 +257,12 @@ public: char *getName() { return _name; } -private: + Graphics::ManagedSurface *getSurface() { return &_surface; } +private: char _name[64]; Graphics::ManagedSurface _surface; - }; class Tile { diff --git a/engines/hdb/hdb.h b/engines/hdb/hdb.h index 739a00e3f1..b7f12a354c 100644 --- a/engines/hdb/hdb.h +++ b/engines/hdb/hdb.h @@ -287,6 +287,11 @@ public: bool _gameShutdown; Graphics::PixelFormat _format; + Picture *_progressGfx, *_progressMarkGfx; + Picture *_loadingScreenGfx, *_logoGfx; + bool _progressActive; + int _progressCurrent, _progressXOffset, _progressMax; + private: uint32 _timePlayed; @@ -305,12 +310,7 @@ private: // Misc Variables int _pauseFlag; - bool _cheating; - Picture *_progressGfx, *_progressMarkGfx; - Picture *_loadingScreenGfx, *_logoGfx; - bool _progressActive; - int _progressCurrent, _progressXOffset, _progressMax; char _currentMapname[64]; char _lastMapname[64]; |