NurbsSharp 0.1.0
See the version list below for details.
dotnet add package NurbsSharp --version 0.1.0
NuGet\Install-Package NurbsSharp -Version 0.1.0
<PackageReference Include="NurbsSharp" Version="0.1.0" />
<PackageVersion Include="NurbsSharp" Version="0.1.0" />
<PackageReference Include="NurbsSharp" />
paket add NurbsSharp --version 0.1.0
#r "nuget: NurbsSharp, 0.1.0"
#:package NurbsSharp@0.1.0
#addin nuget:?package=NurbsSharp&version=0.1.0
#tool nuget:?package=NurbsSharp&version=0.1.0
NURBS Sharp
NURBS Sharp is a small, dependency-free NURBS (Non-Uniform Rational B-Spline) library for .NET. It provides data structures, evaluators, topology operators, I/O and tessellation utilities implemented using only the .NET standard library.
Table of Contents
- Features
- Installation
- Quick Start
- Examples
- Documentation
- Development
- Contributing
- Code of Conduct
- License
Features
- Generation and evaluation of NURBS curves and surfaces
- Topology operators: degree, knot insertion/removal, join/split
- IO helpers: simple OBJ/STL export for ONLY Mesh, IGES import / export for ONLY NURBS
- Tessellation utilities for curves and surfaces
- Targets: .NET 8 and .NET Standard 2.1
Installation
Install via NuGet:
dotnet add package NurbsSharp
Or add the package reference to your project file.
Quick Start
Basic usage (C#):
using NurbsSharp.Core;
using NurbsSharp.Geometry;
using NurbsSharp.Tesselation;
using NurbsSharp.IO;
// Create a NURBS surface and evaluate a point
int degreeU = 3, degreeV = 3;
var knotsU = new double[] {0,0,0,0,1,1,1,1};
var knotsV = new double[] {0,0,0,0,1,1,1,1};
var kvU = new KnotVector(knotsU);
var kvV = new KnotVector(knotsV);
// Build control points (u x v grid)
ControlPoint[][] controlPoints = new ControlPoint[4][];
controlPoints[0] = new ControlPoint[] {
new ControlPoint(0.0, 0.0, 0.0, 1),
new ControlPoint(1.0, 0.0, 1.0, 1),
new ControlPoint(2.0, 0.0, 3.0, 1),
new ControlPoint(3.0, 0.0, 3.0, 1)
};
// ... Create Control Points ...
var surface = new NurbsSurface(degreeU, degreeV, kvU, kvV, controlPoints);
var point = surface.GetPos(0.5, 0.5);
Console.WriteLine(point);
Examples
tessellate a surface and export to STL:
int divideN = 20;
var mesh = SurfaceTessellator.Tessellate(surface, divideN, divideN);
using (var fs = new FileStream("test_output.stl", FileMode.Create, FileAccess.Write))
{
await STLExporter.ExportAsync(mesh, fs);
}
Other examples: https://github.com/nyarurato/NurbsSharpSample or Github Wiki
Documentation
API Docs: https://nyarurato.github.io/NurbsSharp/
Development
Clone the repo and build locally:
dotnet restore
dotnet build -c Debug
Run unit tests:
dotnet test -c Debug
Project layout highlights:
src/Core— numeric helpers and core typessrc/Geometry—NurbsCurve,NurbsSurface,Meshetc.src/Evaluation— curve/surface evaluatorssrc/Operation— topology operators (degree, knot, join, split)src/IO—OBJExporter,STLExporter, minimal IGES helpers
Contributing
Contributions are welcome. Typical workflow:
- Fork the repository
- Create a branch with a descriptive name
- Add tests for new behavior where appropriate
- Open a pull request against
main(or the target branch used in this repo)
License
MIT License
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
| .NET Core | netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.1 is compatible. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.1
- No dependencies.
-
net8.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.3.0 | 155 | 12/12/2025 |
| 0.2.0 | 512 | 12/1/2025 |
| 0.1.1 | 210 | 11/25/2025 |
| 0.1.0 | 371 | 11/21/2025 |
| 0.0.1-beta5 | 417 | 11/19/2025 |
| 0.0.1-beta4 | 415 | 11/18/2025 |
| 0.0.1-beta3 | 325 | 11/17/2025 |
| 0.0.1-beta2 | 274 | 11/14/2025 |
| 0.0.1-beta | 283 | 11/14/2025 |