[postgis-devel] 3D Index / 2D Index concerns

Paragon Corporation lr at pcorp.us
Thu Mar 17 21:06:19 PDT 2011


Paul,

Hope you are enjoying your tripping.

Regarding the 2D, 3D index.  You mentioned those have to be separate
indexes.

I guess that means in order to implement the && (2d interacts)  vs.  &&& (3d
interacts) --- you had have them share separate set of index creation and
operators?

My main request is that we have an &&& and the 3D index version of && just
does a 2D check.

There are a couple of reasons for this:

1) We agreed that all 3D relationship functions would be ST_3D...   So those
should rightfully use a 3D interacts index (I'll call this &&&).

The consensus was also that the ST_Intersects etc.. Should remain as 2D
checks.  This means that even for 3D geometries, they can't use a 3D
interacts check.

If they did  we would have a situation where the 2D footprint of a 3D
geometry intersects a 2D footprint of another 3D geometry, but the
ST_Intersects returns false.  THIS IS VERY BAD.


2) Getting to the THIS IS VERY BAD issue.  I don't think our 3D checks make
provisions for volumetric they are basically checking surface intersection.
Nicklas can corect me if I am wrong, but I don't see how they 
Can since we can't distinguish right now between volumes and surfaces unless
we assume all closed surfaces are volumes (which technically isn't correct).

So with that said -- lets say I have a building and I have 3D stuff in it.
In order to know what stuff is in what building, I would be doing a 2D check
-- not a 3D check.  Any 3D  object that shares the same footprint as the
building is in the building for most cases unless its floating on top or
under the building which is rarely the case :).





More information about the postgis-devel mailing list