[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [ft-devel] gamma correction demo images
From: |
Dave Arnold |
Subject: |
Re: [ft-devel] gamma correction demo images |
Date: |
Fri, 20 Nov 2015 19:11:57 +0000 |
Yes, the only difference in blending is that subpixel mode does it 3 times per
pixel.
The filter is color-balanced, but not normalized. Values above 0x100 will have
to be clamped and this non-linearity causes distortion and adds to color
fringing. Stem darkening is the better way to increase contrast.
________________________________________
From: address@hidden <address@hidden> on behalf of Nikolaus Waxweiler
<address@hidden>
Sent: Friday, November 20, 2015 10:08 AM
To: address@hidden
Subject: Re: [ft-devel] gamma correction demo images
> I did not work on subpixel rendering in FreeType, but I assume it is
> similar to what Adobe does. Here is a brief summary.
I'm currently writing up the documentation for ftautoh.h, do I
understand correctly that the steps for linear alpha blending and gamma
correction of gray and subpixel-rendered glyphs are exactly the same?
Meaning:
1. Take the foreground and background colors (e.g., in sRGB space) and
apply gamma to get them in a linear space.
2. Blend the two linear colors using the alpha value from the glyph's
coverage bitmap
3. Apply inverse gamma (e.g. 1.8) to the blended pixel and write it back
to the image.
> The density computed for each subpixel must be distributed equally to
> all color channels.
Werner,
http://freetype.org/freetype2/docs/reference/ft2-lcd_filtering.html
suggests [0x10, 0x50, 0x60, 0x50, 0x10] as a possible LCD filter to use
when doing LAB+GC. Is this correct and does what Dave suggests here? The
sum seems to go above 0x100? And if it is, would it make a good
candidate for a new FT_LCD_FILTER_EQUAL_WEIGHT that LAB+GC-enabled libs
can set?
_______________________________________________
Freetype-devel mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/freetype-devel
- Re: [ft-devel] gamma correction demo images, Nikolaus Waxweiler, 2015/11/04
- Re: [ft-devel] gamma correction demo images, Alexei Podtelezhnikov, 2015/11/04
- Re: [ft-devel] gamma correction demo images, Dave Arnold, 2015/11/04
- Re: [ft-devel] gamma correction demo images, Nikolaus Waxweiler, 2015/11/20
- Re: [ft-devel] gamma correction demo images,
Dave Arnold <=
- Re: [ft-devel] gamma correction demo images, Nikolaus Waxweiler, 2015/11/20
- Re: [ft-devel] gamma correction demo images, Alexei Podtelezhnikov, 2015/11/20
- Re: [ft-devel] gamma correction demo images, Nikolaus Waxweiler, 2015/11/22
- Re: [ft-devel] gamma correction demo images, Nikolaus Waxweiler, 2015/11/22
- Re: [ft-devel] gamma correction demo images, Alexei Podtelezhnikov, 2015/11/23
- Re: [ft-devel] gamma correction demo images, Werner LEMBERG, 2015/11/23
- Re: [ft-devel] gamma correction demo images, Dave Arnold, 2015/11/24
- Re: [ft-devel] gamma correction demo images, Werner LEMBERG, 2015/11/25
- Re: [ft-devel] gamma correction demo images, Alexei Podtelezhnikov, 2015/11/25
- Re: [ft-devel] gamma correction demo images, Nikolaus Waxweiler, 2015/11/25