MobilityDB 1.3
Loading...
Searching...
No Matches
meos_pose.h
Go to the documentation of this file.
1/*****************************************************************************
2 *
3 * This MobilityDB code is provided under The PostgreSQL License.
4 * Copyright (c) 2016-2025, Université libre de Bruxelles and MobilityDB
5 * contributors
6 *
7 * MobilityDB includes portions of PostGIS version 3 source code released
8 * under the GNU General Public License (GPLv2 or later).
9 * Copyright (c) 2001-2025, PostGIS contributors
10 *
11 * Permission to use, copy, modify, and distribute this software and its
12 * documentation for any purpose, without fee, and without a written
13 * agreement is hereby granted, provided that the above copyright notice and
14 * this paragraph and the following two paragraphs appear in all copies.
15 *
16 * IN NO EVENT SHALL UNIVERSITE LIBRE DE BRUXELLES BE LIABLE TO ANY PARTY FOR
17 * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, INCLUDING
18 * LOST PROFITS, ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION,
19 * EVEN IF UNIVERSITE LIBRE DE BRUXELLES HAS BEEN ADVISED OF THE POSSIBILITY
20 * OF SUCH DAMAGE.
21 *
22 * UNIVERSITE LIBRE DE BRUXELLES SPECIFICALLY DISCLAIMS ANY WARRANTIES,
23 * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
24 * AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON
25 * AN "AS IS" BASIS, AND UNIVERSITE LIBRE DE BRUXELLES HAS NO OBLIGATIONS TO
26 * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
27 *
28 *****************************************************************************/
29
34#ifndef __MEOS_POSE_H__
35#define __MEOS_POSE_H__
36
37/* C */
38#include <stdbool.h>
39#include <stdint.h>
40/* MEOS */
41#include <meos.h>
42#include <meos_internal_geo.h>
43#include "temporal/set.h"
44
45/*****************************************************************************
46 * Struct definitions
47 *****************************************************************************/
48
52typedef struct Pose Pose;
53
54/*****************************************************************************
55 * Validity macros
56 *****************************************************************************/
57
61#if MEOS
62 #define VALIDATE_POSESET(set, ret) \
63 do { \
64 if (! ensure_not_null((void *) set) || \
65 ! ensure_set_isof_type((set), T_POSESET) ) \
66 return (ret); \
67 } while (0)
68#else
69 #define VALIDATE_POSESET(set, ret) \
70 do { \
71 assert(set); \
72 assert((set)->settype == T_POSESET); \
73 } while (0)
74#endif
75
82#if MEOS
83 #define VALIDATE_TPOSE(temp, ret) \
84 do { \
85 if (! ensure_not_null((void *) (temp)) || \
86 ! ensure_temporal_isof_type((Temporal *) (temp), T_TPOSE) ) \
87 return (ret); \
88 } while (0)
89#else
90 #define VALIDATE_TPOSE(temp, ret) \
91 do { \
92 assert(temp); \
93 assert(((Temporal *) (temp))->temptype == T_TPOSE); \
94 } while (0)
95#endif
96
97/******************************************************************************
98 * Functions for poses
99 ******************************************************************************/
100
101/* Input and output functions */
102
103extern char *pose_as_ewkt(const Pose *pose, int maxdd);
104extern char *pose_as_hexwkb(const Pose *pose, uint8_t variant, size_t *size);
105extern char *pose_as_text(const Pose *pose, int maxdd);
106extern uint8_t *pose_as_wkb(const Pose *pose, uint8_t variant, size_t *size_out);
107extern Pose *pose_from_wkb(const uint8_t *wkb, size_t size);
108extern Pose *pose_from_hexwkb(const char *hexwkb);
109extern Pose *pose_in(const char *str);
110extern char *pose_out(const Pose *pose, int maxdd);
111
112/* Constructor functions */
113
114extern Pose *pose_copy(const Pose *pose);
115extern Pose *pose_make_2d(double x, double y, double theta, int32_t srid);
116extern Pose *pose_make_3d(double x, double y, double z, double W, double X, double Y, double Z, int32_t srid);
117extern Pose *pose_make_point2d(const GSERIALIZED *gs, double theta);
118extern Pose *pose_make_point3d(const GSERIALIZED *gs, double W, double X, double Y, double Z);
119
120/* Conversion functions */
121
122extern GSERIALIZED *pose_to_point(const Pose *pose);
123extern STBox *pose_to_stbox(const Pose *pose);
124
125/* Accessor functions */
126
127extern uint32 pose_hash(const Pose *pose);
128extern uint64 pose_hash_extended(const Pose *pose, uint64 seed);
129extern double *pose_orientation(const Pose *pose);
130extern double pose_rotation(const Pose *pose);
131
132/* Transformation functions */
133
134extern Pose *pose_round(const Pose *pose, int maxdd);
135extern Pose **posearr_round(const Pose **posearr, int count, int maxdd);
136
137/* Spatial reference system functions */
138
139extern void pose_set_srid(Pose *pose, int32_t srid);
140extern int32_t pose_srid(const Pose *pose);
141extern Pose *pose_transform(const Pose *pose, int32_t srid);
142extern Pose *pose_transform_pipeline(const Pose *pose, const char *pipelinestr, int32_t srid, bool is_forward);
143
144/* Bounding box functions */
145
146extern STBox *pose_tstzspan_to_stbox(const Pose *pose, const Span *s);
147extern STBox *pose_timestamptz_to_stbox(const Pose *pose, TimestampTz t);
148
149/* Distance functions */
150
151extern double distance_pose_geo(const Pose *pose, const GSERIALIZED *gs);
152extern double distance_pose_pose(const Pose *pose1, const Pose *pose2);
153extern double distance_pose_stbox(const Pose *pose, const STBox *box);
154
155/* Comparison functions */
156
157extern int pose_cmp(const Pose *pose1, const Pose *pose2);
158extern bool pose_eq(const Pose *pose1, const Pose *pose2);
159extern bool pose_ge(const Pose *pose1, const Pose *pose2);
160extern bool pose_gt(const Pose *pose1, const Pose *pose2);
161extern bool pose_le(const Pose *pose1, const Pose *pose2);
162extern bool pose_lt(const Pose *pose1, const Pose *pose2);
163extern bool pose_ne(const Pose *pose1, const Pose *pose2);
164extern bool pose_nsame(const Pose *pose1, const Pose *pose2);
165extern bool pose_same(const Pose *pose1, const Pose *pose2);
166
167/******************************************************************************
168 * Functions for pose sets
169 ******************************************************************************/
170
171/* Input and output functions */
172
173extern Set *poseset_in(const char *str);
174extern char *poseset_out(const Set *s, int maxdd);
175
176/* Constructor functions */
177
178extern Set *poseset_make(const Pose **values, int count);
179
180/* Conversion functions */
181
182extern Set *pose_to_set(const Pose *pose);
183
184/* Accessor functions */
185
186extern Pose *poseset_end_value(const Set *s);
187extern Pose *poseset_start_value(const Set *s);
188extern bool poseset_value_n(const Set *s, int n, Pose **result);
189extern Pose **poseset_values(const Set *s);
190
191/* Set operations */
192
193extern bool contained_pose_set(const Pose *pose, const Set *s);
194extern bool contains_set_pose(const Set *s, Pose *pose);
195extern Set *intersection_pose_set(const Pose *pose, const Set *s);
196extern Set *intersection_set_pose(const Set *s, const Pose *pose);
197extern Set *minus_pose_set(const Pose *pose, const Set *s);
198extern Set *minus_set_pose(const Set *s, const Pose *pose);
199extern Set *pose_union_transfn(Set *state, const Pose *pose);
200extern Set *union_pose_set(const Pose *pose, const Set *s);
201extern Set *union_set_pose(const Set *s, const Pose *pose);
202
203/*===========================================================================*
204 * Functions for temporal poses
205 *===========================================================================*/
206
207/*****************************************************************************
208 * Input/output functions
209 *****************************************************************************/
210
211Temporal *tpose_in(const char *str);
212
213/*****************************************************************************
214 * Constructor functions
215 *****************************************************************************/
216
217
218/*****************************************************************************
219 * Conversion functions
220 *****************************************************************************/
221
222extern Temporal *tpoint_tfloat_to_tpose(const Temporal *tpoint, const Temporal *tradius);
223extern Temporal *tpose_to_tpoint(const Temporal *temp);
224
225/*****************************************************************************
226 * Accessor functions
227 *****************************************************************************/
228
229extern Pose *tpose_end_value(const Temporal *temp);
230extern Set *tpose_points(const Temporal *temp);
231// extern Temporal *tpose_orientation(const Temporal *temp);
232extern Temporal *tpose_rotation(const Temporal *temp);
233extern Pose *tpose_start_value(const Temporal *temp);
234extern GSERIALIZED *tpose_trajectory(const Temporal *temp);
235extern bool tpose_value_at_timestamptz(const Temporal *temp, TimestampTz t, bool strict, Pose **value);
236extern bool tpose_value_n(const Temporal *temp, int n, Pose **result);
237extern Pose **tpose_values(const Temporal *temp, int *count);
238
239/*****************************************************************************
240 * Restriction functions
241 *****************************************************************************/
242
243extern Temporal *tpose_at_geom(const Temporal *temp, const GSERIALIZED *gs, const Span *zspan);
244extern Temporal *tpose_at_stbox(const Temporal *temp, const STBox *box, bool border_inc);
245extern Temporal *tpose_at_pose(const Temporal *temp, const Pose *pose);
246extern Temporal *tpose_minus_geom(const Temporal *temp, const GSERIALIZED *gs, const Span *zspan);
247extern Temporal *tpose_minus_pose(const Temporal *temp, const Pose *pose);
248extern Temporal *tpose_minus_stbox(const Temporal *temp, const STBox *box, bool border_inc);
249
250/*****************************************************************************
251 * Distance functions
252 *****************************************************************************/
253
254extern Temporal *distance_tpose_pose(const Temporal *temp, const Pose *pose);
255extern Temporal *distance_tpose_point(const Temporal *temp, const GSERIALIZED *gs);
256extern Temporal *distance_tpose_tpose(const Temporal *temp1, const Temporal *temp2);
257extern double nad_tpose_geo(const Temporal *temp, const GSERIALIZED *gs);
258extern double nad_tpose_pose(const Temporal *temp, const Pose *pose);
259extern double nad_tpose_stbox(const Temporal *temp, const STBox *box);
260extern double nad_tpose_tpose(const Temporal *temp1, const Temporal *temp2);
261extern TInstant *nai_tpose_geo(const Temporal *temp, const GSERIALIZED *gs);
262extern TInstant *nai_tpose_pose(const Temporal *temp, const Pose *pose);
263extern TInstant *nai_tpose_tpose(const Temporal *temp1, const Temporal *temp2);
264extern GSERIALIZED *shortestline_tpose_geo(const Temporal *temp, const GSERIALIZED *gs);
265extern GSERIALIZED *shortestline_tpose_pose(const Temporal *temp, const Pose *pose);
266extern GSERIALIZED *shortestline_tpose_tpose(const Temporal *temp1, const Temporal *temp2);
267
268/*****************************************************************************
269 * Comparison functions
270 *****************************************************************************/
271
272/* Ever/always and temporal comparison functions */
273
274extern int always_eq_pose_tpose(const Pose *pose, const Temporal *temp);
275extern int always_eq_tpose_pose(const Temporal *temp, const Pose *pose);
276extern int always_eq_tpose_tpose(const Temporal *temp1, const Temporal *temp2);
277extern int always_ne_pose_tpose(const Pose *pose, const Temporal *temp);
278extern int always_ne_tpose_pose(const Temporal *temp, const Pose *pose);
279extern int always_ne_tpose_tpose(const Temporal *temp1, const Temporal *temp2);
280extern int ever_eq_pose_tpose(const Pose *pose, const Temporal *temp);
281extern int ever_eq_tpose_pose(const Temporal *temp, const Pose *pose);
282extern int ever_eq_tpose_tpose(const Temporal *temp1, const Temporal *temp2);
283extern int ever_ne_pose_tpose(const Pose *pose, const Temporal *temp);
284extern int ever_ne_tpose_pose(const Temporal *temp, const Pose *pose);
285extern int ever_ne_tpose_tpose(const Temporal *temp1, const Temporal *temp2);
286
287/*****************************************************************************/
288
289extern Temporal *teq_pose_tpose(const Pose *pose, const Temporal *temp);
290extern Temporal *teq_tpose_pose(const Temporal *temp, const Pose *pose);
291extern Temporal *tne_pose_tpose(const Pose *pose, const Temporal *temp);
292extern Temporal *tne_tpose_pose(const Temporal *temp, const Pose *pose);
293
294/*****************************************************************************/
295
296/* Ever and always spatial relationship functions */
297
298
299/*****************************************************************************/
300
301/* Spatiotemporal relationship functions */
302
303
304/*****************************************************************************/
305
306#endif /* __MEOS_POSE_H__ */
double nad_tpose_stbox(const Temporal *temp, const STBox *box)
Return the nearest approach distance of a temporal pose and a spatiotemporal box.
Definition: tpose_distance.c:225
GSERIALIZED * tpose_trajectory(const Temporal *temp)
Return the trajectory of a temporal pose.
Definition: tpose_spatialfuncs.c:61
Set * tpose_points(const Temporal *temp)
Return the array of points of a temporal pose @csqlfn Tpose_points()
Definition: tpose.c:610
Temporal * tpose_rotation(const Temporal *temp)
Return a the rotation of a temporal pose as a temporal float.
Definition: tpose.c:460
Pose * tpose_start_value(const Temporal *temp)
Return a copy of the start value of a temporal pose.
Definition: tpose.c:488
Pose ** tpose_values(const Temporal *temp, int *count)
Return the array of copies of base values of a temporal pose.
Definition: tpose.c:538
bool tpose_value_n(const Temporal *temp, int n, Pose **result)
Return a copy of the n-th value of a temporal pose.
Definition: tpose.c:519
Pose * tpose_end_value(const Temporal *temp)
Return a copy of the end value of a temporal pose.
Definition: tpose.c:503
bool tpose_value_at_timestamptz(const Temporal *temp, TimestampTz t, bool strict, Pose **value)
Return the value of a temporal pose at a timestamptz.
Definition: tpose.c:639
uint32 pose_hash(const Pose *pose)
Return the 32-bit hash value of a pose.
Definition: pose.c:1426
double pose_rotation(const Pose *pose)
Return the rotation of a 2D pose.
Definition: pose.c:890
uint64 pose_hash_extended(const Pose *pose, uint64 seed)
Return the 64-bit hash value of a pose using a seed.
Definition: pose.c:1463
double * pose_orientation(const Pose *pose)
Return the orientation of a 3D pose.
Definition: pose.c:916
STBox * pose_tstzspan_to_stbox(const Pose *pose, const Span *s)
Return a spatiotemporal box constructed from a pose and a timestamptz.
Definition: tpose_boxops.c:249
STBox * pose_timestamptz_to_stbox(const Pose *pose, TimestampTz t)
Return a spatiotemporal box constructed from a pose and a timestamptz.
Definition: tpose_boxops.c:212
bool pose_eq(const Pose *pose1, const Pose *pose2)
Return true if the first pose is equal to the second one.
Definition: pose.c:1256
int pose_cmp(const Pose *pose1, const Pose *pose2)
Return -1, 0, or 1 depending on whether the first pose is less than, equal to, or greater than the se...
Definition: pose.c:1337
bool pose_ge(const Pose *pose1, const Pose *pose2)
Return true if the first pose is greater than or equal to the second one.
Definition: pose.c:1402
bool pose_nsame(const Pose *pose1, const Pose *pose2)
Return true if the first pose is not equal to the second one.
Definition: pose.c:1325
bool pose_le(const Pose *pose1, const Pose *pose2)
Return true if the first pose is less than or equal to the second one.
Definition: pose.c:1379
bool pose_lt(const Pose *pose1, const Pose *pose2)
Return true if the first pose is less than the second one.
Definition: pose.c:1368
bool pose_ne(const Pose *pose1, const Pose *pose2)
Return true if the first pose is not equal to the second one.
Definition: pose.c:1285
bool pose_gt(const Pose *pose1, const Pose *pose2)
Return true if the first pose is greater than the second one.
Definition: pose.c:1390
bool pose_same(const Pose *pose1, const Pose *pose2)
Return true if the first pose is equal to the second one.
Definition: pose.c:1296
Pose * pose_copy(const Pose *pose)
Copy a pose value.
Definition: pose.c:802
Pose * pose_make_2d(double x, double y, double theta, int32_t srid)
Construct a 2D pose value from the arguments.
Definition: pose.c:660
Pose * pose_make_point2d(const GSERIALIZED *gs, double theta)
Construct a 2D pose value from a 2D point and a rotation angle.
Definition: pose.c:688
Pose * pose_make_3d(double x, double y, double z, double W, double X, double Y, double Z, int32_t srid)
Construct a 3D pose value from the arguments.
Definition: pose.c:722
Pose * pose_make_point3d(const GSERIALIZED *gs, double W, double X, double Y, double Z)
Construct a 3D pose value from the arguments.
Definition: pose.c:760
GSERIALIZED * pose_to_point(const Pose *pose)
Convert a pose into a geometry point.
Definition: pose.c:821
STBox * pose_to_stbox(const Pose *pose)
Convert a pose into a spatiotemporal box.
Definition: tpose_boxops.c:102
char * pose_as_ewkt(const Pose *pose, int maxdd)
Return the Extended Well-Known Text (EWKT) representation of a pose.
Definition: pose.c:571
Pose * pose_from_hexwkb(const char *hexwkb)
Return a pose from its ASCII hex-encoded Well-Known Binary (WKB) representation.
Definition: pose.c:604
char * pose_as_hexwkb(const Pose *pose, uint8_t variant, size_t *size)
Return the ASCII hex-encoded Well-Known Binary (HexWKB) representation of a pose.
Definition: pose.c:640
char * pose_out(const Pose *pose, int maxdd)
Return the string representation of a pose.
Definition: pose.c:460
char * pose_as_text(const Pose *pose, int maxdd)
Return the Well-Known Text (WKT) representation of a pose.
Definition: pose.c:558
uint8_t * pose_as_wkb(const Pose *pose, uint8_t variant, size_t *size_out)
Return the Well-Known Binary (WKB) representation of a pose.
Definition: pose.c:623
Pose * pose_from_wkb(const uint8_t *wkb, size_t size)
Return a pose from its Well-Known Binary (WKB) representation.
Definition: pose.c:589
Pose * pose_in(const char *str)
Return a pose from its string representation.
Definition: pose.c:444
Pose * pose_transform(const Pose *pose, int32_t srid)
Return a pose transformed to another SRID.
Definition: pose.c:1104
int32_t pose_srid(const Pose *pose)
Return the SRID.
Definition: pose.c:1019
Pose * pose_transform_pipeline(const Pose *pose, const char *pipelinestr, int32_t srid, bool is_forward)
Return a pose transformed to another SRID using a pipeline.
Definition: pose.c:1136
void pose_set_srid(Pose *pose, int32_t srid)
Set the SRID.
Definition: pose.c:1046
Pose ** posearr_round(const Pose **posearr, int count, int maxdd)
Return an array of poses with the precision of the vales set to a number of decimal places.
Definition: pose.c:996
Pose * pose_round(const Pose *pose, int maxdd)
Return a pose with the precision of the values set to a number of decimal places.
Definition: pose.c:944
int always_eq_tpose_pose(const Temporal *temp, const Pose *pose)
Return true if a temporal pose is always equal to a pose.
Definition: tpose_compops.c:169
int ever_eq_tpose_pose(const Temporal *temp, const Pose *pose)
Return true if a temporal pose is ever equal to a circular buffer.
Definition: tpose_compops.c:115
int ever_ne_pose_tpose(const Pose *pose, const Temporal *temp)
Return true if a pose is ever different from a temporal pose.
Definition: tpose_compops.c:128
int ever_eq_tpose_tpose(const Temporal *temp1, const Temporal *temp2)
Return true if two temporal poses are ever equal.
Definition: tpose_compops.c:210
int always_eq_tpose_tpose(const Temporal *temp1, const Temporal *temp2)
Return true if two temporal poses are always equal.
Definition: tpose_compops.c:234
int always_ne_tpose_pose(const Temporal *temp, const Pose *pose)
Return true if a temporal pose is always different from a pose.
Definition: tpose_compops.c:196
int always_ne_pose_tpose(const Pose *pose, const Temporal *temp)
Return true if a pose is always different from a temporal pose.
Definition: tpose_compops.c:182
int always_eq_pose_tpose(const Pose *pose, const Temporal *temp)
Return true if a pose is always equal to a temporal pose.
Definition: tpose_compops.c:155
int ever_eq_pose_tpose(const Pose *pose, const Temporal *temp)
Return true if a pose is ever equal to a temporal circular buffer.
Definition: tpose_compops.c:101
int always_ne_tpose_tpose(const Temporal *temp1, const Temporal *temp2)
Return true if two temporal poses are always different.
Definition: tpose_compops.c:246
int ever_ne_tpose_pose(const Temporal *temp, const Pose *pose)
Return true if a temporal pose is ever different from a pose.
Definition: tpose_compops.c:142
int ever_ne_tpose_tpose(const Temporal *temp1, const Temporal *temp2)
Return true if two temporal poses are ever different.
Definition: tpose_compops.c:222
Temporal * tne_tpose_pose(const Temporal *temp, const Pose *pose)
Return the temporal inequality of a temporal pose and a pose.
Definition: tpose_compops.c:345
Temporal * teq_tpose_pose(const Temporal *temp, const Pose *pose)
Return the temporal equality of a temporal pose and a pose.
Definition: tpose_compops.c:331
Temporal * tne_pose_tpose(const Pose *pose, const Temporal *temp)
Return the temporal inequality of a pose and a temporal pose.
Definition: tpose_compops.c:315
Temporal * teq_pose_tpose(const Pose *pose, const Temporal *temp)
Return the temporal equality of a pose and a temporal pose.
Definition: tpose_compops.c:302
Temporal * tpoint_tfloat_to_tpose(const Temporal *tpoint, const Temporal *tradius)
Return a temporal pose from a temporal point and a temporal float.
Definition: tpose.c:390
Temporal * tpose_to_tpoint(const Temporal *temp)
Return a geometry point from a temporal pose.
Definition: tpose.c:435
GSERIALIZED * shortestline_tpose_tpose(const Temporal *temp1, const Temporal *temp2)
Return the line connecting the nearest approach point between two temporal networks.
Definition: tpose_distance.c:334
GSERIALIZED * shortestline_tpose_pose(const Temporal *temp, const Pose *pose)
Return the line connecting the nearest approach point between a pose and a temporal pose.
Definition: tpose_distance.c:313
double nad_tpose_tpose(const Temporal *temp1, const Temporal *temp2)
Return the nearest approach distance of two temporal poses.
Definition: tpose_distance.c:267
Temporal * distance_tpose_point(const Temporal *temp, const GSERIALIZED *gs)
Return the temporal distance between a geometry and a temporal pose.
Definition: tpose_distance.c:57
double nad_tpose_geo(const Temporal *temp, const GSERIALIZED *gs)
Return the nearest approach distance of two temporal pose and a geometry.
Definition: tpose_distance.c:204
TInstant * nai_tpose_pose(const Temporal *temp, const Pose *pose)
Return the nearest approach instant of a pose and a temporal pose.
Definition: tpose_distance.c:148
Temporal * distance_tpose_tpose(const Temporal *temp1, const Temporal *temp2)
Return the temporal distance between two temporal poses.
Definition: tpose_distance.c:97
Temporal * distance_tpose_pose(const Temporal *temp, const Pose *pose)
Return the temporal distance between a temporal pose and a pose.
Definition: tpose_distance.c:77
GSERIALIZED * shortestline_tpose_geo(const Temporal *temp, const GSERIALIZED *gs)
Return the line connecting the nearest approach point between a geometry and a temporal pose.
Definition: tpose_distance.c:292
TInstant * nai_tpose_tpose(const Temporal *temp1, const Temporal *temp2)
Return the nearest approach instant of two temporal poses.
Definition: tpose_distance.c:173
TInstant * nai_tpose_geo(const Temporal *temp, const GSERIALIZED *gs)
Return the nearest approach instant of the temporal pose and a geometry.
Definition: tpose_distance.c:123
double nad_tpose_pose(const Temporal *temp, const Pose *pose)
Return the nearest approach distance of a temporal pose and a pose.
Definition: tpose_distance.c:247
Temporal * tpose_in(const char *str)
Return a temporal pose from its Well-Known Text (WKT) representation.
Definition: tpose.c:211
Temporal * tpose_minus_pose(const Temporal *temp, const Pose *pose)
Return a temporal pose restricted to the complement of a pose.
Definition: tpose.c:681
Temporal * tpose_minus_geom(const Temporal *temp, const GSERIALIZED *gs, const Span *zspan)
Return a temporal point restricted to (the complement of) a geometry.
Definition: tpose_spatialfuncs.c:131
Temporal * tpose_at_stbox(const Temporal *temp, const STBox *box, bool border_inc)
Return a temporal pose restricted to a geometry.
Definition: tpose_spatialfuncs.c:183
Temporal * tpose_minus_stbox(const Temporal *temp, const STBox *box, bool border_inc)
Return a temporal point restricted to (the complement of) a geometry.
Definition: tpose_spatialfuncs.c:197
Temporal * tpose_at_geom(const Temporal *temp, const GSERIALIZED *gs, const Span *zspan)
Return a temporal pose restricted to a geometry.
Definition: tpose_spatialfuncs.c:116
Temporal * tpose_at_pose(const Temporal *temp, const Pose *pose)
Return a temporal pose restricted to a pose.
Definition: tpose.c:665
Pose * poseset_start_value(const Set *s)
Return a copy of the start value of a pose set.
Definition: poseset_meos.c:152
Pose * poseset_end_value(const Set *s)
Return a copy of the end value of a pose set.
Definition: poseset_meos.c:167
Pose ** poseset_values(const Set *s)
Return the array of copies of the values of a pose set.
Definition: poseset_meos.c:203
bool poseset_value_n(const Set *s, int n, Pose **result)
Return in the last argument a copy of the n-th value of a circular buffer set.
Definition: poseset_meos.c:185
Set * poseset_make(const Pose **values, int count)
Return a pose set from an array of values.
Definition: poseset_meos.c:108
Set * pose_to_set(const Pose *pose)
Convert a pose into a pose set.
Definition: poseset_meos.c:132
char * poseset_out(const Set *s, int maxdd)
Return the string representation of a pose set.
Definition: poseset_meos.c:89
Set * poseset_in(const char *str)
Return a set from its Well-Known Text (WKT) representation.
Definition: poseset_meos.c:74
Set * pose_union_transfn(Set *state, const Pose *pose)
Transition function for set union aggregate of poses.
Definition: poseset_meos.c:364
Set * minus_set_pose(const Set *s, const Pose *pose)
Return the difference of a set and a pose.
Definition: poseset_meos.c:345
Set * union_set_pose(const Set *s, const Pose *pose)
Return the union of a set and a pose.
Definition: poseset_meos.c:271
Set * union_pose_set(const Pose *pose, const Set *s)
Return the union of a pose and a set.
Definition: poseset_meos.c:287
Set * minus_pose_set(const Pose *pose, const Set *s)
Return the difference of a pose and a set.
Definition: poseset_meos.c:329
Set * intersection_set_pose(const Set *s, const Pose *pose)
Return the intersection of a set and a pose.
Definition: poseset_meos.c:300
bool contains_set_pose(const Set *s, Pose *pose)
Return true if a set contains a pose.
Definition: poseset_meos.c:239
bool contained_pose_set(const Pose *pose, const Set *s)
Return true if a pose is contained in a set.
Definition: poseset_meos.c:255
Set * intersection_pose_set(const Pose *pose, const Set *s)
Return the intersection of a pose and a set.
Definition: poseset_meos.c:316
External API of the Mobility Engine Open Source (MEOS) library.
double distance_pose_pose(const Pose *pose1, const Pose *pose2)
Return the distance between two poses.
Definition: pose.c:1181
double distance_pose_stbox(const Pose *pose, const STBox *box)
Return the distance between a pose and a spatiotemporal box.
Definition: pose.c:1232
double distance_pose_geo(const Pose *pose, const GSERIALIZED *gs)
Return the distance between a pose and a geometry.
Definition: pose.c:1212
int64 TimestampTz
Definition: postgres_ext_defs.in.h:22
unsigned int uint32
Definition: postgres_ext_defs.in.h:16
unsigned long int uint64
Definition: postgres_ext_defs.in.h:17
Definition: postgis_ext_defs.in.h:170
uint8_t srid[3]
srid
Definition: pose.h:59
Basic functions for static pose objects.
Definition: pose.h:56
Structure to represent spatiotemporal boxes.
Definition: meos.h:134
Structure to represent sets of values.
Definition: meos.h:80
Structure to represent spans (a.k.a.
Definition: meos.h:94
Structure to represent temporal values of instant subtype.
Definition: meos.h:185
Structure to represent the common structure of temporal values of any temporal subtype.
Definition: meos.h:173
Definition: pgtz.h:42
int const GSERIALIZED * gs
Definition: trgeo_spatialrels.h:52