• Fredrik Söderquist's avatar
    Handle arc segments correctly for marker placement · 44953bde
    Fredrik Söderquist authored
    When producing Path objects, arcs are converted to conic segments, and
    when iterating those with Path::Apply(...) they are converted to
    quadratic beziers. So the arc semantics are lost when
    SVGMarkerDataBuilder gets the resulting segment. Thus it produces
    markers for each quadratic bezier, which is incorrect.
    
    Teach SVGMarkerDataBuilder to operate on the original path data too by
    accepting SVGPathByteStreams, and contort the arc segments into single
    (faux) beziers with matching properties (same start/end tangents). This
    allows reuse of the rest of the marker data builder machinery.
    Use the new code-path for the cases which can contain arc segments
    (<path> elements with 'd').
    
    Bug: 583097
    Change-Id: I20d772bb2ab67cd686160ab437d7d16fbc81e3c9
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1950999
    Commit-Queue: Fredrik Söderquist <fs@opera.com>
    Reviewed-by: default avatarStephen Chenney <schenney@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#722425}
    44953bde
TestExpectations 528 KB