Skip to content Skip to sidebar Skip to footer

Specify Size Of Custom Marker In Google Map

I am trying to put custom markers on a google map. The icons that I want to use are png files and vary based on the type of point being placed on the map. Both the location of th

Solution 1:

You could specify a google.maps.Icon as the MarkerOptions, e.g.

var marker = new google.maps.Marker({
    position: myLatlng,
    map: map,
    title: data.venue,
    icon: {
        url: data.image,
        scaledSize: new google.maps.Size(32, 32)
    }
});

Post a Comment for "Specify Size Of Custom Marker In Google Map"