[OpenLayers-Dev] calculateBounds function
Abhi
abhirama.bhat at gmail.com
Tue Nov 11 05:39:38 EST 2008
Can someone please tell me or point me to some literature that explains the
logic behind the below piece of code (Taken from calculateBounds method of
Map class)?
var size = this.getSize();<Returns view port size>
var w_deg = size.w * resolution;
var h_deg = size.h * resolution;
extent = new OpenLayers.Bounds(center.lon - w_deg / 2,
center.lat - h_deg / 2,
center.lon + w_deg / 2,
center.lat + h_deg / 2);
--
Cheers,
Abhi
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-dev/attachments/20081111/0c0d37b3/attachment.html
More information about the Dev
mailing list