1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-07-17 01:32:21 +02:00

Replace SDL_Point and SDL_Rect with Gfx::Point and Gfx::Rect,

synchronization with trunk.
This commit is contained in:
paracelsus
2013-03-13 22:01:05 +00:00
parent 058d730d56
commit 06e2e6ac10
58 changed files with 1969 additions and 819 deletions

View File

@ -648,7 +648,7 @@ void SDLImage::draw(SDL_Surface *where, int posX, int posY, Rect *src, ui8 rotat
Rect destRect(posX, posY, surf->w, surf->h);
destRect += sourceRect.topLeft();
sourceRect -= margins;
CSDL_Ext::blitSurface(surf, &sourceRect, where, &destRect);
//* CSDL_Ext::blitSurface(surf, &sourceRect, where, &destRect);
}
void SDLImage::playerColored(PlayerColor player)
@ -998,7 +998,7 @@ void CAnimation::init(CDefFile * file)
BOOST_FOREACH(const JsonNode &group, config["sequences"].Vector())
{
size_t groupID = group["group"].Float();//TODO: string-to-value conversion("moving" -> MOVING)
size_t groupID = group["group"].asInteger();//TODO: string-to-value conversion("moving" -> MOVING)
source[groupID].clear();
BOOST_FOREACH(const JsonNode &frame, group["frames"].Vector())
@ -1011,8 +1011,8 @@ void CAnimation::init(CDefFile * file)
BOOST_FOREACH(const JsonNode &node, config["images"].Vector())
{
size_t group = node["group"].Float();
size_t frame = node["frame"].Float();
size_t group = node["group"].asInteger();
size_t frame = node["frame"].asInteger();
if (source[group].size() <= frame)
source[group].resize(frame+1);