summaryrefslogtreecommitdiff
path: root/src/compoundsprite.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-06-09 22:46:34 +0300
committerAndrei Karas <akaras@inbox.ru>2012-06-09 23:50:09 +0300
commitff11053f5f638749c3564c464dc41ebc474b4897 (patch)
tree8cf7ed8485528c7498612199c7ca56a6fd84f5e5 /src/compoundsprite.cpp
parentb2c1c301b1e39fbbbb5bde3d4d55d14a9873b51f (diff)
downloadplus-ff11053f5f638749c3564c464dc41ebc474b4897.tar.gz
plus-ff11053f5f638749c3564c464dc41ebc474b4897.tar.bz2
plus-ff11053f5f638749c3564c464dc41ebc474b4897.tar.xz
plus-ff11053f5f638749c3564c464dc41ebc474b4897.zip
Move static methods from Image class to ImageHelper class.
Remove SDL merge method. It was very slow and unused.
Diffstat (limited to 'src/compoundsprite.cpp')
-rw-r--r--src/compoundsprite.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/compoundsprite.cpp b/src/compoundsprite.cpp
index f4890fe2b..41a53467e 100644
--- a/src/compoundsprite.cpp
+++ b/src/compoundsprite.cpp
@@ -33,6 +33,7 @@
#include "map.h"
#include "resources/image.h"
+#include "resources/imagehelper.h"
#include "utils/dtor.h"
@@ -395,12 +396,12 @@ void CompoundSprite::redraw() const
delete mImage;
delete mAlphaImage;
- mImage = Image::load(surface);
+ mImage = ImageHelper::load(surface);
SDL_FreeSurface(surface);
- if (Image::mEnableAlpha)
+ if (ImageHelper::mEnableAlpha)
{
- mAlphaImage = Image::load(surfaceA);
+ mAlphaImage = ImageHelper::load(surfaceA);
SDL_FreeSurface(surfaceA);
}
else
@@ -414,7 +415,7 @@ void CompoundSprite::setAlpha(float alpha)
if (alpha != mAlpha)
{
#ifdef USE_OPENGL
- if (mEnableAlphaFix && Image::mUseOpenGL == 0 && size() > 3)
+ if (mEnableAlphaFix && ImageHelper::mUseOpenGL == 0 && size() > 3)
#else
if (mEnableAlphaFix && size() > 3)
#endif
@@ -433,7 +434,7 @@ void CompoundSprite::setAlpha(float alpha)
void CompoundSprite::updateImages() const
{
#ifdef USE_OPENGL
- if (Image::mUseOpenGL)
+ if (ImageHelper::mUseOpenGL)
return;
#endif