Cache FreeType glyph masks may need current color.

If a FreeType font has glyphs which may need the current color this is
non-changing information, so calculate it once at and cache it. This
information is needed on evert time a scaler context rec is created and
adding the overhead of looking through the font data (especially the
extra indirections from a ttc) can take a bit of time.

Bug: b/206120675
Change-Id: I92f2083a6bbd673fc148347c4e04ed81a441c3ba
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/474059
Reviewed-by: Derek Sollenberger <djsollen@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
2 files changed