DescriptionRemove GlyphBuffer
After dropping the simple shaper, GlyphBuffer is just an intermediate/temporary data structure
we create of the fly at paint time in order to convert the shape results to SkTextBlobs:
ShapeResults -> GlyphBuffer -> GlyphBufferBloberizer -> SkTextBlobs
This CL introduces a ShapeResultBloberizer, and removes the GlyphBuffer intermediate:
ShapeResults -> ShapeResultBloberizer -> SkTextBlobs
Shape results are fed to a ShapeResultBloberizer one glyph at a time, and are greedily combined
into SkTextBlobs:
* glyphs sharing the same SimpleFontData are merged into the same run
* runs sharing the same rotation are merged into the same blob
A detail worth mentioning: while previously vertical text required an additional pass over offsets
to perform verticalBaselineXOffset adjustments, the new approach applies the transformation on the
fly, as the glyphs are appended.
Refactor only, no functional changes expected.
BUG=574136
Review-Url: https://codereview.chromium.org/2714413003
Cr-Commit-Position: refs/heads/master@{#459229}
Committed: https://chromium.googlesource.com/chromium/src/+/123744c5850b84cf7f3ef9228b6d64a281732443
Patch Set 1 #Patch Set 2 : rebase #Patch Set 3 : ShapeResultBloberizer::startRun() #Patch Set 4 : rebase #Patch Set 5 : rebase #Patch Set 6 : cleanup #Patch Set 7 : fix DCHECK #Patch Set 8 : inline startRun #Patch Set 9 : experimentally remove startRun #Patch Set 10 : explicit shaping, unit test #Patch Set 11 : updated unit test #Patch Set 12 : fix unintended rebase change #Patch Set 13 : format #
Total comments: 2
Messages
Total messages: 53 (47 generated)
|