试图从精灵中缩放标记图像

时间:2013-02-21 22:05:55

标签: google-maps sprite freemarker

var marker = new google.maps.Marker({
        position: new google.maps.LatLng(9.967937,-84.15062),
        draggable: true,
        //icon: marker0000,
        icon: new google.maps.MarkerImage("/static/img/map/markers/1/sprite3.png",    
        new google.maps.Size(40*scaleFactor, 24*scaleFactor), // desired size
        new google.maps.Point(41, offset*scaleFactor), // offset within the scaled sprite
        new google.maps.Point(20*scaleFactor, 12*scaleFactor), // anchor point is half of the desired size
        new google.maps.Size(123*scaleFactor, 52*scaleFactor)), // scaled size of the entire sprite
        map: map
    });

1 个答案:

答案 0 :(得分:0)

精灵缩放有一个开放的issue report (#4359)。在2012年8月19日的初次报告之后,任何人都没有任何活动。您可能会"明星"如果这是你遇到的问题,那就是问题。