PostGIS  3.4.0dev-r@@SVN_REVISION@@

◆ ptarray_collect_mvals()

static int ptarray_collect_mvals ( const POINTARRAY pa,
double  tmin,
double  tmax,
double *  mvals 
)
static

Definition at line 1071 of file lwlinearreferencing.c.

1072 {
1073  POINT4D pbuf;
1074  uint32_t i, n = 0;
1075  for (i = 0; i < pa->npoints; ++i)
1076  {
1077  getPoint4d_p(pa, i, &pbuf); /* could be optimized */
1078  if (pbuf.m >= tmin && pbuf.m <= tmax)
1079  mvals[n++] = pbuf.m;
1080  }
1081  return n;
1082 }
int getPoint4d_p(const POINTARRAY *pa, uint32_t n, POINT4D *point)
Definition: lwgeom_api.c:125
double m
Definition: liblwgeom.h:414
uint32_t npoints
Definition: liblwgeom.h:427

References getPoint4d_p(), POINT4D::m, and POINTARRAY::npoints.

Referenced by lwgeom_cpa_within(), and lwgeom_tcpa().

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