Curve

class CCurve

Curve on the plot.

Public Functions

std::string GetName() const

Returns the name of the curve.

Returns

Curve’s name.

void SetName(const std::string &_name)

Sets new name of the curve.

Parameters

_name – Curve’s name.

double GetZValue() const

Returns the value of Z axis for which this curve is defined.

Returns

Z-value of the curve.

void SetZValue(double _z)

Sets a new value of Z axis for which this curve is defined.

Parameters

_z – Z-value of the curve.

void AddPoint(double _x, double _y)

Adds a new point to the curve.

Parameters
  • _x – X-value of the point.

  • _y – Y-value of the point.

void AddPoint(const CPoint &_point)

Adds a new point to the curve.

Parameters

_point – New point.

void AddPoints(const std::vector<double> &_x, const std::vector<double> &_y)

Adds new points to the curve.

Vectors must have the same length.

Parameters
  • _x – X-values of the points.

  • _y – Y-values of the points.

void AddPoints(const std::vector<CPoint> &_points)

Adds new points to the curve.

Parameters

_points – New points.

std::vector<double> GetXValues() const

Returns X values of all points defined in the curve.

Returns

X-values of all points.

std::vector<double> GetYValues() const

Returns Y values of all points defined in the curve.

Returns

Y-values of all points.

std::vector<CPoint> GetPoints() const

Returns all points defined in the curve.

Returns

All points.

void ClearData()

Removes all defined points from the curve.

void Clear()

Removes all data from the curve.