kmllayer redraws / flashes on map zoom

213 views
Skip to first unread message

Kevin

unread,
Mar 1, 2011, 2:48:10 PM3/1/11
to google-map...@googlegroups.com
I have a kml file containing polylines representing highways in a state.  It is loaded into Google Maps v3.3 as a KmlLayer.
 
Whenever I zoom in or out on the map, the KmlLayer appears to be redrawn.  This causes a flashing effect for the polylines (they disappear and are then redrawn) while my Markers stay drawn (and don't flash).
 
Is there a way to eliminate this flashing effect?  I would really like to get rid of it.  The same Kml is displayed regardless of the zoom so from an application point of view, there isn't a need to redraw the layer.

Jones, Kevin

unread,
Mar 1, 2011, 2:59:17 PM3/1/11
to google-map...@googlegroups.com

Maybe this has to do with the order with which Google Maps redraws the map. 

 

If I have only the KmlLayer displayed, I don’t see the flashing since the map is redrawn so quickly.

 

However, when I toggle the display of my Markers on, I see the flashing.  I see the map and the markers immediately redrawn.  Then I see a pause and then the KmlLayer is redrawn.

 

I did see a significant improvement in the zoom performance when moving from v3.2 to v3.3 though I still see what I have described.  Should I consider this poor performance due v3 still being a work in progress?  Will I see an improvement in the future?  Or is there a way that I can remedy this now?

--
You received this message because you are subscribed to the Google Groups "Google Maps JavaScript API v3" group.
To post to this group, send email to google-map...@googlegroups.com.
To unsubscribe from this group, send email to google-maps-js-a...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-maps-js-api-v3?hl=en.

Rossko

unread,
Mar 1, 2011, 3:43:54 PM3/1/11
to Google Maps JavaScript API v3
> I have a kml file containing polylines representing highways in a state.  It
> is loaded into Google Maps v3.3 as a KmlLayer.
>
> Whenever I zoom in or out on the map, the KmlLayer appears to be redrawn.  

Your KmlLayer will be rendered as tile overlays at Google's servers.
When you zoom or pan, new tiles have to be fetched. I don't think
there is much you can do about that.
Reply all
Reply to author
Forward
0 new messages