PostGIS  2.4.9dev-r@@SVN_REVISION@@

◆ buildarea6()

static void buildarea6 ( void  )
static

Definition at line 260 of file cu_buildarea.c.

References check_geom_equal, cu_error_msg_reset(), LW_PARSER_CHECK_NONE, lwgeom_buildarea(), lwgeom_free(), and lwgeom_from_wkt().

Referenced by buildarea_suite_setup().

261 {
262  LWGEOM *gin, *gout, *gexp;
263 
265 
266  gin = lwgeom_from_wkt(
267 "MULTILINESTRING((0 0, 20 0, 20 20, 0 20, 0 0),(2 2, 18 2, 18 18, 2 18, 2 2),(10 2, 10 18))",
269  CU_ASSERT(gin != NULL);
270 
271  gexp = lwgeom_from_wkt(
272 "POLYGON((0 0,0 20,20 20,20 0,0 0),(2 2,18 2,18 18,2 18,2 2))",
274  CU_ASSERT(gexp != NULL);
275 
276  gout = lwgeom_buildarea(gin);
277  CU_ASSERT(gout != NULL);
278 
279  check_geom_equal(gout, gexp);
280 
281  lwgeom_free(gout);
282  lwgeom_free(gexp);
283  lwgeom_free(gin);
284 
285 }
void lwgeom_free(LWGEOM *geom)
Definition: lwgeom.c:1099
LWGEOM * lwgeom_from_wkt(const char *wkt, const char check)
Definition: lwin_wkt.c:904
#define LW_PARSER_CHECK_NONE
Definition: liblwgeom.h:2013
void cu_error_msg_reset()
LWGEOM * lwgeom_buildarea(const LWGEOM *geom)
Take a geometry and return an areal geometry (Polygon or MultiPolygon).
#define check_geom_equal(gobt, gexp)
Definition: cu_buildarea.c:23
Here is the call graph for this function:
Here is the caller graph for this function: