[ka-Map-users] Overlays with dynamic information

Paul Spencer pspencer at dmsolutions.ca
Tue Jan 3 11:13:23 EST 2006


Pg, this is awesome.  Can I add it to ka-Map's cvs?  I would like to  
include this as a standard feature in ka-Map.  More comments inline ...

On 30-Dec-05, at 5:52 AM, Pg wrote:

> Hello everybody. I'm doing some experiments on overlays and I will  
> appreciate comments and ideas.
>
> My goal is to set up a map with some dynamic information, like  
> traffic events, road conditions etc. The dynamic info should be  
> displayed on an overlay and automatically refreshed even if the  
> user doesn't reload the page.
>
> Using the DrawingCanvas of kaMap, the wz_jsgraphics library and  
> some ideas and code circulated on this list I've written a module  
> that fetch a server side generated XML document with the points to  
> draw on the overlay together with rendering directives.
> You can view an example in
>
>    http://sistel.dyndns.info/ka-map/indext.html
>
> The script is readable in http://sistel.dyndns.info/ka-map/ 
> kaXmlOverlay.js and it's tested in Firefox only.

it also works in Safari :)  ... any idea if it works in IE yet?

>
> This is a partial solution to my problem, because it's limited to  
> points, while I would like to display also features as linestrings  
> and polygons. As isn't comfortable doing that with jsgraphics, I've  
> implemented a solution with a wmsLayer that (with some dirty hack)  
> is reloaded periodically.
> In the page
>
>    http://sistel.dyndns.info/ka-map/indexw.html
>
> some streets are highlighted with different colours, and the  
> highlight should change more or less once a minute.
>
> I'think this solution is not as good as the previous, because it's  
> slow and produce a very high load on the WMS server.
> Better solutions could be:
>   a. using jsgraphics to draw 2D features an make them scalable  
> with the map
>   b. using a server-side script to refresh the cache of a layer and  
> convince the browser to reload only that layer, ignoring the  
> browser-cache
>
> Have you any ideas about that? Is anyone working on that?

we could also use a server-side generated image to represent lines  
and polygons.  wz_jsgraphics is pretty heavy, especially for larger,  
dynamic stuff.  Its actually not that hard to use GD or imagemagick  
to generate a server-side image for a given feature (line/polygon)  
and use addObjectGeo to position the resulting image correctly.  The  
tricky part is updating the image on scale change and making sure it  
doesn't get too big for the browser to handle.

For IE, google uses VML and we should probably consider that.

Cheers

Paul


>
> Bye and sorry for the long posting.
>
> Piergiorgio
>
> _______________________________________________
> ka-Map-users mailing list
> ka-Map-users at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/ka-map-users

+-----------------------------------------------------------------+
|Paul Spencer                           pspencer at dmsolutions.ca   |
+-----------------------------------------------------------------+
|Applications & Software Development                              |
|DM Solutions Group Inc                 http://www.dmsolutions.ca/|
+-----------------------------------------------------------------+






More information about the ka-Map-users mailing list