commit | d19bb17782d09e7fe2f7ea85eabf7e649e6becc1 | [log] [tgz] |
---|---|---|
author | Ben Wagner <bungeman@google.com> | Wed May 13 10:44:49 2020 -0400 |
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | Mon May 18 20:18:07 2020 +0000 |
tree | 5bebc8e98a5c3bd45470deb5bc12e719e087527b | |
parent | 75cebbe5d3037cd8ebfce8379c629a7dd6fe787b [diff] |
Cache hb_face. Creating an hb_face can be quite expensive, cache them. This implementation is similar to the super simple caching strategy used by libtxt. It uses a simple global LRU cache from SkFontID to hb_hbface of size 100. Change-Id: I364a4548699cece50073e829a065c0a303245873 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/289442 Commit-Queue: Ben Wagner <bungeman@google.com> Reviewed-by: Mike Reed <reed@google.com>