Skip to main content

Sweep

Extends BooleanOperation

Inherited from BooleanOperation

add()​

add(): this

Additive boolean operation — fuses the result with all intersecting scene objects. Use .scope() to target specific objects.


'new'()​

'new'(): this

No boolean operation — keeps the result as a standalone shape, separate from all other scene objects.


remove()​

remove(): this

Subtractive boolean operation — cuts the result from all intersecting scene objects. Use .scope() to target specific objects.


scope()​

scope(...objects: SceneObject[]): this

Narrows the boolean operation scope to specific target objects. Must be chained after .add() or .remove().

ParameterTypeDescription
...objectsSceneObject[]The target objects to operate on. (optional)
Inherited from SceneObject

name()​

name(value: string): this

Sets a custom display name for this object, overriding the default type-based name.

ParameterTypeDescription
valuestringThe display name to assign.

Methods​

startFaces()​

startFaces(...args: (number | FaceFilterBuilder)[]): ISelection

Selects faces at the start (profile plane) of the sweep.

Returns: ISelection

ParameterTypeDescription
...args(number | FaceFilterBuilder)[]Numeric indices or FaceFilterBuilder instances to filter the selection. (optional)

endFaces()​

endFaces(...args: (number | FaceFilterBuilder)[]): ISelection

Selects faces at the end of the sweep path.

Returns: ISelection

ParameterTypeDescription
...args(number | FaceFilterBuilder)[]Numeric indices or FaceFilterBuilder instances to filter the selection. (optional)

sideFaces()​

sideFaces(...args: (number | FaceFilterBuilder)[]): ISelection

Selects the lateral faces generated by sweeping the profile along the path.

Returns: ISelection

ParameterTypeDescription
...args(number | FaceFilterBuilder)[]Numeric indices or FaceFilterBuilder instances to filter the selection. (optional)

startEdges()​

startEdges(...args: (number | EdgeFilterBuilder)[]): ISelection

Selects edges on the start faces of the sweep.

Returns: ISelection

ParameterTypeDescription
...args(number | EdgeFilterBuilder)[]Numeric indices or EdgeFilterBuilder instances to filter the selection. (optional)

endEdges()​

endEdges(...args: (number | EdgeFilterBuilder)[]): ISelection

Selects edges on the end faces of the sweep.

Returns: ISelection

ParameterTypeDescription
...args(number | EdgeFilterBuilder)[]Numeric indices or EdgeFilterBuilder instances to filter the selection. (optional)

sideEdges()​

sideEdges(...args: (number | EdgeFilterBuilder)[]): ISelection

Selects edges on the side faces, excluding edges shared with start/end faces.

Returns: ISelection

ParameterTypeDescription
...args(number | EdgeFilterBuilder)[]Numeric indices or EdgeFilterBuilder instances to filter the selection. (optional)

internalFaces()​

internalFaces(...args: (number | FaceFilterBuilder)[]): ISelection

Selects faces created inside the solid during the sweep (e.g., from holes).

Returns: ISelection

ParameterTypeDescription
...args(number | FaceFilterBuilder)[]Numeric indices or FaceFilterBuilder instances to filter the selection. (optional)

internalEdges()​

internalEdges(...args: (number | EdgeFilterBuilder)[]): ISelection

Selects edges bounding the internal geometry created during the sweep.

Returns: ISelection

ParameterTypeDescription
...args(number | EdgeFilterBuilder)[]Numeric indices or EdgeFilterBuilder instances to filter the selection. (optional)

draft()​

draft(value: NumberParam | [NumberParam, NumberParam]): this

Applies a draft (taper) angle to the sweep walls.

ParameterTypeDescription
valueNumberParam | [NumberParam, NumberParam]A single angle for uniform draft, or a [start, end] tuple for asymmetric draft.

endOffset()​

endOffset(value: NumberParam): this

Offsets the end face by a specified distance along the sweep direction.

ParameterTypeDescription
valueNumberParamThe offset distance.

extend()​

extend(side: SweepSide, amount: NumberParam): this

Extends the swept solid beyond the path at the given end by amount, continuing straight along the path's tangent direction there. Chain twice to extend both ends, e.g. .extend('start', 10).extend('end', 5).

ParameterTypeDescription
sideSweepSideWhich end of the path to extend: 'start' or 'end'.
amountNumberParamDistance to extend, in mm (positive; non-positive is a no-op).

drill()​

drill(value?: boolean): this

Enables or disables drill mode.

ParameterTypeDescription
valuebooleantrue to enable (default), false to disable. (optional)

region()​

region(...names: string[]): this

Restricts the sweep to particular regions of the profile sketch, by the names their region() declarations gave them. See IExtrude.region.

ParameterTypeDescription
...namesstring[]Names of regions the sketch declares. (optional)

thin()​

thin(offset: NumberParam): this

Enables thin sweep mode — offsets the profile edges to create a thin-walled swept shell instead of sweeping filled faces. Positive values offset outward, negative values offset inward.

ParameterTypeDescription
offsetNumberParamThe wall offset distance. Positive = outward, negative = inward.

thin()​

thin(offset1: NumberParam, offset2: NumberParam): this

Enables thin sweep mode with two offset directions. The two offsets must go in opposite directions. If both have the same sign, the second offset is automatically flipped.

ParameterTypeDescription
offset1NumberParamThe first wall offset distance. Positive = outward, negative = inward.
offset2NumberParamThe second wall offset distance, in the opposite direction of offset1.

capFaces()​

capFaces(...args: (number | FaceFilterBuilder)[]): ISelection

Selects the cap faces at the open ends of a thin-walled sweep from an open profile. These are the small faces connecting the inner and outer walls at the profile endpoints.

Returns: ISelection

ParameterTypeDescription
...args(number | FaceFilterBuilder)[]Numeric indices or FaceFilterBuilder instances to filter the selection. (optional)

capEdges()​

capEdges(...args: (number | EdgeFilterBuilder)[]): ISelection

Selects edges on the cap faces of a thin-walled sweep from an open profile.

Returns: ISelection

ParameterTypeDescription
...args(number | EdgeFilterBuilder)[]Numeric indices or EdgeFilterBuilder instances to filter the selection. (optional)