computeAndAttachRecursiveStrokeCounts Method

Attach StrokeCountMap structure to this primitive (and recursively to any children)

  • Base class implementation (here) gets the simple count from computeStrokeCountForOptions and attaches it.
  • LineString3d, arc3d, BezierCurve3d, BezierCurve3dH accept that default.
  • Subdivided primitives (linestring, bspline curve) implement themselves and attach a StrokeCountMap containing the total count, and also containing an array of StrokeCountMap per component.
  • For CurvePrimitiveWithDistanceIndex, the top level gets (only) a total count, and each child gets its own StrokeCountMap with appropriate structure.

computeAndAttachRecursiveStrokeCounts(options?: StrokeOptions, parentMap?: StrokeCountMap): void

@returns sum of a0+this.curveLength(), for use as a0 of successor in chain.

Parameter Type Description
options StrokeOptions StrokeOptions that determine count
parentMap StrokeCountMap  

Returns - void

sum of a0+this.curveLength(), for use as a0 of successor in chain.

Defined in

Last Updated: 14 November, 2024