PostGIS  2.5.1dev-r@@SVN_REVISION@@

◆ lwline_length()

double lwline_length ( const LWLINE line)

Definition at line 527 of file lwline.c.

References lwline_is_empty(), LWLINE::points, and ptarray_length().

Referenced by lwgeom_length().

528 {
529  if ( lwline_is_empty(line) )
530  return 0.0;
531  return ptarray_length(line->points);
532 }
double ptarray_length(const POINTARRAY *pts)
Find the 3d/2d length of the given POINTARRAY (depending on its dimensionality)
Definition: ptarray.c:1717
int lwline_is_empty(const LWLINE *line)
Definition: lwline.c:511
Definition: liblwgeom.h:424
Here is the call graph for this function:
Here is the caller graph for this function: