#Problem:
Copy from :
Why does my app throw an exception in Map.addOverlay() when adding a Marker to the map with a custom Icon?
The JavaScript API isn't very clear about this, but when using a custom icon you need to be careful to set the icon size and anchor point. Also, when using a custom icon that isn't shaped like the default marker, the shadow may look funny, so its best to plan on replacing that as well.
Icon icon = Icon.newInstance("http://www.example.com/foo.png"); icon.setShadowURL("http://www.example.com/foo-shadow.png"); icon.setIconSize(Size.newInstance(12, 20)); icon.setShadowSize(Size.newInstance(22, 20)); icon.setIconAnchor(Point.newInstance(6, 20)); icon.setInfoWindowAnchor(Point.newInstance(5, 1)); map.addOverlay(new Marker(LatLng.newInstance(lat,lng), options));
Problem: GIF animated onn google map?
No comments:
Post a Comment