Clip FreeType glyph bitmap to mask.
Skia has for some time assumed that when using FT_Render_Glyph with one
of the LCD render modes that one extra pixel would be applied to each
side of the resulting bitmap. FreieType has changed to make this more
conservative when possible, so the pre-allocated SkMask and the generated
FT_Bitmap may no longer agree on the size and origin.
This change ensures the SkMask and FT_Bitmap are the same size and their
origins align. This is not an ideal long term fix, but is both simple and
localized for easy and quick back-porting, should that become necessary.
Reviewed-by: Herb Derby <firstname.lastname@example.org>
Commit-Queue: Ben Wagner <email@example.com>
Reviewed-by: Ben Wagner <firstname.lastname@example.org>
1 file changed