PostGIS  2.2.8dev-r@@SVN_REVISION@@

◆ BOX2D_union()

Datum BOX2D_union ( PG_FUNCTION_ARGS  )

Definition at line 351 of file lwgeom_box.c.

References BOX2D_expand(), gbox_union(), lwalloc(), and PG_FUNCTION_INFO_V1().

Referenced by BOX2D_intersects().

352 {
353  GBOX *a = (GBOX*) PG_GETARG_POINTER(0);
354  GBOX *b = (GBOX*) PG_GETARG_POINTER(1);
355  GBOX *n;
356 
357  n = (GBOX *) lwalloc(sizeof(GBOX));
358  if ( ! gbox_union(a,b,n) ) PG_RETURN_NULL();
359  PG_RETURN_POINTER(n);
360 }
int gbox_union(const GBOX *g1, const GBOX *g2, GBOX *gout)
Update the output GBOX to be large enough to include both inputs.
Definition: g_box.c:111
void * lwalloc(size_t size)
Definition: lwutil.c:199
Here is the call graph for this function:
Here is the caller graph for this function: