MathHelperFindEllipseFromPoints Method
|
Checks if a list of 2D points lies on an ellipse and retrieves its parameters.
Namespace:
DXFReaderNET
Assembly:
DXFReaderNET (in DXFReaderNET.dll) Version: 20.12.2
Syntaxpublic static bool FindEllipseFromPoints(
List<Vector2> points,
out Vector2 center,
out double majorAxis,
out double minorAxis,
out double rotation,
double tolerance = 1E-06
)
Public Shared Function FindEllipseFromPoints (
points As List(Of Vector2),
<OutAttribute> ByRef center As Vector2,
<OutAttribute> ByRef majorAxis As Double,
<OutAttribute> ByRef minorAxis As Double,
<OutAttribute> ByRef rotation As Double,
Optional tolerance As Double = 1E-06
) As Boolean
public:
static bool FindEllipseFromPoints(
List<Vector2>^ points,
[OutAttribute] Vector2% center,
[OutAttribute] double% majorAxis,
[OutAttribute] double% minorAxis,
[OutAttribute] double% rotation,
double tolerance = 1E-06
)
static member FindEllipseFromPoints :
points : List<Vector2> *
center : Vector2 byref *
majorAxis : float byref *
minorAxis : float byref *
rotation : float byref *
?tolerance : float
(* Defaults:
let _tolerance = defaultArg tolerance 1E-06
*)
-> bool
STATIC METHOD FindEllipseFromPoints(
points AS List<Vector2>,
center OUT Vector2,
majorAxis OUT REAL8,
minorAxis OUT REAL8,
rotation OUT REAL8,
tolerance AS REAL8 := 1E-06
) AS LOGIC
Parameters
- points
- Type: System.Collections.GenericListVector2
List of 2D points to check. - center
- Type: DXFReaderNETVector2
The calculated center of the ellipse (output). - majorAxis
- Type: SystemDouble
The calculated major axis length of the ellipse (output). - minorAxis
- Type: SystemDouble
The calculated minor axis length of the ellipse (output). - rotation
- Type: SystemDouble
The calculated rotation of the ellipse in degrees (output). - tolerance (Optional)
- Type: SystemDouble
Tolerance for floating-point comparisons.
Return Value
Type:
BooleanTrue if the points lie on an ellipse, otherwise false.
See Also