[postgis-users] Converting GMaps.getBounds to POLYGON ewkt format

Babu Naidu pbnaidu at gmail.com
Fri Sep 14 19:31:34 PDT 2007


Hi All,

I am trying to convert Google Maps GMap.getBounds() (which returns LatLng
for south west and LatLng for north east)
to POLYGON( ) ewkt format. This is to query for points within that POLYGON.

I think I figured out the format and I would like to verify it with experts
here. I have southwest LatLng and northeast LatLng
considering Y=Lng and X=Lat

POLYGON(maxY  maxX,
maxY  minX,
minY  minX,
minY  maxX,
maxY  maxX)

Is this the right way to create a POLYGON? could you please point me to docs
if available that explain this format?

Thanks
Babu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20070914/f7a1ab89/attachment.html>


More information about the postgis-users mailing list