PostGIS  2.5.7dev-r@@SVN_REVISION@@
lwgeom_rtree.h
Go to the documentation of this file.
1 /**********************************************************************
2  *
3  * PostGIS - Spatial Types for PostgreSQL
4  * http://postgis.net
5  *
6  * PostGIS is free software: you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation, either version 2 of the License, or
9  * (at your option) any later version.
10  *
11  * PostGIS is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with PostGIS. If not, see <http://www.gnu.org/licenses/>.
18  *
19  **********************************************************************
20  *
21  * ^copyright^
22  *
23  **********************************************************************/
24 
25 #ifndef _LWGEOM_RTREE_H
26 #define _LWGEOM_RTREE_H 1
27 
28 #include "liblwgeom.h"
29 #include "lwgeom_cache.h"
30 
34 typedef struct
35 {
36  double min;
37  double max;
38 }
40 
46 typedef struct rtree_node
47 {
52 }
54 
58 typedef struct
59 {
61  int* ringCounts;
62  int polyCount;
64 
65 
66 typedef struct
67 {
68  GeomCache gcache;
71 
76 
77 
83 RTREE_POLY_CACHE *GetRtreeCache(FunctionCallInfo fcinfo, GSERIALIZED *g1);
84 
85 #endif /* !defined _LWGEOM_RTREE_H */
This library is the generic geometry handling section of PostGIS.
LWMLINE * RTreeFindLineSegments(RTREE_NODE *root, double value)
Retrieves a collection of line segments given the root and crossing value.
Definition: lwgeom_rtree.c:450
struct rtree_node RTREE_NODE
The following struct and methods are used for a 1D RTree implementation, described at: http://lin-ear...
RTREE_POLY_CACHE * GetRtreeCache(FunctionCallInfo fcinfo, GSERIALIZED *g1)
Checks for a cache hit against the provided geometry and returns a pre-built index structure (RTREE_P...
Definition: lwgeom_rtree.c:432
int value
Definition: genraster.py:61
Representation for the y-axis interval spanned by an edge.
Definition: lwgeom_rtree.h:35
RTREE_NODE ** ringIndices
Definition: lwgeom_rtree.h:60
The tree structure used for fast P-i-P tests by point_in_multipolygon_rtree()
Definition: lwgeom_rtree.h:59
GeomCache gcache
Definition: lwgeom_rtree.h:68
RTREE_POLY_CACHE * index
Definition: lwgeom_rtree.h:69
struct rtree_node * leftNode
Definition: lwgeom_rtree.h:49
struct rtree_node * rightNode
Definition: lwgeom_rtree.h:50
LWLINE * segment
Definition: lwgeom_rtree.h:51
RTREE_INTERVAL * interval
Definition: lwgeom_rtree.h:48
The following struct and methods are used for a 1D RTree implementation, described at: http://lin-ear...
Definition: lwgeom_rtree.h:47