PolygonLabelPlacementCalculator.simpleCentroid constructor
- @literal
Places the Polygon.label at the approximate centroid calculated by averaging all the points of the polygon
This is computationally cheap and gives reasonable results for convex polygons. However, for more complex or convex polygons, results may not be as good (but they should still be acceptable).
Important
If the polygon may be over the anti-meridan boundary, SimpleMultiWorldCentroidCalculator must be used - other calculators will produce unexpected results.
Implementation
@literal
const factory PolygonLabelPlacementCalculator.simpleCentroid() =
SimpleCentroidCalculator._;