summaryrefslogtreecommitdiff
path: root/src/resources/image.h
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-07-07 02:12:24 +0300
committerAndrei Karas <akaras@inbox.ru>2011-07-07 03:17:16 +0300
commit7d151c8fc05cd7feaf1e1cee33fd8289208fa18d (patch)
treecc246201d9aafb94087efbe85cd13b4b18eacaaf /src/resources/image.h
parent95c8a3c0b4d2f0d39c81a6671452e1aa34a626f9 (diff)
downloadplus-7d151c8fc05cd7feaf1e1cee33fd8289208fa18d.tar.gz
plus-7d151c8fc05cd7feaf1e1cee33fd8289208fa18d.tar.bz2
plus-7d151c8fc05cd7feaf1e1cee33fd8289208fa18d.tar.xz
plus-7d151c8fc05cd7feaf1e1cee33fd8289208fa18d.zip
Add map reduce feature for software drawing.
Now invisible tiles will be removed if this mode enabled.
Diffstat (limited to 'src/resources/image.h')
-rw-r--r--src/resources/image.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/resources/image.h b/src/resources/image.h
index 72b85cc1e..ee341af75 100644
--- a/src/resources/image.h
+++ b/src/resources/image.h
@@ -208,6 +208,15 @@ class Image : public Resource
int getTextureHeight() const
{ return mTexHeight; }
+ bool isHasAlphaChannel()
+ { return mHasAlphaChannel; }
+
+ bool isAlphaVisible()
+ { return mIsAlphaVisible; }
+
+ void setAlphaVisible(bool b)
+ { mIsAlphaVisible = b; }
+
static int getTextureType()
{ return mTextureType; }
@@ -247,6 +256,7 @@ class Image : public Resource
std::map<float, SDL_Surface*> mAlphaCache;
bool mUseAlphaCache;
+ bool mIsAlphaVisible;
static bool mEnableAlphaCache;
static bool mEnableAlpha;
@@ -305,6 +315,8 @@ class SubImage : public Image
*/
Image *getSubImage(int x, int y, int width, int height);
+ SDL_Rect mInternalBounds;
+
private:
Image *mParent;
};