CurveLocus

References
[IoId("00000000-11ac-438f-9612-6833666f90d0")] public readonly struct CurveLocus : IStorable, IEquatable<CurveLocus>, IComparable<CurveLocus>
Represents a parameter or locus on or near a curve. This type replaces the simple numeric curve parameter as used in RhinoCommon and Grasshopper 1.0 with a more flexible and forgiving approach.

Constructors

CurveLocus

#
public CurveLocus(
reader
)

Properties

Kind

#
Gets the kind of locus this is.
public CurveLocusKind Kind { get; }

Value

#
Gets the value of this locus. The type of value depends on the Kind.
public object Value { get; }

Methods

CompareTo

#
public int CompareTo()

Equals

#
public bool Equals()

Equals

#
public override bool Equals(
obj
)
ValueType.Equals

FromLength

#
Create a curve locus from a length value.
public static CurveLocus FromLength(
length
)

FromParameter

#
Create a curve locus from a curve parameter.
public static CurveLocus FromParameter(
parameter
)

FromPoint

#
Create a curve locus from a 3D point.
public static CurveLocus FromPoint(
point
)

FromRatio

#
Create a curve locus from a normalised length ratio.
public static CurveLocus FromRatio(
ratio
)

GetHashCode

#
public override int GetHashCode()
Explicit

IStorable.Store

#
void IStorable.Store(
writer
)
Store

ResolveToParameter

#
Resolve this locus to an actual curve parameter.
public bool ResolveToParameter(
curve,
Curve to map on to.
out double
parameter
Resulting curve parameter.
)
True if mapping was successful, even if the mapping went beyond the curve domain.

ResolveToParameter

#
Resolve this locus to an actual curve parameter.
public bool ResolveToParameter(
circle,
Curve to map on to.
out double
parameter
Resulting curve parameter.
)
True if mapping was successful, even if the mapping went beyond the curve domain.

ResolveToParameter

#
Resolve this locus to an actual curve parameter.
public bool ResolveToParameter(
curve,
Curve to map on to.
out double
parameter
Resulting curve parameter.
)
True if mapping was successful, even if the mapping went beyond the curve domain.

ResolveToParameter

#
Resolve this locus to an actual curve parameter.
public bool ResolveToParameter(
line,
Curve to map on to.
out double
parameter
Resulting curve parameter.
)
True if mapping was successful, even if the mapping went beyond the curve domain.

ResolveToParameter

#
Resolve this locus to an actual curve parameter on a Rhino curve. This resolver is needed when a locus is defined on some unknown curve type, but it needs to be transferred onto the Curve conversion of that unknown curve type. I.e. let's say the locus is defined on an Arc, and the arc has already been converted into an ArcCurve or maybe even a NurbsCurve. Use this method to revolve the parameter on the ArcCurve or NurbsCurve implied by the locus and the original Arc.
public bool ResolveToParameter(
curve,
Curve on which this locus is defined.
assistant,
Curve assistant override. If null, a fitting assistant will be found.
rhinoCurve,
Rhino curve whose parameter we're interested in.
out double
parameter
Resulting curve parameter.
)
True if mapping was successful, even if the mapping went beyond the curve domain.

ResolveToParameter

#
Resolve this locus to an actual curve parameter.
public bool ResolveToParameter(
curve,
Curve to map on to.
assistant,
Curve assistant override. If null, a fitting assistant will be found.
out double
parameter
Resulting curve parameter.
)
True if mapping was successful, even if the mapping went beyond the curve domain.

ResolveToParameter

#
Resolve this locus to an actual curve parameter.
public bool ResolveToParameter(
polyline,
Curve to map on to.
out double
parameter
Resulting curve parameter.
)
True if mapping was successful, even if the mapping went beyond the curve domain.

ResolveToParameter

#
Resolve this locus to an actual curve parameter.
public bool ResolveToParameter(
rectangle,
Curve to map on to.
out double
parameter
Resulting curve parameter.
)
True if mapping was successful, even if the mapping went beyond the curve domain.

ResolveToParameter

#
Resolve this locus to an actual curve parameter.
public bool ResolveToParameter(
triangle,
Curve to map on to.
out double
parameter
Resulting curve parameter.
)
True if mapping was successful, even if the mapping went beyond the curve domain.

ToString

#
public override string ToString()

ToString

#
public string ToString()

TryParse

#
public static Result<CurveLocus> TryParse(
text
)

Convertors

OperationResultDescription
implicitdoubleCurveLocusCreate a curve locus from a parameter.
implicitPoint3dCurveLocusCreate a curve locus from a point.