brepjs API Reference
    Preparing search index...

    Function sweep

    • Sweep a wire profile along a spine wire to create a 3D shape.

      Supports Frenet framing, auxiliary spine twist, scaling laws, contact detection, and configurable corner transition modes.

      Parameters

      • wire: Wire

        The profile wire to sweep.

      • spine: Wire

        The path wire to sweep along.

      • config: SweepOptions = {}

        Sweep configuration (frenet, transition mode, scaling law, etc.).

      • shellMode: boolean = false

        When true, return [shell, startWire, endWire] instead of a solid.

      Returns Result<Shape3D | [Shape3D, Wire, Wire]>

      Result containing either a solid or a [Shape3D, Wire, Wire] tuple in shell mode.

      In WASM, BRepOffsetAPI_MakePipeShell supports only a single Add_1 call per builder. Multi-profile sweeps will silently ignore additional profiles.

      extrude!genericSweep | genericSweep for the OOP API equivalent.