commit 3810f114cc1d5da016e18bdf4fa4b4148fef5742 Author: Behdad Esfahbod Date: Fri Jan 23 11:44:26 2015 -0800 Fix breakage caused by 8dc863587440d0a1d2eec2a7973a8eda99d2767d As reported on ft-devel. diff --git a/src/raster/ftraster.c b/src/raster/ftraster.c index 65ba454..23aa53c 100644 --- a/src/raster/ftraster.c +++ b/src/raster/ftraster.c @@ -3124,6 +3124,9 @@ worker->buff = buffer; worker->sizeBuff = (&buffer)[1]; /* Points to right after buffer. */ + if ( params->flags & FT_RASTER_FLAG_AA ) + return FT_THROW( Unsupported ); + return Render_Glyph( RAS_VAR ); } diff --git a/src/raster/ftrend1.c b/src/raster/ftrend1.c index dc03b34..e13d47c 100644 --- a/src/raster/ftrend1.c +++ b/src/raster/ftrend1.c @@ -187,20 +187,8 @@ slot->internal->flags &= ~FT_GLYPH_OWN_BITMAP; } - /* allocate new one, depends on pixel format */ - if ( !( mode & FT_RENDER_MODE_MONO ) ) - { - /* we pad to 32 bits, only for backwards compatibility with FT 1.x */ - pitch = FT_PAD_CEIL( width, 4 ); - bitmap->pixel_mode = FT_PIXEL_MODE_GRAY; - bitmap->num_grays = 256; - } - else - { - pitch = ( ( width + 15 ) >> 4 ) << 1; - bitmap->pixel_mode = FT_PIXEL_MODE_MONO; - } - + pitch = ( ( width + 15 ) >> 4 ) << 1; + bitmap->pixel_mode = FT_PIXEL_MODE_MONO; bitmap->width = width; bitmap->rows = height; bitmap->pitch = pitch; @@ -218,9 +206,6 @@ params.source = outline; params.flags = 0; - if ( bitmap->pixel_mode == FT_PIXEL_MODE_GRAY ) - params.flags |= FT_RASTER_FLAG_AA; - /* render outline into the bitmap */ error = render->raster_render( render->raster, ¶ms );