How consciousnesscraft/nurbs-curve works
Project type and purpose
• This is a desktop C++ visualization tool (an open-source graphics demo) that computes and renders a Non-Uniform Rational B-Spline (NURBS) curve.
• It reads control points, knot vectors, and weights, computes the curve geometry (plus Frenet frames, osculating circles, curvature radius, balayage surface), and displays everything in an interactive OpenGL window.
File structure
• Top-level files only:
• Makefile – build script invoking g++/clang++ and linking graphics libraries
• main.cpp – monolithic source file containing:
· Core NURBS computation routines (basis functions, curve evaluation)
· Data model for control points, weights, knot vectors
· Input/event handling (keyboard controls: v, b, +, –, n, c)
· View-mode toggles and state machine
README for additional insights
• Dependencies: C++ compiler, OpenGL (plus a windowing toolkit like GLUT/GLFW), Make
Diagramming recommendations
– Group all internal modules in an “NURBS-CURVE App” container
– Position the build system off to the side, feeding into the App container
Essential elements to capture
– Clear module boundaries and responsibilities