Skip to content

M_Rhino_Geometry_Curve_Fair

Will Pearson edited this page Aug 12, 2016 · 2 revisions

Curve.Fair Method

Fairs a curve object. Fair works best on degree 3 (cubic) curves. Attempts to remove large curvature variations while limiting the geometry changes to be no more than the specified tolerance.

Namespace: Rhino.Geometry
Assembly: RhinoCommon (in RhinoCommon.dll) Version: Rhino 6.0

Syntax

C#

public Curve Fair(
	double distanceTolerance,
	double angleTolerance,
	int clampStart,
	int clampEnd,
	int iterations
)

VB

Public Function Fair ( 
	distanceTolerance As Double,
	angleTolerance As Double,
	clampStart As Integer,
	clampEnd As Integer,
	iterations As Integer
) As Curve

Parameters

 

distanceTolerance
Type: System.Double
Maximum allowed distance the faired curve is allowed to deviate from the input.
angleTolerance
Type: System.Double
(in radians) kinks with angles <= angleTolerance are smoothed out 0.05 is a good default.
clampStart
Type: System.Int32
The number of (control vertices-1) to preserve at start. 0 = preserve start point

1 = preserve start point and 1st derivative

2 = preserve start point, 1st and 2nd derivative

clampEnd
Type: System.Int32
Same as clampStart.
iterations
Type: System.Int32
The number of iteratoins to use in adjusting the curve.

Return Value

Type: Curve
Returns new faired Curve on success, null on failure.

Version Information

Supported in: 6.0.16224.21491, 5D58w

See Also

Reference

Curve Class
Rhino.Geometry Namespace

Clone this wiki locally