[mapguide-internals] RE: [mapguide-users] Fusion and Themed
Layers - usability
Paul Spencer
pagameba at gmail.com
Mon Apr 6 14:28:54 EDT 2009
just realized my posts are bouncing because I sent them from a
different mail account ...
In mapserver, we build the legend sprite when the map is loaded. If
the sprite information is available for any given layer, it is reused
otherwise the normal process is used (which catches dynamic layers).
It would be possible to modify this to point to a static image file if
the appropriate offsets were also cached, but there may be some
problems figuring out which layer is which (does the uuid of a layer
change at run time?)
The strip needs to be generated once when the map is loaded rather
than dynamically via a php file as the source of an image to make it
workable (you need the offsets anyway so why not draw it once)
Cheers
Paul
On 5-Apr-09, at 9:08 PM, Tom Fukushima wrote:
> I'm assuming that the map authors would like some control on how the
> legend swatches look; and that's why I think there should be a
> chance for the user to specify the image strip. Perhaps I'm wrong.
>
>
> Tom
>
> -----Original Message-----
> From: mapguide-internals-bounces at lists.osgeo.org [mailto:mapguide-internals-bounces at lists.osgeo.org
> ] On Behalf Of Jason Birch
> Sent: Sunday, April 05, 2009 4:44 PM
> To: MapGuide Users Mail List; mapguide-internals at lists.osgeo.org
> Subject: [mapguide-internals] RE: [mapguide-users] Fusion and Themed
> Layers - usability
>
> Paul,
>
> How does this work for MapServer? Do you just define an image URL
> and icon width/height in the Map extension element, and calculate a
> CSS offset into the image strip based on the layer item's array index?
>
> If that's the case, it wouldn't take me much work to create a PHP
> script that generates an image strip given a map definition. This
> script could either be called dynamically (if it's specified as the
> icon image URL) or could be run once by the user, and the image
> stored and hard-coded as the icon URL.
>
> I guess we'd need a special case for dynamic layers (buffer results,
> etc); do a direct GetLayerImage call for these?
>
> Jason
> ________________________________________
> From: Paul Spencer
> Sent: Sunday, April 05, 2009 2:15 PM
> Subject: Re: [mapguide-users] Fusion and Themed Layers - usability
>
> I think Jason's idea of using the bottom end of the scale + 1 would
> improve cacheability (?) but in the end it would be ideal if we could
> do the same thing with MapGuide that we did with MapServer which is to
> generate a strip of images for each layers/scale and a set of css
> offsets associated with them. The image is only generated and loaded
> once, providing significant improvements to responsiveness and load
> time._______________________________________________
> mapguide-internals mailing list
> mapguide-internals at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapguide-internals
> _______________________________________________
> mapguide-users mailing list
> mapguide-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapguide-users
More information about the mapguide-users
mailing list