diff options
author | Andrei Karas <akaras@inbox.ru> | 2012-06-09 22:46:34 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2012-06-09 23:50:09 +0300 |
commit | ff11053f5f638749c3564c464dc41ebc474b4897 (patch) | |
tree | 8cf7ed8485528c7498612199c7ca56a6fd84f5e5 /src/resources/ambientlayer.cpp | |
parent | b2c1c301b1e39fbbbb5bde3d4d55d14a9873b51f (diff) | |
download | manaplus-ff11053f5f638749c3564c464dc41ebc474b4897.tar.gz manaplus-ff11053f5f638749c3564c464dc41ebc474b4897.tar.bz2 manaplus-ff11053f5f638749c3564c464dc41ebc474b4897.tar.xz manaplus-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/resources/ambientlayer.cpp')
-rw-r--r-- | src/resources/ambientlayer.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/resources/ambientlayer.cpp b/src/resources/ambientlayer.cpp index b5640904c..f2eaeab81 100644 --- a/src/resources/ambientlayer.cpp +++ b/src/resources/ambientlayer.cpp @@ -24,6 +24,7 @@ #include "graphics.h" #include "resources/image.h" +#include "resources/imagehelper.h" #include "resources/resourcemanager.h" #include "debug.h" @@ -38,7 +39,7 @@ AmbientLayer::AmbientLayer(Image *img, float parallax, if (!mImage) return; - if (keepRatio && !mImage->useOpenGL() + if (keepRatio && !ImageHelper::useOpenGL() /*&& defaultScreenWidth != 0 && defaultScreenHeight != 0*/ && mainGraphics->mWidth != defaultScreenWidth @@ -105,7 +106,7 @@ void AmbientLayer::draw(Graphics *graphics, int x, int y) if (!mImage) return; - if (!mImage->useOpenGL() || !mKeepRatio) + if (!ImageHelper::useOpenGL() || !mKeepRatio) { graphics->drawImagePattern(mImage, static_cast<int>(-mPosX), static_cast<int>(-mPosY), x + static_cast<int>(mPosX), |