PostGIS  2.1.10dev-r@@SVN_REVISION@@
int gbox_contains_point3d ( const GBOX gbox,
const POINT3D pt 

Return true if the point is inside the gbox.

Definition at line 205 of file g_box.c.

References LW_FALSE, LW_TRUE, POINT3D::x, GBOX::xmax, GBOX::xmin, POINT3D::y, GBOX::ymax, GBOX::ymin, POINT3D::z, GBOX::zmax, and GBOX::zmin.

Referenced by CircTreePIP(), gbox_pt_outside(), and lwpoly_covers_point2d().

206 {
207  if ( gbox->xmin > pt->x || gbox->ymin > pt->y || gbox->zmin > pt->z ||
208  gbox->xmax < pt->x || gbox->ymax < pt->y || gbox->zmax < pt->z )
209  {
210  return LW_FALSE;
211  }
212  return LW_TRUE;
213 }
double y
Definition: liblwgeom.h:296
double xmax
Definition: liblwgeom.h:249
double x
Definition: liblwgeom.h:296
double z
Definition: liblwgeom.h:296
double zmax
Definition: liblwgeom.h:253
double ymin
Definition: liblwgeom.h:250
double xmin
Definition: liblwgeom.h:248
#define LW_FALSE
Definition: liblwgeom.h:52
#define LW_TRUE
Return types for functions with status returns.
Definition: liblwgeom.h:51
double ymax
Definition: liblwgeom.h:251
double zmin
Definition: liblwgeom.h:252

Here is the caller graph for this function: