Like flattenCubic but also appends, for each new flattened point, its
arc-length fraction t (relative to the polyline distance accumulated so
far inside this curve) to arcOut. Caller then post-processes the segment's
arcOut range by dividing each by the segment's total flattened arc length
to yield t ∈ (0, 1].
The returned values are cumulative distance from the segment start, not
normalized fractions. Two-pass design (accumulate, then divide) keeps the
recursive splitter simple — it doesn't need to know the total length up
front.
Like
flattenCubicbut also appends, for each new flattened point, its arc-length fractiont(relative to the polyline distance accumulated so far inside this curve) toarcOut. Caller then post-processes the segment'sarcOutrange by dividing each by the segment's total flattened arc length to yield t ∈ (0, 1].The returned values are cumulative distance from the segment start, not normalized fractions. Two-pass design (accumulate, then divide) keeps the recursive splitter simple — it doesn't need to know the total length up front.