The Google Maps terrain view by default has unlimited panning of the map tile. You can use LatLngBounds()
to limit this, but what are the maximum and minimum coordinates I should use to set the viewport as just the earth and not outside the map region?
Coordinates for North America:
var strictBounds = new google.maps.LatLngBounds(
new google.maps.LatLng(28.70, -127.50),
new google.maps.LatLng(48.85, -55.90)
);
I've tried (+90, -180)(-90,180)
to no luck.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…