PostGIS  2.5.7dev-r@@SVN_REVISION@@

◆ initiate_effectivearea()

EFFECTIVE_AREAS* initiate_effectivearea ( const POINTARRAY inpts)

Definition at line 30 of file effectivearea.c.

31 {
32  LWDEBUG(2, "Entered initiate_effectivearea");
33  EFFECTIVE_AREAS *ea;
34  ea=lwalloc(sizeof(EFFECTIVE_AREAS));
35  ea->initial_arealist = lwalloc(inpts->npoints*sizeof(areanode));
36  ea->res_arealist = lwalloc(inpts->npoints*sizeof(double));
37  ea->inpts=inpts;
38  return ea;
39 }
void * lwalloc(size_t size)
Definition: lwutil.c:229
#define LWDEBUG(level, msg)
Definition: lwgeom_log.h:83
areanode * initial_arealist
Definition: effectivearea.h:67
double * res_arealist
Definition: effectivearea.h:68
const POINTARRAY * inpts
Definition: effectivearea.h:66
Structure to hold pointarray and its arealist.
Definition: effectivearea.h:65
uint32_t npoints
Definition: liblwgeom.h:374
This structure is placed in an array with one member per point.
Definition: effectivearea.h:39

References EFFECTIVE_AREAS::initial_arealist, EFFECTIVE_AREAS::inpts, lwalloc(), LWDEBUG, POINTARRAY::npoints, and EFFECTIVE_AREAS::res_arealist.

Referenced by do_test_lwgeom_effectivearea(), and ptarray_set_effective_area().

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