I need to have a map with a list of markers on it. It needs to transition between these smoothly.
I have the following code which currently loops around the markers.
var x = 0;
function pan_to() {
if(x >= addresses.length){
x=0;
}
$.getJSON('http://maps.googleapis.com/maps/api/geocode/json?address='+addresses[x]+'&sensor=false', null, function (data) {
var p = data.results[0].geometry.location
var latlng = new google.maps.LatLng(p.lat, p.lng);
map.panTo(latlng);
});
x++;
} setInterval(pan_to,3000);
Working example here - http://jsfiddle.net/shanejones/khX2K/
What I need is the map to smoothly transition for 1 seconds between them with some form of easing too. Anyone have any ideas