PostGIS  2.2.7dev-r@@SVN_REVISION@@
void gbox_expand ( GBOX g,
double  d 
)

Move the box minimums down and the maximums up by the distance provided.

Definition at line 93 of file g_box.c.

References GBOX::flags, FLAGS_GET_M, FLAGS_GET_Z, GBOX::mmax, GBOX::mmin, GBOX::xmax, GBOX::xmin, GBOX::ymax, GBOX::ymin, GBOX::zmax, and GBOX::zmin.

Referenced by BOX2D_expand(), LWGEOM_expand(), lwt_AddLine(), lwt_AddPolygon(), and union_pairs_within_distance().

94 {
95  g->xmin -= d;
96  g->xmax += d;
97  g->ymin -= d;
98  g->ymax += d;
99  if ( FLAGS_GET_Z(g->flags) )
100  {
101  g->zmin -= d;
102  g->zmax += d;
103  }
104  if ( FLAGS_GET_M(g->flags) )
105  {
106  g->mmin -= d;
107  g->mmax += d;
108  }
109 }
double xmax
Definition: liblwgeom.h:277
double zmax
Definition: liblwgeom.h:281
double ymin
Definition: liblwgeom.h:278
double xmin
Definition: liblwgeom.h:276
double ymax
Definition: liblwgeom.h:279
#define FLAGS_GET_Z(flags)
Macros for manipulating the 'flags' byte.
Definition: liblwgeom.h:124
uint8_t flags
Definition: liblwgeom.h:275
double mmin
Definition: liblwgeom.h:282
double zmin
Definition: liblwgeom.h:280
#define FLAGS_GET_M(flags)
Definition: liblwgeom.h:125
double mmax
Definition: liblwgeom.h:283

Here is the caller graph for this function: