[postgis-tickets] [PostGIS] #2495: geography && large_bbox fails

PostGIS trac at osgeo.org
Sun Oct 6 22:30:42 PDT 2013


#2495: geography && large_bbox fails
---------------------+------------------------------------------------------
 Reporter:  strk     |       Owner:  pramsey      
     Type:  defect   |      Status:  new          
 Priority:  medium   |   Milestone:  PostGIS 2.1.1
Component:  postgis  |     Version:  2.1.x        
 Keywords:           |  
---------------------+------------------------------------------------------

Comment(by pramsey):

 Welllll... I'm not sure segmentize or your other calculations are doing
 what you think, since you're calling it within the context of geometry,
 not geography (note the areas you are returning, those are areas in
 degrees, not square meters), BUT, that's not the real problem.

 The real problem is this idea that (-180, -90, 180, 90) is a "box". The
 "line" from -180,90 to 180,90 is not a line at all, there's no there
 there, it's just a point. Similarly at the bottom. So you aren't creating
 much of a bounding area, even if you did segmentize it.

 This is a problem that SQL Server solved with a custom "everything"
 representation for geographies, so handle the "whole world" case.

 The QGIS case is a flat world box being handed in and then we have an
 expectation for interpretation... probably the "right" thing to do is to
 segmentize it in geometry (as you have done, though far more aggressively
 (at 0.1 or 0.5 degrees), so that it more closely approximates on the globe
 what it is representing on the plane) then cast is into geography for
 processing. It should work better then. That still would fail for the
 "whole world" case, but would work right for most other "most of the
 world" cases.

 For the whole world, I'm still not sure what to do.

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/2495#comment:1>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-tickets mailing list