getProjectedBounds method
Rescales the bounds to a given zoom value.
Implementation
@override
Bounds<double>? getProjectedBounds(double zoom) {
if (infinite) return null;
final b = projection.bounds!;
final zoomScale = scale(zoom);
final transformation = _getTransformationByZoom(zoom);
final (minx, miny) = transformation.transform(b.min.x, b.min.y, zoomScale);
final (maxx, maxy) = transformation.transform(b.max.x, b.max.y, zoomScale);
return Bounds<double>(
Point<double>(minx, miny),
Point<double>(maxx, maxy),
);
}