postgis/lwgeom
2008-10-03 18:07:18 +00:00
..
.cvsignore jdbc2 works: 2005-04-15 14:04:34 +00:00
BBOXCACHE_BEHAVIOURS added snaptogrid behavior 2006-02-06 11:09:02 +00:00
compat.h Estrapolated SERIALIZED_FORM doc from liblwgeom.h and put it into 2005-11-28 15:06:06 +00:00
DEBUG Provide a new text file called DEBUG explaining how to use the new debug system. 2008-05-31 10:35:04 +00:00
long_xact.c Commit new PostGIS debugging infrastructure. These changes unify all the debug logging to use a new set of macros: LWDEBUG()/LWDEBUGF() for LWGEOM functions, and POSTGIS_DEBUG()/POSTGIS_DEBUGF() for PostgreSQL functions. To enable debugging, run configure with --enable-debug and then remake the entire project. If --enable-debug is omitted during configure, the above macros evaluate to (void)0, and hence should be removed by the compiler during optimisation. Also: contains minor warning cleanups and a fix for the ST_Dwithin SQL definition. 2008-05-31 09:56:44 +00:00
long_xact.sql.in Switch all SQL and PL/PGSQL stored procedures over to use dollar quoting instead of apostrophes for function bodies. At last, most of the stored procedures actually become readable 2008-06-05 12:09:48 +00:00
lwgeom_box.c Since PGXS compiles libraries with -Wall, attempt to remove as many warnings as possible. Most of these are missing function prototypes at the top of each file. 2008-05-22 20:43:00 +00:00
lwgeom_box2dfloat4.c Commit new PostGIS debugging infrastructure. These changes unify all the debug logging to use a new set of macros: LWDEBUG()/LWDEBUGF() for LWGEOM functions, and POSTGIS_DEBUG()/POSTGIS_DEBUGF() for PostgreSQL functions. To enable debugging, run configure with --enable-debug and then remake the entire project. If --enable-debug is omitted during configure, the above macros evaluate to (void)0, and hence should be removed by the compiler during optimisation. Also: contains minor warning cleanups and a fix for the ST_Dwithin SQL definition. 2008-05-31 09:56:44 +00:00
lwgeom_box3d.c Commit new PostGIS debugging infrastructure. These changes unify all the debug logging to use a new set of macros: LWDEBUG()/LWDEBUGF() for LWGEOM functions, and POSTGIS_DEBUG()/POSTGIS_DEBUGF() for PostgreSQL functions. To enable debugging, run configure with --enable-debug and then remake the entire project. If --enable-debug is omitted during configure, the above macros evaluate to (void)0, and hence should be removed by the compiler during optimisation. Also: contains minor warning cleanups and a fix for the ST_Dwithin SQL definition. 2008-05-31 09:56:44 +00:00
lwgeom_btree.c Blast away the huge amounts of legacy C code related to PostgreSQL versions < 8.1. Next step will be to work on the SQL script files too. 2008-06-05 10:19:01 +00:00
lwgeom_chip.c Since PGXS compiles libraries with -Wall, attempt to remove as many warnings as possible. Most of these are missing function prototypes at the top of each file. 2008-05-22 20:43:00 +00:00
lwgeom_debug.c Commit new PostGIS debugging infrastructure. These changes unify all the debug logging to use a new set of macros: LWDEBUG()/LWDEBUGF() for LWGEOM functions, and POSTGIS_DEBUG()/POSTGIS_DEBUGF() for PostgreSQL functions. To enable debugging, run configure with --enable-debug and then remake the entire project. If --enable-debug is omitted during configure, the above macros evaluate to (void)0, and hence should be removed by the compiler during optimisation. Also: contains minor warning cleanups and a fix for the ST_Dwithin SQL definition. 2008-05-31 09:56:44 +00:00
lwgeom_dump.c Add parser flags to the LWGEOM to (E)WKB/WKT parsers, similar to has already been done for the (E)WKB/WKT to LWGEOM parsers. 2008-09-25 21:50:19 +00:00
lwgeom_estimate.c Fix for segfault in ANALYZE due to incorrect use of legacy BOX type within compute_geometry_stats() (Fixes GBT#43). Thanks to Landon Fuller for the bug report and fix. 2008-07-16 08:42:34 +00:00
lwgeom_functions_analytic.c Update pip shortcut code to be less aggressive in building cache. 2008-09-28 09:03:32 +00:00
lwgeom_functions_basic.c Update LWGEOM unparser to (E)WKT/WKB to resturn a LWGEOM_UNPARSER_RESULT structure instead of just the WKT/WKB character array. This is the same work done for r3023 but applied to the unparser instead. 2008-09-28 19:48:17 +00:00
lwgeom_functions_lrs.c Fix for locate_along_measure returning invalid values (GBT#21) 2008-09-30 13:25:22 +00:00
lwgeom_geojson.c Apply GeoJSON patch from Olivier Courtin. 2008-07-13 23:47:54 +00:00
lwgeom_geos_c.c Some extra debugf's in the prepared geometry code. 2008-10-03 18:07:18 +00:00
lwgeom_gist.c Patch up and comment out some DEBUGF lines that don't compile due to changes in function 2008-10-03 17:37:42 +00:00
lwgeom_gml.c Commit new PostGIS debugging infrastructure. These changes unify all the debug logging to use a new set of macros: LWDEBUG()/LWDEBUGF() for LWGEOM functions, and POSTGIS_DEBUG()/POSTGIS_DEBUGF() for PostgreSQL functions. To enable debugging, run configure with --enable-debug and then remake the entire project. If --enable-debug is omitted during configure, the above macros evaluate to (void)0, and hence should be removed by the compiler during optimisation. Also: contains minor warning cleanups and a fix for the ST_Dwithin SQL definition. 2008-05-31 09:56:44 +00:00
lwgeom_inout.c Patch up and comment out some DEBUGF lines that don't compile due to changes in function 2008-10-03 17:37:42 +00:00
lwgeom_kml.c Fixed up KML patch from Eduin Carillo. 2008-03-28 21:31:57 +00:00
lwgeom_ogc.c Update LWGEOM unparser to (E)WKT/WKB to resturn a LWGEOM_UNPARSER_RESULT structure instead of just the WKT/WKB character array. This is the same work done for r3023 but applied to the unparser instead. 2008-09-28 19:48:17 +00:00
lwgeom_pg.c Update LWGEOM unparser to (E)WKT/WKB to resturn a LWGEOM_UNPARSER_RESULT structure instead of just the WKT/WKB character array. This is the same work done for r3023 but applied to the unparser instead. 2008-09-28 19:48:17 +00:00
lwgeom_pg.h Add parser flags to the LWGEOM to (E)WKB/WKT parsers, similar to has already been done for the (E)WKB/WKT to LWGEOM parsers. 2008-09-25 21:50:19 +00:00
lwgeom_rtree.c Fix log message to refer to correct function name 2008-10-02 15:56:57 +00:00
lwgeom_rtree.h Clear up warnings (mixed declartions within code and invalid return) from r3022. 2008-09-28 15:47:02 +00:00
lwgeom_spheroid.c Commit new PostGIS debugging infrastructure. These changes unify all the debug logging to use a new set of macros: LWDEBUG()/LWDEBUGF() for LWGEOM functions, and POSTGIS_DEBUG()/POSTGIS_DEBUGF() for PostgreSQL functions. To enable debugging, run configure with --enable-debug and then remake the entire project. If --enable-debug is omitted during configure, the above macros evaluate to (void)0, and hence should be removed by the compiler during optimisation. Also: contains minor warning cleanups and a fix for the ST_Dwithin SQL definition. 2008-05-31 09:56:44 +00:00
lwgeom_sqlmm.c Move the LWGEOM-specific functions from lwgeom_sqlmm.c into liblwgeom/lwsegmentize.c to ensure that liblwgeom can exist as a standalone library. 2008-09-16 18:44:49 +00:00
lwgeom_svg.c Enhanced speed _ST_DWithin(g,g,d) that returns as soon as g and g are within d of each other, rather than using distance naively. Change ST_DWithin to use enhanced op. (Issue 20) 2008-05-28 23:03:11 +00:00
lwgeom_transform.c Rework prepared geometry handling to look more like the implementation of 2008-10-02 23:53:37 +00:00
lwgeom_triggers.c Added cache_bbox trigger 2004-12-30 10:24:25 +00:00
lwpostgis.sql.in.c add check for invalid srid to addgeometrycolumn (#33) 2008-10-02 17:36:52 +00:00
Makefile.in Alter the lwgeom Makefile so that liblwgeom.a is linked directly, rather than using the -L...-l options on the command line. This is to prevent problems on OSX where PGXSadds the PostgreSQL $libdir to the PostGIS link line, causing it to link to liblwgeom.so produced by older versions of PostGIS rather than the static liblwgeom.a. 2008-08-21 08:45:07 +00:00
MISSING_OBJECTS updated 2004-11-11 09:42:26 +00:00
pgsql_compat.h Move some PostgreSQL compatibility macros from lwgeom_pg.h into pgsql_compat.h which is their proper home 2008-06-29 19:19:06 +00:00
profile.h ISO C90 comments (finished in lwgeom/) 2006-01-09 15:55:55 +00:00
README Added updated README file 2005-01-13 09:10:11 +00:00
SERIALIZED_FORM Updated with curved geometry definitions. 2006-12-06 02:00:26 +00:00
sqldefines.h.in Remove the HAS_SCHEMA #define and all related #else code since we now guarantee to be using PostgreSQL > 7.2 2008-06-05 11:19:29 +00:00
sqlmm.sql.in Got rid pf superfluous redirection to deprecated functions of ST_GeomFromWkb and ST_GeomFromText - now they just point directly to the c functions. Changed all FromWKB, FromText variants to point to the non-deprecated ST_GeomFrom, ST_BuildArea etc. (before they were pointing at deprecated functions) 2008-07-30 11:41:23 +00:00
stringBuffer.c ISO C90 comments (finished in lwgeom/) 2006-01-09 15:55:55 +00:00
stringBuffer.h ISO C90 comments (finished in lwgeom/) 2006-01-09 15:55:55 +00:00
test.c Renamed lwgeom_to_wkt to lwgeom_to_ewkt, as it doesn't strip out non-ogc 2005-03-01 13:22:50 +00:00
TODO jdbc2 works: 2005-04-15 14:04:34 +00:00

Welcome to the Initial version of LWGEOM.

More information is available on the PostGIS user's mailing list and 
the PostGIS developer's mailing list.  

Differences
-----------

The LWGEOM is very much like the original PostGIS GEOMETRY type.  The 
main differences are:

a) LWGEOMs are much smaller than the PostGIS GEOMETRY
b) LWGEOMs natively support 2d, 3d, and 4d points
c) LWGEOMs are indexed using single-precision bounding boxes.  This
   make the indexes significantly smaller than PostGIS GEOMETRY
   indexes.
d) LWGEOMs are internally very similar to OGC WKB   
e) The "normal" view of LWGEOMs is OGC WKB - PostGIS GEOMETRY is OGC WKT
f) PostGIS geometries have a built-in BOX3D.  LWGEOMs have an *optional*
   BOX2D (see below).


Also included with the LWGEOMs is a type called 'box2d'.  This is
very similar to PostGIS BOX3D type:

a) BOX2Ds are 2D - BOX3D is 3D
b) BOX2Ds are represented by single-precision floating point numbers,
   while BOX3Ds are double-precision floating point numbers.
c) BOX2Ds will sometimes be slightly larger than you might expect.
   This is because the conversion from double-precision to 
   single-precision is inexact.  When this happens, the BOX2D will
   automatically expand itself.
   

Bounding Boxes
--------------

<this section for advanced users.  Ignore it if you don't understand
 what its saying.>

Bounding boxes are optional in LWGEOMs.  By not having one, you are
saving a small amount of space per LWGEOM geometry (16 bytes).

Bounding boxes are attached to any non-POINT geometry by default.

You can disable this automatic addition setting AUTOCACHE_BBOX to 0
in the top-builddir Makefile.config and read BBOXCACHE_BEHAVIOURS
for function-by-function behaviour explanation.

Manual control of bbox cache is available using DropBBOX() and AddBBOX().

UPDATE <table> SET <geomcol> = DropBBOX(<geomcol>);
UPDATE <table> SET <geomcol> = AddBBOX(<geomcol>);

Note that if you don't cache a BBOX spatial operators will be much slower,
as they'll need to compute all the boxes at every invokation.
If you use GiST indexes you will still note a slow down as a RECHECK
clause is specified for GiST operators. Also, GiST index updating
will be slower w/out a BBOX cache.


Space Saving
------------

LWGEOM indexes are approximately 40% smaller than PostGIS indexes.

A LWGEOM 'POINT(0 0)' takes up 21 bytes, a POSTGIS 'POINT(0 0)' takes
up 140 bytes.  This shows that LWGEOMs have a much smaller overhead.

LWGEOMs will store 2D points as 2 double precision numbers (16 bytes) -
PostGIS will store 2D points with 3 numbers (24 bytes).   This can be 
another big savings.