summaryrefslogtreecommitdiff
path: root/src/cairo-types-private.h
diff options
context:
space:
mode:
authorNicolaus L Helper <nlhepler@gmail.com>2010-06-17 08:56:30 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2010-06-17 09:06:13 +0100
commit7a023a62f7517ad0d54f4d59c99909fadcc05e82 (patch)
tree0598a5746ed67cbfea33a79c402efa2eb3e4060e /src/cairo-types-private.h
parent36b4b0631cc220d01c411b596a4eef839338cd7c (diff)
downloadcairo-7a023a62f7517ad0d54f4d59c99909fadcc05e82.tar.gz
ft,fc,xlib: LCD filtering patch.
This adds internal API to retrieve the LCD filtering parameters from fontconfig, or as set on the Screen, and feed them to FreeType when rendering the glyph. References: Bug 10301 - LCD filtering patch https://bugs.freedesktop.org/show_bug.cgi?id=10301 Tested-by: Brandon Wright <bearoso@gmail.com> Forward-ported-by: Robert Hooker <sarvatt@gmail.cm> ickle: The API is clearly not ready for public consumption, the enum are poorly named, however this stands by itself as enabling system wide properties.
Diffstat (limited to 'src/cairo-types-private.h')
-rw-r--r--src/cairo-types-private.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/src/cairo-types-private.h b/src/cairo-types-private.h
index 8b5a94b43..49fc7092a 100644
--- a/src/cairo-types-private.h
+++ b/src/cairo-types-private.h
@@ -129,9 +129,34 @@ struct _cairo_array {
cairo_bool_t is_snapshot;
};
+/**
+ * cairo_lcd_filter_t:
+ * @CAIRO_LCD_FILTER_DEFAULT: Use the default LCD filter for
+ * font backend and target device
+ * @CAIRO_LCD_FILTER_NONE: Do not perform LCD filtering
+ * @CAIRO_LCD_FILTER_INTRA_PIXEL: Intra-pixel filter
+ * @CAIRO_LCD_FILTER_FIR3: FIR filter with a 3x3 kernel
+ * @CAIRO_LCD_FILTER_FIR5: FIR filter with a 5x5 kernel
+ *
+ * The LCD filter specifies the low-pass filter applied to LCD-optimized
+ * bitmaps generated with an antialiasing mode of %CAIRO_ANTIALIAS_SUBPIXEL.
+ *
+ * Note: This API was temporarily made available in the public
+ * interface during the 1.7.x development series, but was made private
+ * before 1.8.
+ **/
+typedef enum _cairo_lcd_filter {
+ CAIRO_LCD_FILTER_DEFAULT,
+ CAIRO_LCD_FILTER_NONE,
+ CAIRO_LCD_FILTER_INTRA_PIXEL,
+ CAIRO_LCD_FILTER_FIR3,
+ CAIRO_LCD_FILTER_FIR5
+} cairo_lcd_filter_t;
+
struct _cairo_font_options {
cairo_antialias_t antialias;
cairo_subpixel_order_t subpixel_order;
+ cairo_lcd_filter_t lcd_filter;
cairo_hint_style_t hint_style;
cairo_hint_metrics_t hint_metrics;
};