[Mapserver-users] Drawing labels beneath a certain layer?

Daniel Morissette morissette at dmsolutions.ca
Thu Dec 5 06:16:35 PST 2002


Vinko Vrsalovic wrote:
> 
> I want to draw the labels of a certain layer before another layer (so
> that the labels will be covered by this other layer).
> 
> Is this possible? (Without creating another layer just with texts)
> 

Assuming you are using MapScript, if instead of $map->draw() you use a
for() loop to call $layer->draw() on every layer, then you can call
drawLabelCache() in the middle of the loop to draw the labels.  Only
problem is you will have to clear the label cache and I don't think a
function exists for that yet in the PHP version... duh!  
(http://mapserver.gis.umn.edu/bugs/show_bug.cgi?id=207)

Well, as long as you don't call drawLabelCahce() again you should be
fine.

Daniel
-- 
------------------------------------------------------------
 Daniel Morissette               morissette at dmsolutions.ca
 DM Solutions Group              http://www.dmsolutions.ca/
------------------------------------------------------------



More information about the MapServer-users mailing list