From 5111746911958bd35422e9614b0961a6b911ea06 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Sat, 3 Aug 2013 02:35:31 +0200 Subject: GRAPHICS: Take advantage of Surface::getPixels. --- graphics/fonts/ttf.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'graphics/fonts/ttf.cpp') diff --git a/graphics/fonts/ttf.cpp b/graphics/fonts/ttf.cpp index 2b1dca1eae..b9e9610d77 100644 --- a/graphics/fonts/ttf.cpp +++ b/graphics/fonts/ttf.cpp @@ -322,7 +322,7 @@ void TTFFont::drawChar(Surface *dst, byte chr, int x, int y, uint32 color) const int w = glyph.image.w; int h = glyph.image.h; - const uint8 *srcPos = (const uint8 *)glyph.image.getBasePtr(0, 0); + const uint8 *srcPos = (const uint8 *)glyph.image.getPixels(); // Make sure we are not drawing outside the screen bounds if (x < 0) { @@ -422,7 +422,7 @@ bool TTFFont::cacheGlyph(Glyph &glyph, FT_UInt &slot, uint chr) { srcPitch = -srcPitch; } - uint8 *dst = (uint8 *)glyph.image.getBasePtr(0, 0); + uint8 *dst = (uint8 *)glyph.image.getPixels(); memset(dst, 0, glyph.image.h * glyph.image.pitch); switch (bitmap.pixel_mode) { -- cgit v1.2.3