4 ** The author disclaims copyright to this source code. In place of
5 ** a legal notice, here is a blessing:
7 ** May you do good and not evil.
8 ** May you find forgiveness for yourself and forgive others.
9 ** May you share freely, never taking more than you give.
11 *************************************************************************
14 #ifndef _SQLITE3RTREE_H_
15 #define _SQLITE3RTREE_H_
23 typedef struct sqlite3_rtree_geometry sqlite3_rtree_geometry
;
26 ** Register a geometry callback named zGeom that can be used as part of an
27 ** R-Tree geometry query as follows:
29 ** SELECT ... FROM <rtree> WHERE <rtree col> MATCH $zGeom(... params ...)
31 int sqlite3_rtree_geometry_callback(
34 int (*xGeom
)(sqlite3_rtree_geometry
*, int nCoord
, double *aCoord
, int *pRes
),
40 ** A pointer to a structure of the following type is passed as the first
41 ** argument to callbacks registered using rtree_geometry_callback().
43 struct sqlite3_rtree_geometry
{
44 void *pContext
; /* Copy of pContext passed to s_r_g_c() */
45 int nParam
; /* Size of array aParam[] */
46 double *aParam
; /* Parameters passed to SQL geom function */
47 void *pUser
; /* Callback implementation user data */
48 void (*xDelUser
)(void *); /* Called by SQLite to clean up pUser */
53 } /* end of the 'extern "C"' block */
56 #endif /* ifndef _SQLITE3RTREE_H_ */