371 POSTGIS_DEBUG(5,
"entered function");
373 if ( a == NULL || b == NULL )
375 elog(ERROR,
"gidx_inter_volume received a null argument");
388 result = Min(GIDX_GET_MAX(a,0),GIDX_GET_MAX(b,0)) - Max(GIDX_GET_MIN(a,0),GIDX_GET_MIN(b,0));
391 if ( result < 0.0 )
return 0.0;
394 for ( i = 1; i < GIDX_NDIMS(b); i++ )
396 float width = Min(GIDX_GET_MAX(a,i),GIDX_GET_MAX(b,i)) - Max(GIDX_GET_MIN(a,i),GIDX_GET_MIN(b,i));
397 if ( width < 0.0 )
return 0.0;
401 POSTGIS_DEBUGF(5,
"volume( %s intersection %s ) = %.12g", gidx_to_string(a), gidx_to_string(b), result);
bool gidx_is_unknown(const GIDX *a)
static void gidx_dimensionality_check(GIDX **a, GIDX **b)