transformValues method
Transforms the x and y values to screen coordinates.
Implementation
@override
void transformValues() {
if (xValues.isEmpty || yValues.isEmpty) {
return;
}
points.clear();
_drawIndexes.clear();
_highPoints.clear();
_lowPoints.clear();
_fillPath.reset();
_strokePath.reset();
_calculatePoints(xValues, yValues);
final List<Offset> lerpHighPoints =
_lerpPoints(_oldHighPoints, _highPoints);
final List<Offset> lerpLowPoints = _lerpPoints(_oldLowPoints, _lowPoints);
_createFillPath(_fillPath, lerpHighPoints, lerpLowPoints);
switch (series.borderDrawMode) {
case BorderDrawMode.all:
_strokePath = _fillPath;
break;
case BorderDrawMode.top:
_createTopStrokePath(_strokePath, lerpHighPoints);
break;
case BorderDrawMode.excludeBottom:
_createExcludeBottomStrokePath(
_strokePath, lerpHighPoints, lerpLowPoints);
break;
}
}