aboutsummaryrefslogtreecommitdiff
path: root/engines/sword25/gfx/image/renderedimage.h
diff options
context:
space:
mode:
authorEugene Sandulenko2013-05-06 03:49:21 -0700
committerEugene Sandulenko2013-05-06 03:49:21 -0700
commit4a62d6c25a4994a72c59ca3b8f2913ead565a173 (patch)
tree63b8027b1f8d68eb66f9822f1a786c955ec14adf /engines/sword25/gfx/image/renderedimage.h
parentcc3f4a36b22ad894e30eaa3e840b9388d8bd104b (diff)
parent4fc57dac8fd6865494d21acfddeb69ab7fb1ad5c (diff)
downloadscummvm-rg350-4a62d6c25a4994a72c59ca3b8f2913ead565a173.tar.gz
scummvm-rg350-4a62d6c25a4994a72c59ca3b8f2913ead565a173.tar.bz2
scummvm-rg350-4a62d6c25a4994a72c59ca3b8f2913ead565a173.zip
Merge pull request #320 from johndoe123/sword25-gfx
SWORD25: Optimized graphics drawing
Diffstat (limited to 'engines/sword25/gfx/image/renderedimage.h')
-rw-r--r--engines/sword25/gfx/image/renderedimage.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/engines/sword25/gfx/image/renderedimage.h b/engines/sword25/gfx/image/renderedimage.h
index f92a5b39b4..a25b258592 100644
--- a/engines/sword25/gfx/image/renderedimage.h
+++ b/engines/sword25/gfx/image/renderedimage.h
@@ -75,7 +75,8 @@ public:
int flipping = Image::FLIP_NONE,
Common::Rect *pPartRect = NULL,
uint color = BS_ARGB(255, 255, 255, 255),
- int width = -1, int height = -1);
+ int width = -1, int height = -1,
+ RectangleList *updateRects = 0);
virtual bool fill(const Common::Rect *pFillRect, uint color);
virtual bool setContent(const byte *pixeldata, uint size, uint offset = 0, uint stride = 0);
void replaceContent(byte *pixeldata, int width, int height);
@@ -105,14 +106,19 @@ public:
static Graphics::Surface *scale(const Graphics::Surface &srcImage, int xSize, int ySize);
+ void setIsTransparent(bool isTransparent) { _isTransparent = isTransparent; }
+ virtual bool isSolid() const { return !_isTransparent; }
+
private:
byte *_data;
int _width;
int _height;
bool _doCleanup;
+ bool _isTransparent;
Graphics::Surface *_backSurface;
+ void checkForTransparency();
static int *scaleLine(int size, int srcSize);
};