Closed chaosmail closed 7 years ago
Thanks for reporting this - will need looking into. Also, I have reproduced the reported output.
Contrast:
select ST_Area(ST_MultiPolygon('multipolygon(((0.0 0.0, 1.0 0.0, 1.0 1.0, 0.0 1.0, 0.0 0.0)))')); 1.0 select ST_Area(ST_MultiPolygon(array(0.0, 0.0, 0.0, 1.0, 1.0, 1.0, 1.0, 0.0))); 1.0
In ST_Polygon, we obviate ordering/orientation issues constructing from number pairs, by generating WKT. We could do the same in ST_MultiPolygon. comments @climbage ?
Seems reasonable
Also, ST_MultiPolygon erroneously sets y=x for the first point listed.
select ST_AsText(ST_MultiPolygon(array(0.0, 1.0, 1.0, 1.0, 1.0, 0.0))); MULTIPOLYGON (((0 0, 1 0, 1 1, 0 0)))
Hi guys,
When computing the Area of a single Polygon as MultiPolygon, the resulting area is negative.
When using a Polygon, it is working properly.
Best, Christoph