Re: zooming with polylines: slow, memory hogged
Wasn't it benft who wrote:
>
>Right, I haven't attempted to implement that VML / IE business yet. Are
>you saying that doing VML will help the situation in firefox too?
No. Firefox doesn't do VML at all.
Firefox could do SVG, but the API itself doesn't currently make use of
that technology.
> Is
>there a way to disable caching of those klunky line-images, if stuck
>with that?
The images aren't being cached. They're being delivered fresh from the
server every time you pan and zoom. That's the problem.
You can improve the situation by using a single blue polyline that
contains all those lines (even if it means backtracking and covering
some lines more than once). In that way you'll only ever get a single
polyline image returned from the server. The combined image will be a
little larger than the largest of your 74 images. I'd expect a
substantial speed and memory improvement.
You can do the same thing with each set of red lines. However, you're
going to have to draw the red lines over the top of the blue lines. Use
poly.setZindex(1) for the red lines. (The default z-index for polylines
is 0).
Or see if you can find a way to get your information across without
having all those blue lines there all the time, and only display the red
ones. Or perhaps not even have those, but change the colour of the
markers to highlight valid destinations.
--
The Blackpool Community Church Javascript Team
http://www.econym.demon.co.uk/googlemaps/
0 Comments:
Yorum Gönder
<< Home