Skip to content

Instantly share code, notes, and snippets.

@drott
Created January 15, 2021 10:10
Show Gist options
  • Save drott/c2f6cf14d44416bc3a35733bd63f1e9e to your computer and use it in GitHub Desktop.
Save drott/c2f6cf14d44416bc3a35733bd63f1e9e to your computer and use it in GitHub Desktop.
CHANGES entry for COLRv1
- New API was added for surfacing properties of COLRv1 color
fonts. COLRv1 color fonts are a new proposed addition to OFF and
OpenType. Specification work currently happens in
https://github.com/googlefonts/colr-gradients-spec/. COLRv1 is
expected to be merged to OpenType and the ISO standardisation
process for adding COLRv1 as an amendment to OFF is underway.
COLRv1 tables are mapped to the a specific subtype of the
FT_COLR_Paint union. As COLRv1 fonts store drawing information in
a graph, often a FT_OpaquePaint type is used to represent a
particular location in the COLRv1 table.
FT_Get_Color_Glyph_Paint
Retrieve the root paint for a given glyph id.
FT_Get_Paint_Layers
Accesses the layers of a PaintColrLayers table.
FT_Get_Colorline_Stops
Retrieve the stops on a color line for
a color stop iterator retrieved from a paint.
FT_Get_Paint
Dereferences an FT_OpaquePaint and retrieves the
corresponding FT_COLR_Paint object which contains
deatils on how to draw the respective COLRv1 Paint table.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment