resizeAll method

List<Offset> resizeAll({
  1. required double originalSize,
  2. required double transformSize,
})

transform custom path to resized custom path

Implementation

List<Offset> resizeAll(
    {required double originalSize, required double transformSize}) {
  double resizeFactor = transformSize / originalSize;
  List<Offset> resizedCustomPath = [];

  for (final point in this) {
    resizedCustomPath
        .add(Offset(point.dx * resizeFactor, point.dy * resizeFactor));
  }
  return resizedCustomPath;
}