Function initializing shortestline and longestline calculations.
Definition at line 84 of file measures.c.
References COLLECTIONTYPE, DIST_MIN, DISTPTS::distance, lw_dist2d_comp(), lwcollection_construct_empty(), LWDEBUG, lwerror(), lwline_from_ptarray(), lwpoint_make2d(), DISTPTS::mode, DISTPTS::p1, DISTPTS::p2, DISTPTS::tolerance, POINT2D::x, and POINT2D::y.
Referenced by lw_dist3d_distanceline(), lwgeom_closest_line(), and lwgeom_furthest_line().
88 double initdistance = ( mode ==
DIST_MIN ? FLT_MAX : -1.0);
97 LWDEBUG(2,
"lw_dist2d_distanceline is called");
102 lwerror(
"Some unspecified error.");
109 LWDEBUG(3,
"didn't find geometries to measure between, returning null");
int lw_dist2d_comp(const LWGEOM *lw1, const LWGEOM *lw2, DISTPTS *dl)
This function just deserializes geometries Bboxes is not checked here since it is the subgeometries b...
LWPOINT * lwpoint_make2d(int srid, double x, double y)
LWLINE * lwline_from_ptarray(int srid, uint32_t npoints, LWPOINT **points)
#define LWDEBUG(level, msg)
Structure used in distance-calculations.
LWCOLLECTION * lwcollection_construct_empty(uint8_t type, int srid, char hasz, char hasm)
void lwerror(const char *fmt,...)
Write a notice out to the error handler.