sweepLineStringToFacets MethodStatic

Sweep the line string to intersections with a mesh and return collected line segments.

  • Facets are ASSUMED to be convex and planar, and not overlap in the sweep direction.

sweepLineStringToFacets(points: IndexedXYZCollection, source: PolyfaceVisitor | Polyface, options?: SweepLineStringToFacetsOptions): LinearCurvePrimitive[]

Parameter Type Description
points IndexedXYZCollection the linestring to drape onto the mesh.
source PolyfaceVisitor | Polyface target facet set. For best results, facets should be convex and planar.
options SweepLineStringToFacetsOptions input, filtering, search, and output options.
* If undefined, the default sweep direction is the positive z-axis, and chains are assembled and returned.
* For faster vertical sweep, a pre-computed range tree can be supplied in options.searcher.
* For faster non-vertical sweep, first transform inputs with the inverse of the transform
T = Transform.createRigidFromOriginAndVector(undefined, options.vectorToEye), construct the searcher on these
local facets, call sweepLineStringToFacets/XY with these local inputs (and default sweep direction), and lastly,
transform the returned draped linework back to world coordinates with T.

Returns - LinearCurvePrimitive[]

Defined in

Last Updated: 27 June, 2025