This is a static archive of our old OpenStreetMap Help Site. Please post any new questions and answers at community.osm.org.

[closed] pixel Width and Height of a Bounding box based on zoom level in OpenLayers

0

I have a Openlayers Map showing ESRI's World_Imagery as base map. My question is given a extent (openlayers bounds object) and a zoom level. How do I calculate the Width and Height of this box in Pixels for that zoom level?

asked 16 Oct '12, 20:53

Shaunak's gravatar image

Shaunak
11112
accept rate: 0%

closed 16 Oct '12, 21:28

Frederik%20Ramm's gravatar image

Frederik Ramm ♦
82.5k927201273

Source code available on GitHub .