A NURBS curve implementation that can be used by other curve classes

Constructors

  • Parameters

    • degree: number
    • knots: number[]
    • controlPoints: AcGeVector3dLike[]
    • Optionalweights: number[]

    Returns AcGeNurbsCurve

Methods

  • Get the degree of the NURBS curve

    Returns number

  • Get the valid parameter range for this curve

    Returns { end: number; start: number }

  • Get points along the curve

    Parameters

    • divisions: number

      Number of divisions to create

    Returns number[][]

    Array of points along the curve

  • Check if the curve is closed by comparing start and end points

    Parameters

    • Optionaltolerance: number

    Returns boolean

  • Get the knot vector

    Returns number[]

  • Calculate curve length using numerical integration

    Returns number

  • Calculate a point on the curve at parameter u

    Parameters

    • u: number

    Returns number[]

  • Get the weights

    Returns number[]

  • Create a NURBS curve from control points and knots

    Parameters

    • degree: number
    • knots: number[]
    • controlPoints: AcGeVector3dLike[]
    • Optionalweights: number[]

    Returns AcGeNurbsCurve