PostGIS  3.7.0dev-r@@SVN_REVISION@@

◆ lwt_LoadPolygon()

static void lwt_LoadPolygon ( LWT_TOPOLOGY topo,
const LWPOLY poly,
double  tol 
)
static

Definition at line 7569 of file lwgeom_topo.c.

7570 {
7571  uint32_t i;
7572 
7573  /* Add each ring as an edge */
7574  for ( i=0; i<poly->nrings; ++i )
7575  {
7576  LWLINE *line;
7577  POINTARRAY *pa;
7578 
7579  /* TODO: avoid the clone here */
7580  pa = ptarray_clone(poly->rings[i]);
7581  line = lwline_construct(topo->srid, NULL, pa);
7582  lwt_LoadLine(topo, line, tol, -1);
7583  lwline_free(line);
7584  }
7585 }
LWLINE * lwline_construct(int32_t srid, GBOX *bbox, POINTARRAY *points)
Definition: lwline.c:42
void lwline_free(LWLINE *line)
Definition: lwline.c:67
POINTARRAY * ptarray_clone(const POINTARRAY *ptarray)
Clone a POINTARRAY object.
Definition: ptarray.c:674
static void lwt_LoadLine(LWT_TOPOLOGY *topo, LWLINE *line, double tol, int max_new_edges)
Definition: lwgeom_topo.c:7558
POINTARRAY ** rings
Definition: liblwgeom.h:519
uint32_t nrings
Definition: liblwgeom.h:524

References lwline_construct(), lwline_free(), lwt_LoadLine(), LWPOLY::nrings, ptarray_clone(), LWPOLY::rings, and LWT_TOPOLOGY_T::srid.

Referenced by _lwt_LoadGeometryRecursive(), and lwt_AddPolygon().

Here is the call graph for this function:
Here is the caller graph for this function: