This is an automated email from the git hooks/post-receive script. thansen pushed a commit to branch master in repository aseprite.
commit fb10cf1d365290d6703a37a305b6c7e6bb5e980f Author: David Capello <[email protected]> Date: Tue Mar 15 16:34:41 2016 -0300 Simplify code in generic_surface.h for gcc/clang --- src/she/common/generic_surface.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/she/common/generic_surface.h b/src/she/common/generic_surface.h index 051e7a6..520353a 100644 --- a/src/she/common/generic_surface.h +++ b/src/she/common/generic_surface.h @@ -57,8 +57,8 @@ public: void drawColoredRgbaSurface(const Surface* src, gfx::Color fg, gfx::Color bg, const gfx::Clip& clipbase) override { gfx::Clip clip(clipbase); - if (!clip.clip(static_cast<Base*>(this)->width(), - static_cast<Base*>(this)->height(), + if (!clip.clip(this->width(), + this->height(), src->width(), src->height())) return; @@ -73,7 +73,7 @@ public: clip.src.x, clip.src.y+v); for (int u=0; u<clip.size.w; ++u) { - gfx::Color dstColor = static_cast<Base*>(this)->getPixel(clip.dst.x+u, clip.dst.y+v); + gfx::Color dstColor = this->getPixel(clip.dst.x+u, clip.dst.y+v); if (gfx::geta(bg) > 0) dstColor = blend(dstColor, bg); @@ -85,7 +85,7 @@ public: dstColor = blend(dstColor, src); } - static_cast<Base*>(this)->putPixel(dstColor, clip.dst.x+u, clip.dst.y+v); + this->putPixel(dstColor, clip.dst.x+u, clip.dst.y+v); ++ptr; } } @@ -106,7 +106,7 @@ public: if (!charBounds.isEmpty()) { Surface* sheet = ssFont->getSurfaceSheet(); SurfaceLock lock(sheet); - static_cast<Base*>(this)->drawColoredRgbaSurface(sheet, fg, bg, gfx::Clip(x, y, charBounds)); + this->drawColoredRgbaSurface(sheet, fg, bg, gfx::Clip(x, y, charBounds)); } break; } @@ -141,10 +141,10 @@ public: int fg_alpha = gfx::geta(fg); gfx::Rect bounds = ttFont->face().calcTextBounds(str); - gfx::Rect clipBounds = static_cast<Base*>(this)->getClipBounds(); + gfx::Rect clipBounds = this->getClipBounds(); she::SurfaceFormatData fd; - static_cast<Base*>(this)->getFormat(&fd); + this->getFormat(&fd); ttFont->face().forEachGlyph( str, @@ -167,7 +167,7 @@ public: + (v+clippedRows)*glyph.bitmap->pitch; int dst_x = dstBounds.x; uint32_t* dst_address = - (uint32_t*)static_cast<Base*>(this)->getData(dst_x, dst_y); + (uint32_t*)this->getData(dst_x, dst_y); // Skip first clipped pixels for (int u=0; u<dstBounds.x-origDstBounds.x; ++u) { -- Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/aseprite.git _______________________________________________ Pkg-games-commits mailing list [email protected] http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-games-commits

