[mapguide-users] OGR / GEOS selection problem

Kenneth, GEOGRAF A/S ks at geograf.dk
Thu Jun 7 02:54:54 EDT 2007


Maciej previously reported problems with the OGR provider using PostGIS.

The problem is with the OGR provider.
Se the Trac ticket for details:
http://trac.osgeo.org/mapguide/ticket/172

I have posted some follow up on the issue, but in hope someone knows a 
lot about GEOS, I'm also posting it here:


I have been examining the problem, using a custom build of the OGR 
provider. It is true that without GEOS support in OGR, the Intersect 
only does a BBOX check.

However, merely enabling GEOS will not work, as the viewer sends a 
square that is orthogonal to the axes (like a BBOX). The GEOS library 
will interpret this as another BBOX, and only perform the BBOX check 
anyway.

When I change the polgyon sent from the viewer to a triangle, it takes 
22 seconds to calculate the Intersects result with a polygon with 8000 
linesegments. I have a 2+ GHz machine.

It seems that GEOS always builds a full intersection matrix, before 
returning the result. This is obviously not optimal for a simple hit 
test. Even with this knowledge, I still don't see how it can take 22 
seconds to calculate 8000 * 3 intersections.

Can someone explain this, or how to fix it?



-- 
Regards, Kenneth, GEOGRAF A/S




More information about the mapguide-users mailing list