Click or drag to resize

GdiExtensionMethodsGetFractionalIndexFromDistanceFromStartOfPartialPolylineCurve Method

Gets the fractional index into points of a partial polyline by searching a point along the partial polyline that has a specified distance to the start point of the partial polyline.

Namespace: Altaxo.Graph.Gdi
Assembly: AltaxoBase (in AltaxoBase.dll) Version: 4.8.3179.0 (4.8.3179.0)
Syntax
C#
public static double GetFractionalIndexFromDistanceFromStartOfPartialPolylineCurve(
	PointF[] points,
	int startIndex,
	int endIndex,
	double distanceFromStart
)

Parameters

points  PointF
The points of the global polyline curve. From this points only the partial polyline (indices startIndex .. endIndex) is considered.
startIndex  Int32
The first index of the partial polyline curve that is considered here.
endIndex  Int32
The last valid index of the partial polyline curve that is considered here.
distanceFromStart  Double
The distance to the start of the partial polyline curve, i.e. to the point at index startIndex.

Return Value

Double
The fractional index of the global polyline curve where the point at this fractional index has a distance of distanceFromStart from the point at index startIndex. The return value is in the range [startIndex .. endIndex]. If no such point is found, then double.NaN is returned.
See Also