Class LiteFreeformLineSeries
- Namespace
- LightningChartLib.WinForms.Charting.SeriesXY
- Assembly
- LightningChart.WinForms.Charting.NET4.dll
Lite freeform line series. Uses arrays of points as input data: double[N,2]. Can be only used with Linear axis and DirectX11 engine.
public class LiteFreeformLineSeries : BlockSeriesBase<double[,]>, IChartNode, IDisposable, IHighlightingItem, IRealtimeShiftable
- Inheritance
-
LiteFreeformLineSeries
- Implements
- Inherited Members
Constructors
LiteFreeformLineSeries()
Constructor.
public LiteFreeformLineSeries()
LiteFreeformLineSeries(ViewXY, AxisX, AxisY)
Constructor.
public LiteFreeformLineSeries(ViewXY owner, AxisX axisX, AxisY axisY)
Parameters
Properties
this[int]
Get point at index.
public PointDouble2D this[int index] { get; }
Parameters
indexintIndex to point.
Property Value
- PointDouble2D
Point at index.
LimitYToStackSegment
Line rendering limit on y-axis.
public LimitYToSegment LimitYToStackSegment { get; set; }
Property Value
PointCount
Added point count.
public int PointCount { get; }
Property Value
PointCountLimit
Point count limit. Series will contain at least this amount of points, but will limit to higher count based on data blocks.
public int PointCountLimit { get; set; }
Property Value
PointCountLimitEnabled
Enable/disable point count limiter. See PointCountLimit
public bool PointCountLimitEnabled { get; set; }
Property Value
Points
Series points.
public double[][,] Points { set; }
Property Value
- double[][,]
Methods
AddPoints(double[,], bool)
Add points to end of series, [N,2] format, where [i,0] is x and [i,1] is y.
public int AddPoints(double[,] data, bool invalidateChart)
Parameters
datadouble[,]Data array.
invalidateChartboolUpdate chart after adding data. Updating will raise CPU load, which is why usage of this method is not recommended with every call if points are added many times per second.
Returns
- int
Series point count after adding.
Construct()
Construct some properties.
protected override void Construct()
GetMinMaxFromXRange(out double, out double, double, double, bool)
Get minimum and maximum Y value withing given X range.
public override bool GetMinMaxFromXRange(out double yMin, out double yMax, double xRangeMin, double xRangeMax, bool ignoreZeros)
Parameters
yMindoubleMinimum Y value.
yMaxdoubleMaximum Y value.
xRangeMindoubleX range start.
xRangeMaxdoubleX range end.
ignoreZerosboolIgnore zeros.
Returns
- bool
True if values were successfully detected.
GetPointAtIndex(int)
Get point at index.
public PointDouble2D GetPointAtIndex(int index)
Parameters
indexintIndex to point.
Returns
- PointDouble2D
Point at index.
GetXMinMax(out double, out double)
Get minimum X and maximum X of series X values
public override bool GetXMinMax(out double xMin, out double xMax)
Parameters
Returns
- bool
True if minimum X and maximum X was obtained successfully.
IsPositionOver(int, int, bool)
Is position over series.
public override bool IsPositionOver(int x, int y, bool useDIP = true)
Parameters
Returns
- bool
true if position is over series. Else false.
SolveNearestSampleByValue(double, double, out double, out double, out int)
public override bool SolveNearestSampleByValue(double xValue, double yValue, out double nearestSampleXValue, out double nearestSampleYValue, out int nearestIndex)
Parameters
xValuedoubleparam xValue M:LightningChartLib.WinForms.Charting.SeriesXY.LiteFreeformLineSeries.SolveNearestSampleByValue(System.Double,System.Double,System.Double@,System.Double@,System.Int32@) yValuedoubleparam yValue M:LightningChartLib.WinForms.Charting.SeriesXY.LiteFreeformLineSeries.SolveNearestSampleByValue(System.Double,System.Double,System.Double@,System.Double@,System.Int32@) nearestSampleXValuedoubleparam nearestSampleXValue M:LightningChartLib.WinForms.Charting.SeriesXY.LiteFreeformLineSeries.SolveNearestSampleByValue(System.Double,System.Double,System.Double@,System.Double@,System.Int32@) nearestSampleYValuedoubleparam nearestSampleYValue M:LightningChartLib.WinForms.Charting.SeriesXY.LiteFreeformLineSeries.SolveNearestSampleByValue(System.Double,System.Double,System.Double@,System.Double@,System.Int32@) nearestIndexintparam nearestIndex M:LightningChartLib.WinForms.Charting.SeriesXY.LiteFreeformLineSeries.SolveNearestSampleByValue(System.Double,System.Double,System.Double@,System.Double@,System.Int32@)
Returns
- bool
returns M:LightningChartLib.WinForms.Charting.SeriesXY.LiteFreeformLineSeries.SolveNearestSampleByValue(System.Double,System.Double,System.Double@,System.Double@,System.Int32@)
SolveYCoordsAtXCoord(float, bool)
Find series points of given X-coordinate and get corresponding Y-coordinates.
public IList<LineSeriesCoordinateSolveResult> SolveYCoordsAtXCoord(float x, bool useDIP = false)
Parameters
Returns
- IList<LineSeriesCoordinateSolveResult>
List of results at x-coordinate.
SolveYValueAtXValue(double)
Solving single y-value at x-value is not supported. Use SolveYValuesAtXValue() method instead.
public override LineSeriesValueSolveResult SolveYValueAtXValue(double x)
Parameters
xdoubleX value.
Returns
- LineSeriesValueSolveResult
returns M:LightningChartLib.WinForms.Charting.SeriesXY.LiteFreeformLineSeries.SolveYValueAtXValue(System.Double)
SolveYValuesAtXValue(double)
Solve Y value on given X value. Returned value will be interpolated, if X is between sequential points X values.
public IList<LineSeriesValueSolveResult> SolveYValuesAtXValue(double x)
Parameters
xdoubleX value.
Returns
- IList<LineSeriesValueSolveResult>
List will be empty if X is not in the data range.
Events
OldDataDropped
Occurs when old data samples have been dropped.
public event LiteFreeformLineSeries.OldDataDroppedEventHandler OldDataDropped