postgis/postgis
2011-10-28 20:46:18 +00:00
..
.cvsignore Change the name of the main source directory. This is going to break the build for a little while until I fix all the references, but I want to do it atomically to ensure version history is preserved. 2009-02-11 18:22:32 +00:00
compat.h Change the name of the main source directory. This is going to break the build for a little while until I fix all the references, but I want to do it atomically to ensure version history is preserved. 2009-02-11 18:22:32 +00:00
DEBUG Change the name of the main source directory. This is going to break the build for a little while until I fix all the references, but I want to do it atomically to ensure version history is preserved. 2009-02-11 18:22:32 +00:00
geography.h Remove GSERIALIZED_ON from .sql files. 2011-09-28 23:58:34 +00:00
geography.sql.in.c Remove GSERIALIZED_ON from .sql files. 2011-09-28 23:58:34 +00:00
geography_btree.c Move floating points comparator macros from liblwgeom.h to liblwgeom_internal.h (not prefixed symbols) [RT-SIGTA] 2011-08-09 14:19:12 +00:00
geography_estimate.c Replace min/max/abs macros with FP_* variants in liblwgeom/ and with pgsql variants in postgis/ 2011-10-28 18:01:57 +00:00
geography_inout.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
geography_measurement.c Use macros for hard-coded "magic" SRIDs used by _BestSRID and ST_Transform, use 999xxx range for them. See ticket #1230. 2011-10-10 06:55:50 +00:00
geometry_estimate.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
geometry_inout.c Partial typmod support for PostGIS geometry (#944) 2011-06-16 21:01:53 +00:00
gserialized_gist_2d.c Make the <-> operator return linear not square units, to match the <#> operator. 2011-09-28 15:06:51 +00:00
gserialized_gist_nd.c Fix error of unknown symbol gidx_to_string when building with the flags --with-raster --enable-debug using patch gidx_to_string.patch provided by bnordgren. 2011-08-25 18:18:20 +00:00
gserialized_typmod.c Ensure calls to lwgeom->type use type of uint8_t 2011-10-28 17:01:02 +00:00
legacy.sql.in.c Remove GSERIALIZED_ON from .sql files. 2011-09-28 23:58:34 +00:00
legacy_compatibility_layer.sql.in.c Remove GSERIALIZED_ON from .sql files. 2011-09-28 23:58:34 +00:00
long_xact.c astyle --style=ansi --indent=tab (#133) 2009-06-11 16:44:03 +00:00
long_xact.sql.in.c replace _VOLATILE_STRICT with VOLATILE STRICT 2009-06-12 15:30:40 +00:00
lwgeom_accum.c apply astyle 2011-05-13 08:46:04 +00:00
lwgeom_box.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_box3d.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_btree.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_debug.c Ensure calls to lwgeom->type use type of uint8_t 2011-10-28 17:01:02 +00:00
lwgeom_dump.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_export.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_export.h Change SRID to srid in LWGEOM struct (and also in CHIP too). Rename some functions related to SRID from Camel notation to lower case: errorIfSRIDMismatch, pglwgeom_getSRID, pglwgeom_setSRID, LWGEOM_getSRID, LWGEOM_setSRID, hasSRID. Related to #658 2010-11-25 17:34:21 +00:00
lwgeom_functions_analytic.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_functions_analytic.h merged fix from r7136 in 1.5 branch, fixes broken point_in_multipolygon_rtree, for #884 2011-05-12 18:51:57 +00:00
lwgeom_functions_basic.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_functions_lrs.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_geos.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_geos.h Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_geos_clean.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_geos_prepared.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_geos_prepared.h Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_geos_relatematch.c Don't release memory associated with arguments. Fixes #725. 2010-12-21 17:36:05 +00:00
lwgeom_gist.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_in_gml.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_in_kml.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_inout.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_ogc.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_rtree.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_rtree.h Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_spheroid.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_sqlmm.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_transform.c Remove BOX2DFLOAT4->GBOX and PG_LWGEOM->GSERIALIZED #defines 2011-10-28 20:46:18 +00:00
lwgeom_triggers.c astyle --style=ansi --indent=tab (#133) 2009-06-11 16:44:03 +00:00
Makefile.in Remove old box2dfloat4 in favor of gbox. 2011-10-25 21:05:42 +00:00
Makefile.pgxs Add missing MODULE_big section for #311 which was preventing the main PostGIS library from being installed on older versions of PostgreSQL. 2010-01-12 10:33:49 +00:00
MISSING_OBJECTS Change the name of the main source directory. This is going to break the build for a little while until I fix all the references, but I want to do it atomically to ensure version history is preserved. 2009-02-11 18:22:32 +00:00
postgis.sql.in.c Restrict valid spatial_ref_sys SRID values between 1 and 998999 (#1233) 2011-10-10 20:50:20 +00:00
postgis_drop.sql.in.c put in svn keywords and forcce to LF 2011-09-27 01:55:49 +00:00
postgis_drop_before.sql.in.c Some functions need to be dropped before upgrade minor if they need to be recreated. This is required for functions where argument names change but fundamental types do not. Will add this to upgrade minor script build later. 2011-10-13 11:56:20 +00:00
profile.h Add header guards to geos headers, move GEOS_PREPARED define to the implementation file, add missing copyright header. 2011-09-21 09:50:15 +00:00
README Change the name of the main source directory. This is going to break the build for a little while until I fix all the references, but I want to do it atomically to ensure version history is preserved. 2009-02-11 18:22:32 +00:00
SERIALIZED_FORM Change CompoundString to CompoundCurve 2011-06-27 19:24:00 +00:00
sqldefines.h.in Removed hackish use of POSTGIS_GDAL_VERSION in postgis/sqldefines.h.in and postgis/postgis.sql.in.c. Added conditional compilation of extent resizing based upon GDAL version in rt_api.c 2011-10-05 04:54:00 +00:00
sqlmm.sql.in.c #774: regress fails - Oops forgot to commit this file on last commit 2011-01-16 09:10:45 +00:00
TODO Drop extraneous task (if it referred to loader we do have a switch for index creation now) 2010-03-12 15:25:33 +00:00
uninstall_geography.sql.in.c Updated SQL files for uninstallation to match current state. 2009-11-30 19:56:27 +00:00
uninstall_legacy.sql.in.c #944, #1081, #1083, #1088, #1084: Convert geometry_columns to a view, revise management functions to not update/delete from geometry_columns and to support typmod. Will use typmod behavior as default 2011-07-02 08:58:38 +00:00
uninstall_long_xact.sql.in.c Merge Paul's geodetic (geography) branch into trunk, as per discussions on postgis-devel. Most of the merge was automatic (albeit quite slow), with a few manual touch-ups where the merge algorithm couldn't handle this automatically. "make check" runs and passes, so I hope I haven't managed to break too much ;) 2009-09-14 10:54:33 +00:00
uninstall_postgis.sql.in.c Renaming of 3D functions, #817 2011-03-27 17:50:58 +00:00
uninstall_sqlmm.sql.in.c Merge Paul's geodetic (geography) branch into trunk, as per discussions on postgis-devel. Most of the merge was automatic (albeit quite slow), with a few manual touch-ups where the merge algorithm couldn't handle this automatically. "make check" runs and passes, so I hope I haven't managed to break too much ;) 2009-09-14 10:54:33 +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.