From 6eafffaf57581f4e22405e7ae22c5d54555a285b Mon Sep 17 00:00:00 2001 From: Artem Pavlenko Date: Tue, 28 Nov 2017 11:23:13 +0100 Subject: [PATCH] check if FT_PIXEL_MODE_BGRA is defined (freetype < 2.5.0) (#3797) --- src/text/renderer.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/text/renderer.cpp b/src/text/renderer.cpp index a549d6c9d..e45077125 100644 --- a/src/text/renderer.cpp +++ b/src/text/renderer.cpp @@ -178,7 +178,9 @@ void agg_text_renderer::render(glyph_positions const& pos) if (!error) { FT_BitmapGlyph bit = reinterpret_cast(g); +#ifdef FT_PIXEL_MODE_BGRA if (bit->bitmap.pixel_mode != FT_PIXEL_MODE_BGRA) +#endif { composite_bitmap(pixmap_, &bit->bitmap,