[postgis-devel] Geodetic issues

Bryce L Nordgren bnordgren at gmail.com
Thu Sep 1 12:57:39 PDT 2011


On Thu, Sep 1, 2011 at 7:26 PM, Paul Ramsey <pramsey at opengeo.org> wrote:

>
> > - Is it illegal to have a point on the poles? From
> ptarray_check_geodetic()
> > in /liblwgeom/lwgeodetic.c
> >
> > if ( pt.x < -180.0 || pt.y < -90.0 || pt.x > 180.0 || pt.y > 90.0 )
> return
> > LW_FALSE;
> >
> > It seems kind wierd that it is ok to have a polygon the circumnavigates
> the
> > pole, but not a point on the pole?
>
> It is weird, and I cannot access my last year self to figure out WTF I
> was thinking doing strict less-than rather than less-than-equals. I
> think it's just going to have to change.
>
>
As I read it, that statement only returns false if y > 90.0 or y < -90.0;
meaning that a point on the pole (exactly 90.0 or -90.0) would return true.
Ergo, the stmt as is permits points on the poles. Am I missing something?

Bryce
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-devel/attachments/20110901/6897640c/attachment.html>


More information about the postgis-devel mailing list