I have a page which displays different polygons saved as strings in SQL Db. I managed to center the map depending on the polygon being loaded, but I would also like to set the zoom level of the map, depending on the polygon's zoom level. I have seen many discussions on this topic (i.e. How can I get zoom levels to decode a polyline from Google Maps Directions API?), but I am nowhere nearer the solution. Could anyone help?
I center the map using coordinates, which I get from decodePath method,
google.maps.geometry.encoding.decodePath(googlePolygon)
however it only returns lat long values, without any levels or zoom level information