diff options
author | Nicola Mettifogo | 2007-11-22 21:51:33 +0000 |
---|---|---|
committer | Nicola Mettifogo | 2007-11-22 21:51:33 +0000 |
commit | 919c0a2833273d3ae92d0eb3635a479c34e1ced9 (patch) | |
tree | 66cdf8a6d46da4e6a57e7e64351ba43c6671b9cc /engines/parallaction/graphics.cpp | |
parent | f4946e64008ebebcbba340c7b0d51ad466219e85 (diff) | |
download | scummvm-rg350-919c0a2833273d3ae92d0eb3635a479c34e1ced9.tar.gz scummvm-rg350-919c0a2833273d3ae92d0eb3635a479c34e1ced9.tar.bz2 scummvm-rg350-919c0a2833273d3ae92d0eb3635a479c34e1ced9.zip |
* added adapter from Graphics::Surface to Frames
* changed all Disk routines to return Frames* instead of Graphics::Surface*
* changed displayItemComment to use new gfx routines
* merged code for Examine zones into displayComment
svn-id: r29615
Diffstat (limited to 'engines/parallaction/graphics.cpp')
-rw-r--r-- | engines/parallaction/graphics.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/engines/parallaction/graphics.cpp b/engines/parallaction/graphics.cpp index e40d954f10..41f818a8a8 100644 --- a/engines/parallaction/graphics.cpp +++ b/engines/parallaction/graphics.cpp @@ -565,14 +565,17 @@ void Gfx::backupDoorBackground(DoorData *data, int16 x, int16 y) { void Gfx::backupGetBackground(GetData *data, int16 x, int16 y) { - byte *t = (byte*)data->_cnv->pixels; + byte *t = (byte*)data->_cnv->getData(0); byte *s = (byte*)_buffers[kBitBack]->getBasePtr(x, y); byte *d = data->_backup; - uint pitch = _backgroundWidth - data->_cnv->w; + Common::Rect r; + data->_cnv->getRect(0, r); + + uint pitch = _backgroundWidth - r.width(); - for (uint16 i = 0; i < data->_cnv->h ; i++) { - for (uint16 j = 0; j < data->_cnv->w ; j++) { + for (uint16 i = 0; i < r.height(); i++) { + for (uint16 j = 0; j < r.width(); j++) { *d = (*t) ? *s : 0; d++; |