To further explain in details, I need to quote what one of our developers says:
"It is the fact that we've quoted some codes for Bing Map in last update of Tourweaver. They are MapTypeControl class, PositionControl class, ZoomControl class, as well as codes related to these three classes, such as functions get_zoom_from_bing_resolution and get_bing_resolution related to ZoomControl class. The fomula Klaus mentions 22 - (4.7438 + 2 * (Math.log(res) * Math.LOG10E) / (Math.log(4) * Math.LOG10E)), and Math.pow(10, (22 - 4.7438 - zoom) * (Math.log(4) * Math.LOG10E) is mainly the approximate relationship between zoom level and resolution in ZoomControl class. I would like to share what we've found about the zoom level and resolution in Bing Map: when the value of resolution is smaller than 1.2, Bing map won't show up. It would be a white screen. According to the definition of resolutions in org.openscales.core.layer.Bing:
public static const resolutions:Array = new Array(156543.03390625,
78271.516953125,
39135.7584765625,
19567.87923828125,
9783.939619140625,
4891.9698095703125,
2445.9849047851562,
1222.9924523925781,
611.4962261962891,
305.74811309814453,
152.87405654907226,
76.43702827453613,
38.218514137268066,
19.109257068634033,
9.554628534317017,
4.777314267158508,
2.388657133579254,
1.194328566789627,
0.5971642833948135,
0.29858214169740677,
0.14929107084870338,
0.07464553542435169);
When the value of resolution is 1.2, it is at the level between 17 and 18. What's more, the valid levels are 1-17 even though the returned JSON data "zoomMax":21,"zoomMin":1 from MS Bing Map, so it should be ok to modify the response method (zoomin and zoomout) in org.openscales.core.Map class, no need of such complicated formula."
"We will remove all the codes quoted from Krpano Bing Map Plugin."
"In order to use OpenSacles to realize the support of Bing Map and the features supported by Tourweaver, we've digged deep into OpenScales, Bing Map and Google Map, and then we compile our core classes. We would like to share our thoughts here:
Get to the bottom of the projection relationship of Google Map and Bing Map with reference at http://www.maptiler.org/google-maps-co…unds-projection and http://msdn.microsoft.com/en-us/library/bb259689.aspx. Chinese references: Mercator map projection http://www.blogoutdoor.com/user1/8860/arc…2007/36455.html. The programming conversion among Warp and weft cordinate, Mercator cordinate and QUADTREE cordinate, so the lat and lng of Google Map are needed to be converted to the corresponding cordinate in Bing Map. However, in proj4as of OpenScales, ProjProjection class provides the conversions from wgs84 (EPSG:4326) to EPSG:900913 and from EPSG:900913 TO WGS84(epsg:4326)."
"Refer to OPenScales API documents and sample codes (openscales-as-examples, openscales-fx-examples) so to compile our own Map class."
"We've written TWCsutomMarker class (inherited from org.openscales.core.feature.CustomMarker) to realize the hotspot and radar on map."
"We've written Polygon class (inherited from org.openscales.core.feature.PolygonFeature)to realize the customizable polygonal hotspot in the map."
"OpenScales has provided org.openscales.core.handler.mouse.WheelHandler (used for the mouse rolling control over the zoom in/out of the map) and DragHandler class (used for the left/right and up/down movement of the map). We've found when we roll to the highest leverl with mouse, the Bing Map won't show up but a white screen. When the value of _newResolutio is smaller than 1.2, the Bing map won't show up. _newResolutio is in the zoomIn method of org.openscales.core.Map called by org.openscales.core.handler.mouse.WheelHandler. For the response to DEFAULT_MAX_RESOLUTION, we come to conclusion that the value should be 1.5. "