react-three-nurbs
Version:
A React component library for NURBS (Non-Uniform Rational B-Spline) curves, surfaces, and solids in Three.js. Built with React Three Fiber, zero external NURBS dependencies — all math implemented from scratch. Boolean operations powered by OpenCASCADE WAS
16 lines (15 loc) • 641 B
TypeScript
/**
* Curve fitting and surface lofting algorithms.
* Implements Algorithm A9.1 from "The NURBS Book" (Piegl & Tiller).
*/
import type { CurveData, SurfaceData } from "./types";
/**
* Global curve interpolation through a set of points (Algorithm A9.1).
* Uses chord-length parameterization and averages for knot vector.
*/
export declare function globalCurveInterpolation(points: number[][], degree: number): CurveData;
/**
* Create a lofted surface through multiple curves.
* All curves are made compatible (same degree, same knots) first.
*/
export declare function loftSurface(curves: CurveData[], degreeV: number): SurfaceData;