diff options
author | Andrei Karas <akaras@inbox.ru> | 2012-10-08 19:48:26 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2012-10-08 19:48:26 +0300 |
commit | 196cc38da19b867eaa9419343dd6ecd8212af354 (patch) | |
tree | afb2d39f88c213702a339cae6fa08f8248b5c1af /src/maplayer.cpp | |
parent | a80a1c69f8a5f4db88ade16e3b9d53f7b648be47 (diff) | |
download | plus-196cc38da19b867eaa9419343dd6ecd8212af354.tar.gz plus-196cc38da19b867eaa9419343dd6ecd8212af354.tar.bz2 plus-196cc38da19b867eaa9419343dd6ecd8212af354.tar.xz plus-196cc38da19b867eaa9419343dd6ecd8212af354.zip |
Fix compilation errors and warnings in different modes.
Diffstat (limited to 'src/maplayer.cpp')
-rw-r--r-- | src/maplayer.cpp | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/src/maplayer.cpp b/src/maplayer.cpp index 654cb7997..fcecb17bd 100644 --- a/src/maplayer.cpp +++ b/src/maplayer.cpp @@ -147,6 +147,25 @@ void MapLayer::draw(Graphics *const graphics, } } +void MapLayer::drawSDL(Graphics *const graphics) +{ + MapRows::const_iterator rit = mTempRows.begin(); + const MapRows::const_iterator rit_end = mTempRows.end(); + while (rit != rit_end) + { + MepRowImages *const images = &(*rit)->images; + MepRowImages::const_iterator iit = images->begin(); + const MepRowImages::const_iterator iit_end = images->end(); + while (iit != iit_end) + { + graphics->drawTile(*iit); + ++ iit; + } + ++ rit; + } +} + +#ifdef USE_OPENGL void MapLayer::updateSDL(Graphics *const graphics, int startX, int startY, int endX, int endY, const int scrollX, const int scrollY, @@ -209,30 +228,11 @@ void MapLayer::updateSDL(Graphics *const graphics, int startX, int startY, } } -void MapLayer::drawSDL(Graphics *const graphics) -{ - MapRows::const_iterator rit = mTempRows.begin(); - const MapRows::const_iterator rit_end = mTempRows.end(); - while (rit != rit_end) - { - MepRowImages *const images = &(*rit)->images; - MepRowImages::const_iterator iit = images->begin(); - const MepRowImages::const_iterator iit_end = images->end(); - while (iit != iit_end) - { - graphics->drawTile(*iit); - ++ iit; - } - ++ rit; - } -} - void MapLayer::updateOGL(Graphics *const graphics, int startX, int startY, int endX, int endY, const int scrollX, const int scrollY, const int debugFlags) { -#ifdef USE_OPENGL delete_all(mTempRows); mTempRows.clear(); @@ -303,7 +303,6 @@ void MapLayer::updateOGL(Graphics *const graphics, int startX, int startY, } } } -#endif } void MapLayer::drawOGL(Graphics *const graphics) @@ -326,6 +325,7 @@ void MapLayer::drawOGL(Graphics *const graphics) } // logger->log("draws: %d", k); } +#endif void MapLayer::drawFringe(Graphics *const graphics, int startX, int startY, int endX, int endY, |