TType to assist.

Constructors

CurveAssistant

#
protected CurveAssistant()
Abstract constructor, assigns Type and TypeId fields based on T.

Properties

IsReimplementation

#
public bool IsReimplementation { get; }
Gets whether or not this assistant is a type-safe re-implementation of a more generic assistant.
IsReimplementation

ReimplementationBase

#
public ICurveAssistant ReimplementationBase { get; }
Gets the base assistant (if any) this assistant is a re-implementation of.

Type

#
public Type Type { get; }
Gets the type associated with this assistant.
Type

Methods

BoundingBox

#
public virtual BoundingBox BoundingBox(T instance)
Gets the bounding box of a curve.
instance (T)Curve instance.
World axis aligned bounding box.

ConvertToNurbsCurve

#
public virtual NurbsCurve ConvertToNurbsCurve(T instance)
Convert the instance into a Rhino NURBS curve type which best describes the original instance. Note this method need not return a duplicate of the input, if a duplicate is required by the caller then a ReferenceEquals check must be performed.
instance (T)Instance to convert.
A Rhino NURBS curve or null if there is no way to describe the curve geometry as NURBS.

ConvertToPolyline

#
public virtual Polyline ConvertToPolyline(T instance, double deviation, double angle)
Convert the instance into a polyline.
instance (T)Instance to convert.
deviation (double)Maximum allowed deviation (absolute tolerance) between original curve and resulting polyline.
angle (double)Maximum allowed angle between original curve tangents and polyline corners.

ConvertToRhinoCurve

#
public abstract Curve ConvertToRhinoCurve(T instance)
Convert the instance into a Rhino curve type which best describes the original instance. Note this method need not return a duplicate of the input, if a duplicate is required by the caller then a ReferenceEquals check must be performed.
instance (T)Instance to convert.
A Rhino curve or null if there is no Rhino curve type which remotely describes this instance of T.

DivideByCount

#
public virtual double[] DivideByCount(T instance, int count)
Divide the curve into a number of equal length segments.
instance (T)Instance.
count (int)Number of segments.
Array of division parameters, including the start and end of the domain.

DivideByDistance

#
public virtual double[] DivideByDistance(T instance, double distance)
Divide a curve into segments whose end-points are a fixed distance apart.
instance (T)Instance.
distance (double)Distance between segment start and end-points.
Array of division parameters. The parameter at the end of the domain is not included if there's a remainder segment.

DivideByLength

#
public virtual double[] DivideByLength(T instance, double length)
Divide the curve into equal length segments.
instance (T)Instance.
length (double)Tier length.
Array of division parameters. The parameter at the end of the domain is not included if there's a remainder segment.

EvaluateCurvature

#
public virtual Vector3d EvaluateCurvature(T instance, double parameter, CurveEvaluationSide side)
Evaluate the curvature of the curve at the given parameter.
instance (T)Instance of T.
parameter (double)Curve parameter.
side (CurveEvaluationSide)Side of parameter to evaluate.
Curvature at parameter, or Vector3d.None if the curve cannot be evaluated at the given parameter.

EvaluateDerivatives

#
public virtual Vector3d[] EvaluateDerivatives(T instance, double parameter, CurveEvaluationSide side, int count)
Evaluate the first N derivatives of the curve at the given parameter.
instance (T)Instance of T.
parameter (double)Curve parameter.
side (CurveEvaluationSide)Side of parameter to evaluate.
count (int)Number of derivatives to compute.
An array of N+1 derivatives, where the first element describes the position vector.

EvaluatePerpendicular

#
public virtual Plane EvaluatePerpendicular(T instance, double parameter, CurveEvaluationSide side)
Evaluate the perpendicular plane of the curve at the given parameter.
instance (T)Instance of T.
parameter (double)Curve parameter.
side (CurveEvaluationSide)Side of parameter to evaluate.
Perpendicular at parameter, or Plane.None if the curve cannot be evaluated at the given parameter.

EvaluatePosition

#
public virtual Point3d EvaluatePosition(T instance, double parameter)
Evaluate the position of the curve at the given parameter.
instance (T)Instance of T.
parameter (double)Curve parameter.
Point at parameter, or Point3d.None if the curve cannot be evaluated at the given parameter.

EvaluateTangent

#
public virtual Vector3d EvaluateTangent(T instance, double parameter, CurveEvaluationSide side)
Evaluate the tangent of the curve at the given parameter.
instance (T)Instance of T.
parameter (double)Curve parameter.
side (CurveEvaluationSide)Side of parameter to evaluate.
Tangent at parameter, or Vector3d.None if the curve cannot be evaluated at the given parameter.

Explode

#
public virtual object[] Explode(T instance)
Explode a curve into smaller segments, each representing a subtype of curve.
instance (T)Instance.
Array of subcurves.

ExplodeRecursive

#
public virtual object[] ExplodeRecursive(T instance)
Explode a curve into the smallest possible segments.
instance (T)Instance.
Array of subcurves.

Extend

#
public virtual object Extend(T instance, CurveExtension start, CurveExtension end)
Extend the curve.
instance (T)Instance of T.
start (CurveExtension)Extension properties at start.
end (CurveExtension)Extension properties at end.
Modified curve.

FindClosestParameter

#
public virtual double FindClosestParameter(T instance, Point3d point)
Find the point on the curve closest to a test point.
instance (T)Instance of T.
point (Point3d)Test point.
Parameter or double.NaN if no parameter could be found.

FindCurvatureExtremes

#
public virtual void FindCurvatureExtremes(T instance, out double minimum, out double maximum)
Find the two parameters with the lowest and highest curvature.
instance (T)Instance.
minimum (out double)The (or one of the) parameters on the curve with the lowest curvature.
maximum (out double)The (or one of the) parameters on the curve with the highest curvature.

FindDiscontinuities

#
public virtual Discontinuity[] FindDiscontinuities(T instance, DiscontinuityLevel order)
Find all discontinuities along the curve up to and including a target continuity type.
instance (T)Instance.
order (DiscontinuityLevel)Maximum continuity order to search for.
Array of curve discontinuities.

FindFurthestParameter

#
public virtual double FindFurthestParameter(T instance, Point3d point)
Find the point on the curve furthest from a test point.
instance (T)Instance of T.
point (Point3d)Test point.
Parameter or double.NaN if no parameter could be found.

FindInflections

#
public virtual double[] FindInflections(T instance)
Find all inflection points along the curve.
instance (T)Instance.
Array of curve parameters.

FindPositionExtremes

#
public virtual void FindPositionExtremes(T instance, Plane plane, out double minimum, out double maximum)
Find the two parameters closest to and furthest away from a plane.
instance (T)Instance.
plane (Plane)Plane.
minimum (out double)The (or one of the) parameters on the curve closest to the plane.
maximum (out double)The (or one of the) parameters on the curve furthest from the plane.

FlipDirection

#
public virtual object FlipDirection(T instance)
Flip the curve.
instance (T)Instance to flip.
Flipped curve.

GetDomain

#
public virtual Interval GetDomain(T instance)
Get the domain of an instance of T.
instance (T)Instance of T.
Domain of curve.

GetEndPoints

#
public virtual void GetEndPoints(T instance, out Point3d start, out Point3d end)
Get the end-points of a curve.
instance (T)Instance.
start (out Point3d)Point at start.
end (out Point3d)Point at end.

GetEndTangents

#
public virtual void GetEndTangents(T instance, out Vector3d start, out Vector3d end)
Get the tangents at the ends of a curve.
instance (T)Instance.
start (out Vector3d)Tangent at start.
end (out Vector3d)Tangent at end.

GetLength

#
public virtual double GetLength(T instance)
Measure the total length of this curve.
instance (T)Instance.
Length.

GetSpans

#
public virtual Interval[] GetSpans(T instance)
Gets an array of curve domain spans. A span is a section of the curve that is reasonably simple in shape. Discontinuities in curves typically signal transitions from one span to another, but it depends on the curve type how it divides itself up.
instance (T)Instance.
Span domains.
Explicit

ICurveAssistant.BoundingBox

#
BoundingBox ICurveAssistant.BoundingBox(object instance)
instance (object)
BoundingBox
Explicit

ICurveAssistant.ConvertToNurbsCurve

#
NurbsCurve ICurveAssistant.ConvertToNurbsCurve(object instance)
instance (object)
Explicit

ICurveAssistant.ConvertToPolyline

#
Polyline ICurveAssistant.ConvertToPolyline(object instance, double deviation, double angle)
instance (object)
deviation (double)
angle (double)
ConvertToPolyline
Explicit

ICurveAssistant.ConvertToRhinoCurve

#
Curve ICurveAssistant.ConvertToRhinoCurve(object instance)
instance (object)
Explicit

ICurveAssistant.DivideByCount

#
double[] ICurveAssistant.DivideByCount(object instance, int count)
instance (object)
count (int)
DivideByCount
Explicit

ICurveAssistant.DivideByDistance

#
double[] ICurveAssistant.DivideByDistance(object instance, double distance)
instance (object)
distance (double)
DivideByDistance
Explicit

ICurveAssistant.DivideByLength

#
double[] ICurveAssistant.DivideByLength(object instance, double length)
instance (object)
length (double)
DivideByLength
Explicit

ICurveAssistant.EvaluateCurvature

#
Vector3d ICurveAssistant.EvaluateCurvature(object instance, double parameter, CurveEvaluationSide side)
instance (object)
parameter (double)
side (CurveEvaluationSide)
EvaluateCurvature
Explicit

ICurveAssistant.EvaluateDerivatives

#
Vector3d[] ICurveAssistant.EvaluateDerivatives(object instance, double parameter, CurveEvaluationSide side, int count)
instance (object)
parameter (double)
side (CurveEvaluationSide)
count (int)
Explicit

ICurveAssistant.EvaluatePerpendicular

#
Plane ICurveAssistant.EvaluatePerpendicular(object instance, double parameter, CurveEvaluationSide side)
instance (object)
parameter (double)
side (CurveEvaluationSide)
Explicit

ICurveAssistant.EvaluatePosition

#
Point3d ICurveAssistant.EvaluatePosition(object instance, double parameter)
instance (object)
parameter (double)
EvaluatePosition
Explicit

ICurveAssistant.EvaluateTangent

#
Vector3d ICurveAssistant.EvaluateTangent(object instance, double parameter, CurveEvaluationSide side)
instance (object)
parameter (double)
side (CurveEvaluationSide)
EvaluateTangent
Explicit

ICurveAssistant.Explode

#
object[] ICurveAssistant.Explode(object instance)
instance (object)
Explode
Explicit

ICurveAssistant.ExplodeRecursive

#
object[] ICurveAssistant.ExplodeRecursive(object instance)
instance (object)
ExplodeRecursive
Explicit

ICurveAssistant.Extend

#
instance (object)
start (CurveExtension)
end (CurveExtension)
Extend
Explicit

ICurveAssistant.FindClosestParameter

#
double ICurveAssistant.FindClosestParameter(object instance, Point3d point)
instance (object)
point (Point3d)
Explicit

ICurveAssistant.FindCurvatureExtremes

#
void ICurveAssistant.FindCurvatureExtremes(object instance, out double minimum, out double maximum)
instance (object)
minimum (out double)
maximum (out double)
Explicit

ICurveAssistant.FindDiscontinuities

#
Discontinuity[] ICurveAssistant.FindDiscontinuities(object instance, DiscontinuityLevel order)
instance (object)
order (DiscontinuityLevel)
Explicit

ICurveAssistant.FindFurthestParameter

#
double ICurveAssistant.FindFurthestParameter(object instance, Point3d point)
instance (object)
point (Point3d)
Explicit

ICurveAssistant.FindInflections

#
double[] ICurveAssistant.FindInflections(object instance)
instance (object)
FindInflections
Explicit

ICurveAssistant.FindPositionExtremes

#
void ICurveAssistant.FindPositionExtremes(object instance, Plane plane, out double minimum, out double maximum)
instance (object)
plane (Plane)
minimum (out double)
maximum (out double)
Explicit

ICurveAssistant.FlipDirection

#
object ICurveAssistant.FlipDirection(object instance)
instance (object)
FlipDirection
Explicit

ICurveAssistant.GetDomain

#
Interval ICurveAssistant.GetDomain(object instance)
instance (object)
GetDomain
Explicit

ICurveAssistant.GetEndPoints

#
void ICurveAssistant.GetEndPoints(object instance, out Point3d start, out Point3d end)
instance (object)
start (out Point3d)
end (out Point3d)
GetEndPoints
Explicit

ICurveAssistant.GetEndTangents

#
void ICurveAssistant.GetEndTangents(object instance, out Vector3d start, out Vector3d end)
instance (object)
start (out Vector3d)
end (out Vector3d)
GetEndTangents
Explicit

ICurveAssistant.GetLength

#
double ICurveAssistant.GetLength(object instance)
instance (object)
GetLength
Explicit

ICurveAssistant.GetSpans

#
Interval[] ICurveAssistant.GetSpans(object instance)
instance (object)
GetSpans
Explicit

ICurveAssistant.IntersectWith

#
double[] ICurveAssistant.IntersectWith(object instance, Plane plane)
instance (object)
plane (Plane)
IntersectWith
Explicit

ICurveAssistant.IsClosed

#
bool ICurveAssistant.IsClosed(object instance)
instance (object)
IsClosed
Explicit

ICurveAssistant.IsLinear

#
bool ICurveAssistant.IsLinear(object instance, double tolerance)
instance (object)
tolerance (double)
IsLinear
Explicit

ICurveAssistant.IsLinear

#
void ICurveAssistant.IsLinear(object instance, out Line line, out double deviation)
instance (object)
line (out Line)
deviation (out double)
IsLinear
Explicit

ICurveAssistant.IsPeriodic

#
bool ICurveAssistant.IsPeriodic(object instance)
instance (object)
IsPeriodic
Explicit

ICurveAssistant.IsPlanar

#
bool ICurveAssistant.IsPlanar(object instance, double tolerance)
instance (object)
tolerance (double)
IsPlanar
Explicit

ICurveAssistant.IsPlanar

#
void ICurveAssistant.IsPlanar(object instance, out Plane plane, out double deviation)
instance (object)
plane (out Plane)
deviation (out double)
IsPlanar
Explicit

ICurveAssistant.LengthAtParameter

#
bool ICurveAssistant.LengthAtParameter(object instance, double parameter, out double length)
instance (object)
parameter (double)
length (out double)
LengthAtParameter
Explicit

ICurveAssistant.ParameterAtLength

#
bool ICurveAssistant.ParameterAtLength(object instance, double length, out double parameter)
instance (object)
length (double)
parameter (out double)
ParameterAtLength
Explicit

ICurveAssistant.SetDomain

#
object ICurveAssistant.SetDomain(object instance, Interval domain)
instance (object)
domain (Interval)
SetDomain
Explicit

ICurveAssistant.Split

#
void ICurveAssistant.Split(object instance, double parameter, out object below, out object above)
instance (object)
parameter (double)
below (out object)
above (out object)
Split
Explicit

ICurveAssistant.Trim

#
object ICurveAssistant.Trim(object instance, Interval domain)
instance (object)
domain (Interval)
Trim

IntersectWith

#
public virtual double[] IntersectWith(T instance, Plane plane)
Find all the intersection parameters between this curve and a plane.
instance (T)Curve.
plane (Plane)Plane.
Collection of zero or more curve parameters.

IsClosed

#
public virtual bool IsClosed(T instance)
Determine whether the curve is closed.
instance (T)Instance of T.
Boolean value indicating closedness.

IsLinear

#
public virtual bool IsLinear(T instance, double tolerance)
Determine whether the curve is linear.
instance (T)Instance.
tolerance (double)Maximum allowed linearity deviation.
True if curve is linear.

IsLinear

#
public virtual void IsLinear(T instance, out Line line, out double deviation)
Determine the best fit line for this curve.
instance (T)Instance.
line (out Line)Line which best approximates curve.
deviation (out double)Maximum deviation from line.

IsPeriodic

#
public virtual bool IsPeriodic(T instance)
Determine whether the curve is periodic.
instance (T)Instance of T.
Boolean value indicating periodicity.

IsPlanar

#
public virtual bool IsPlanar(T instance, double tolerance)
Determine whether the curve is planar.
instance (T)Instance of T.
tolerance (double)Maximum allowed planarity deviation.
Boolean value indicating planarity.

IsPlanar

#
public virtual void IsPlanar(T instance, out Plane plane, out double deviation)
Determine the best fit plane for this curve.
instance (T)Instance of T.
plane (out Plane)Plane of curve or Plane.None if curve is not planar.
deviation (out double)Maximum deviation from plane.

LengthAtParameter

#
public virtual bool LengthAtParameter(T instance, double parameter, out double length)
Gets the length from the start of the curve to the given parameter.
instance (T)Instance of T.
parameter (double)Parameter on curve.
length (out double)Length from start of curve to parameter.
Success or failure.

ParameterAtLength

#
public virtual bool ParameterAtLength(T instance, double length, out double parameter)
Get the parameter of a curve at a given length from the start.
instance (T)Instance.
length (double)Length along curve to measure.
parameter (out double)Parameter at the given length.
True if length measurement was possible.

SetDomain

#
public virtual object SetDomain(T instance, Interval domain)
Assign a new parameter domain to the curve.
instance (T)Instance.
domain (Interval)New domain to assign.
Curve with new domain.

Split

#
public virtual void Split(T instance, double parameter, out object below, out object above)
Split a curve into two parts.
instance (T)Instance.
parameter (double)Splitting parameter.
below (out object)Part from start of curve to parameter.
above (out object)Part from parameter to end of curve.

Trim

#
public virtual object Trim(T instance, Interval domain)
Extract a subcurve from an instance of T.
instance (T)Instance of T.
domain (Interval)Domain of subcurve.
Sub curve.