ProtoTwin API
    Preparing search index...

    Class FramedCurve

    Immutable framed curve.

    Hierarchy (View Summary)

    Implements

    Index

    Constructors

    Accessors

    • get closed(): boolean

      Returns boolean

    • get length(): number

      Returns number

    Methods

    • Evaluates the frame at the specified distance.

      Parameters

      • s: number

        The distance.

      Returns Frame

      The frame.

    • Evaluates the normal to the framed curve at the specified distance.

      Parameters

      • s: number

        The distance.

      Returns Vec3

      The normal to the framed curve.

    • Parameters

      • s: number

      Returns number

    • Evaluates the point on the framed curve at the specified distance.

      Parameters

      • s: number

        The distance.

      Returns Vec3

      The point on the framed curve.

    • Calculates the distance for the specified point when projected onto the framed curve.

      Parameters

      Returns number

      The distance (arc-length) for the projected point.

    • Parameters

      • s: number
      • distances: number[]

      Returns number

    • Evaluates the tangent to the framed curve at the specified distance.

      Parameters

      • s: number

        The distance.

      Returns Vec3

      The tangent to the framed curve.

    • Creates a framed curve by discretizing the specified source curve. The orientation of the framed curve is constant along the curve.

      Parameters

      • curve: Curve

        The source curve.

      • sagitta: number

        The maximum sagitta, used to control the discretization.

      • maxPoints: number

        The maximum number of discrete points.

      • start: number
      • end: number
      • orientation: Quat

        The constant orientation at every point along the curve.

      • auxiliary: number[]

      Returns null | FramedCurve

      The generated framed curve, or null if the generation failed.

      This function will return null if the number of discrete points generated exceeds the specified maximum point count.

    • Creates a framed curve by discretizing the specified source curve. The orientation of the framed curve matches the orientation of the source curve at every discrete point.

      Parameters

      • curve: Curve

        The source curve.

      • sagitta: number

        The maximum sagitta, used to control the discretization.

      • maxPoints: number

        The maximum number of discrete points.

      • start: number
      • end: number

      Returns null | FramedCurve

      The generated framed curve, or null if the generation failed.

      This function will return null if the number of discrete points generated exceeds the specified maximum point count.

    • Parameters

      • curve: Curve
      • sagitta: number
      • maxPoints: number
      • start: number
      • end: number
      • startNormal: IVec3
      • rotationOffset: IQuat
      • auxiliary: number[]

      Returns null | FramedCurve