PostGIS  2.1.10dev-r@@SVN_REVISION@@
double lwcurvepoly_area ( const LWCURVEPOLY curvepoly)

This should be rewritten to make use of the curve itself.

Definition at line 120 of file lwcurvepoly.c.

References area(), lwcurvepoly_segmentize(), lwgeom_is_empty(), lwpoly_area(), and lwpoly_free().

Referenced by lwgeom_area().

121 {
122  double area = 0.0;
123  LWPOLY *poly;
124  if( lwgeom_is_empty((LWGEOM*)curvepoly) )
125  return 0.0;
126  poly = lwcurvepoly_segmentize(curvepoly, 32);
127  area = lwpoly_area(poly);
128  lwpoly_free(poly);
129  return area;
130 }
LWPOLY * lwcurvepoly_segmentize(const LWCURVEPOLY *curvepoly, uint32_t perQuad)
Definition: lwsegmentize.c:290
void lwpoly_free(LWPOLY *poly)
Definition: lwpoly.c:79
double lwpoly_area(const LWPOLY *poly)
Find the area of the outer ring - sum (area of inner rings).
Definition: lwpoly.c:390
int lwgeom_is_empty(const LWGEOM *geom)
Return true or false depending on whether a geometry is an "empty" geometry (no vertices members) ...
Definition: lwgeom.c:1229

Here is the call graph for this function:

Here is the caller graph for this function: