diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-08-24 16:12:12 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-08-24 21:08:17 +0300 |
commit | 889ea19ddd5b4240375793d5030a04ed4642ec66 (patch) | |
tree | d1694423834f8d4be86383ad28702845dfdadf2f /src/sdlgraphics.cpp | |
parent | b70bbf075a20524e6c1859fb18db0865c65182ca (diff) | |
download | manaplus-889ea19ddd5b4240375793d5030a04ed4642ec66.tar.gz manaplus-889ea19ddd5b4240375793d5030a04ed4642ec66.tar.bz2 manaplus-889ea19ddd5b4240375793d5030a04ed4642ec66.tar.xz manaplus-889ea19ddd5b4240375793d5030a04ed4642ec66.zip |
extract surface draw into surfacegraphics class.
Diffstat (limited to 'src/sdlgraphics.cpp')
-rw-r--r-- | src/sdlgraphics.cpp | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/src/sdlgraphics.cpp b/src/sdlgraphics.cpp index a77076c26..f62bca7c8 100644 --- a/src/sdlgraphics.cpp +++ b/src/sdlgraphics.cpp @@ -47,7 +47,6 @@ static unsigned int *cB = nullptr; SDLGraphics::SDLGraphics() : Graphics(), - mBlitMode(BLIT_NORMAL), mOldPixel(0), mOldAlpha(0) { @@ -126,16 +125,8 @@ bool SDLGraphics::drawImage2(const Image *const image, int srcX, int srcY, srcRect.w = static_cast<uint16_t>(width); srcRect.h = static_cast<uint16_t>(height); - if (mBlitMode == BLIT_NORMAL) - { - return !(SDL_BlitSurface(image->mSDLSurface, &srcRect, - mWindow, &dstRect) < 0); - } - else - { - return !(SDL_gfxBlitRGBA(image->mSDLSurface, &srcRect, - mWindow, &dstRect) < 0); - } + return !(SDL_BlitSurface(image->mSDLSurface, &srcRect, + mWindow, &dstRect) < 0); } void SDLGraphics::drawImagePattern(const Image *const image, |