34#ifndef __TGEO_SPATIALRELS_H__
35#define __TGEO_SPATIALRELS_H__
41#include "temporal/temporal.h"
43#define INVERT_RESULT(result) (result < 0 ? -1 : (result > 0) ? 0 : 1)
116 double dist,
bool ever);
118 double dist,
bool ever);
int ea_disjoint_tgeo_geo(const Temporal *temp, const GSERIALIZED *gs, bool ever)
Return 1 if a temporal geometry and a geometry are ever disjoint, 0 if not, and -1 on error or if the...
Definition: tgeo_spatialrels.c:927
int ea_dwithin_tgeo_geo(const Temporal *temp, const GSERIALIZED *gs, double dist, bool ever)
Return 1 if a geometry and a temporal geo are ever within the given distance, 0 if not,...
Definition: tgeo_spatialrels.c:1445
int ea_intersects_tgeo_geo(const Temporal *temp, const GSERIALIZED *gs, bool ever)
Return 1 if a temporal geometry ever/always intersects a geometry, 0 if not, and -1 on error or if th...
Definition: tgeo_spatialrels.c:1080
int ea_intersects_geo_tgeo(const GSERIALIZED *gs, const Temporal *temp, bool ever)
Return 1 if a geometry intersects a temporal geometry, 0 if not, and -1 on error or if the geometry i...
Definition: tgeo_spatialrels.c:1103
int ea_disjoint_geo_tgeo(const GSERIALIZED *gs, const Temporal *temp, bool ever)
Return 1 if a temporal geometry and a geometry are ever disjoint, 0 if not, and -1 on error or if the...
Definition: tgeo_spatialrels.c:975
int ea_touches_tgeo_geo(const Temporal *temp, const GSERIALIZED *gs, bool ever)
Return 1 if a temporal geometry ever/always touches a geometry, 0 if not, and -1 on error or if the g...
Definition: tgeo_spatialrels.c:1313
int ea_covers_geo_tgeo(const GSERIALIZED *gs, const Temporal *temp, bool ever)
Return 1 if a temporal geometry ever/always covers a geo, 0 if not, and -1 on error or if the geometr...
Definition: tgeo_spatialrels.c:777
int ea_intersects_tgeo_tgeo(const Temporal *temp, const Temporal *temp2, bool ever)
Return 1 if the temporal geos ever/always intersect, 0 if not, and -1 on error or if the temporal geo...
Definition: tgeo_spatialrels.c:1151
int ea_covers_tgeo_tgeo(const Temporal *temp, const Temporal *temp2, bool ever)
Return 1 if a temporal geometry ever covers another one, 0 if not, and -1 on error.
Definition: tgeo_spatialrels.c:872
int ea_contains_tgeo_tgeo(const Temporal *temp, const Temporal *temp2, bool ever)
Return 1 if a temporal geometry ever contains another temporal geometry, 0 if not,...
Definition: tgeo_spatialrels.c:696
int ea_disjoint_tgeo_tgeo(const Temporal *temp, const Temporal *temp2, bool ever)
Return 1 if the temporal geos ever/always intersect, 0 if not, and -1 on error or if the temporal geo...
Definition: tgeo_spatialrels.c:1023
int ea_contains_geo_tgeo(const GSERIALIZED *gs, const Temporal *temp, bool ever)
Return 1 if a temporal geometry ever/always contains a geo, 0 if not, and -1 on error or if the geome...
Definition: tgeo_spatialrels.c:601
int ea_contains_tgeo_geo(const Temporal *temp, const GSERIALIZED *gs, bool ever)
Return 1 if a temporal geometry ever/always contains a geo, 0 if not, and -1 on error or if the geome...
Definition: tgeo_spatialrels.c:612
int ea_covers_tgeo_geo(const Temporal *temp, const GSERIALIZED *gs, bool ever)
Return 1 if a temporal geometry ever/always covers a geo, 0 if not, and -1 on error or if the geometr...
Definition: tgeo_spatialrels.c:788
int ea_touches_tgeo_tgeo(const Temporal *temp, const Temporal *temp2, bool ever)
Return 1 if a temporal geometry ever/always touches another one, 0 if not, and -1 on error.
Definition: tgeo_spatialrels.c:1380
Datum(* varfunc)(Datum,...)
Definition: temporal.h:283
Datum(* datum_func2)(Datum, Datum)
Definition: temporal.h:296
Datum(* datum_func3)(Datum, Datum, Datum)
Definition: temporal.h:297
External API of the Mobility Engine Open Source (MEOS) library.
int64 TimestampTz
Definition: postgres_ext_defs.in.h:22
signed short int16
Definition: postgres_ext_defs.in.h:10
uintptr_t Datum
Definition: postgres_ext_defs.in.h:7
Definition: postgis_ext_defs.in.h:170
Structure to represent the common structure of temporal values of any temporal subtype.
Definition: meos.h:173
datum_func3 geo_dwithin_fn_geo(int16 flags1, uint8_t flags2)
Select the appropriate dwithin function depending on the flags.
Definition: tgeo_spatialrels.c:279
int spatialrel_geo_geo(const GSERIALIZED *gs1, const GSERIALIZED *gs2, Datum param, varfunc func, int numparam, bool invert)
Return 1 if two geometries satisfy a spatial relationship.
Definition: tcbuffer_spatialrels.c:123
Datum datum_geom_disjoint2d(Datum geom1, Datum geom2)
Return a Datum true if two geometries are disjoint in 2D.
Definition: tgeo_spatialrels.c:91
Datum datum_geom_intersects2d(Datum geom1, Datum geom2)
Return a Datum true if two geometries intersect in 2D.
Definition: tgeo_spatialrels.c:121
Datum datum_geom_dwithin2d(Datum geom1, Datum geom2, Datum dist)
Return a Datum true if two 2D geometries are within a distance.
Definition: tgeo_spatialrels.c:151
Datum datum_geom_touches(Datum geom1, Datum geom2)
Return a Datum true if the first geometry covers the second one.
Definition: tgeo_spatialrels.c:191
Datum datum_geom_covers(Datum geom1, Datum geom2)
Return a Datum true if the first geometry covers the second one.
Definition: tgeo_spatialrels.c:81
int tpointsegm_tdwithin_turnpt(Datum start1, Datum end1, Datum start2, Datum end2, Datum value, TimestampTz lower, TimestampTz upper, TimestampTz *t1, TimestampTz *t2)
Return the value and timestamp at which the two temporal geo segments are at the minimum distance.
Definition: tgeo_spatialrels.c:1516
int ea_spatialrel_tspatial_geo(const Temporal *temp, const GSERIALIZED *gs, datum_func2 func, bool ever, bool invert)
Return true if two temporal geos ever/always satisfy a spatial relationship.
Definition: tgeo_spatialrels.c:454
Datum datum_geom_relate_pattern(Datum geog1, Datum geog2, Datum p)
Return a Datum true if two 2D geometries are within a distance.
Definition: tgeo_spatialrels.c:181
int spatialrel_tgeo_tgeo(const Temporal *temp1, const Temporal *temp2, Datum param, varfunc func, int numparam)
Generic spatial relationship for the trajectory or traversed area of two temporal geometries.
Definition: tgeo_spatialrels.c:380
Datum datum_geom_intersects3d(Datum geom1, Datum geom2)
Return a Datum true if two geometries intersect in 3D.
Definition: tgeo_spatialrels.c:131
Datum datum_geom_dwithin3d(Datum geom1, Datum geom2, Datum dist)
Return a Datum true if two 3D geometries are within a distance.
Definition: tgeo_spatialrels.c:161
int ea_touches_tpoint_geo(const Temporal *temp, const GSERIALIZED *gs, bool ever)
Return 1 if a temporal point ever/always touches a geometry, 0 if not, and -1 on error or if the geom...
Definition: tgeo_spatialrels.c:1213
int ea_dwithin_tgeo_tgeo(const Temporal *temp1, const Temporal *temp2, double dist, bool ever)
Return 1 if two temporal geos are ever/always within a distance, 0 if not, -1 on error or if the temp...
Definition: tgeo_spatialrels.c:1675
Datum datum_geom_contains(Datum geom1, Datum geom2)
Return a Datum true if the first geometry covers the second one.
Definition: tgeo_spatialrels.c:71
datum_func2 geo_disjoint_fn(int16 flags1, int16 flags2)
Select the appropriate disjoint function depending on the flags.
Definition: tgeo_spatialrels.c:204
Datum datum_geog_intersects(Datum geog1, Datum geog2)
Return a Datum true if two geographies intersect.
Definition: tgeo_spatialrels.c:141
datum_func3 geo_dwithin_fn(int16 flags1, int16 flags2)
Select the appropriate dwithin function depending on the flags.
Definition: tgeo_spatialrels.c:264
int ea_spatialrel_tspatial_tspatial(const Temporal *temp1, const Temporal *temp2, datum_func2 func, bool ever)
Return true if two temporal geometries ever/always satisfy a spatial relationship.
Definition: tgeo_spatialrels.c:494
Datum datum_geog_disjoint(Datum geog1, Datum geog2)
Return a Datum true if two geographies are disjoint.
Definition: tgeo_spatialrels.c:111
datum_func2 geo_intersects_fn_geo(int16 flags1, uint8_t flags2)
Select the appropriate intersects function depending on the flags.
Definition: tgeo_spatialrels.c:249
datum_func2 geo_disjoint_fn_geo(int16 flags1, uint8_t flags2)
Select the appropriate disjoint function depending on the flags.
Definition: tgeo_spatialrels.c:219
Datum datum_geog_dwithin(Datum geog1, Datum geog2, Datum dist)
Return a Datum true if two geographies are within a distance.
Definition: tgeo_spatialrels.c:171
Datum datum_geom_disjoint3d(Datum geom1, Datum geom2)
Return a Datum true if two geometries are disjoint in 3D.
Definition: tgeo_spatialrels.c:101
datum_func2 geo_intersects_fn(int16 flags1, int16 flags2)
Select the appropriate intersects function depending on the flags.
Definition: tgeo_spatialrels.c:234
int const GSERIALIZED * gs
Definition: trgeo_spatialrels.h:52
int const GSERIALIZED bool ever
Definition: trgeo_spatialrels.h:53