There are some problems with REQUIRES. I understood that it's just possible to use only one REQUIRES per map file, also I don't know how a mutual REQUIRES "!..." for 2 layers might work. And how would one define which of the 2 will be the one that 'wins' if both are selecetd to be visible. And the display and selected layers in the TOC should be consistent.
I think it will be best to define a list of layers that mutually will disable all others if one of them is selected. I made some testings and it should work with some Javascript and using just checkboxes. So all checkboxes of the other layers in the disable list are set off if one of them is clicked. Armin > --- Urspr?ngliche Nachricht --- > Von: Silke Reimer <Silke.Reimer at intevation.de> > An: pmapper-users at faunalia.it > Betreff: Re: [Pmapper-users] switching raster layers > Datum: Mon, 30 Jan 2006 08:49:05 +0100 > > On Sun, Jan 29, 2006 at 11:37:53PM +0100, Armin Burger wrote: > > Luca, > > > > I had already similar problems with raster layers like satellite images > > and another layer like slopes, dem etc. It could also be vector layers > > if they are not transparent. > > > > I'm currently re-writing the part for the legend and layer display. One > > simplistic solution for that is to define layers that should mutually be > > disabled. This can be done by using radio buttons for them instead of > > checkboxes. > > > > There are maybe slight problems with regard to aesthetics and > > consistency. First the radio buttons align different on Firefox that the > > checkboxes. And also it might be confusing for users if you mix them. > > But nevertheless, one can think about to use it. I attached 2 > > screenshots that show how it looks like. If you group the raster layers > > together it might look acceptable. > > > > I will have to do some more testing. The PHP part is mainly finished, > > just some Javascript that needs some fine-tuning. Then I will make a > > development snapshot available for testing and hopefully it will go soon > > into final releases. > > Another solution could be to use the key REQUIRES in the layer > definition (seei [1]): > > Something like > REQUIRES "![orthophotos]" > should do it if you want an layer be rendered only if Orthophotos > are switched off. > > Silke > > [1] http://mapserver.gis.umn.edu/docs/reference/mapfile/layer > > > > > Armin > > > > luca marletta wrote: > > >Hi list. I'm exited with all this new code and feature you are > > >writing. Just worry for our friend Armin that must play the dirty work > > >of merge all together :-)). Be a leader as some disadvantages ;-) > > > > > >This my question asking for an hint. > > >I'm wondering if having 2 heavy rasters for the same scale and region > > >I can get more performance find the way to switch from one to another > > >in the layers activation or just overwrite one with another to show > > >the first or the second as I do now. > > > > > >In my case one raster is the map and the second is the orthofoto of > same > > >area. > > > > > >The idea is that mapserver takes 90% of total time for building the > > >map (Armin benchmark) so why process 2 rasters for overwrite one > > >totally. > > > > > >Maybe is a silly question because there is an obvious way to do it but > > >I don't know it so some one could be kind with me please. > > > > > >Is there a way to have in Layers tab just one option that switch from > > >a raster layer to another? > > > > > >-- > > >luca marletta > > > > > >_______________________________________________ > > >Pmapper-users mailing list > > >Pmapper-users at faunalia.it > > >http://faunalia.it/cgi-bin/mailman/listinfo/pmapper-users > > > > > > > > > > > _______________________________________________ > > Pmapper-users mailing list > > Pmapper-users at faunalia.it > > http://faunalia.it/cgi-bin/mailman/listinfo/pmapper-users > > > -- > Silke Reimer : www.intevation.de/~silke | GISpatcher: www.gispatcher.de > Intevation GmbH: www.intevation.de | Thuban : > thuban.intevation.org > Georgstr.4 : 49074 Osnabr?ck | FreeGIS : www.freegis.org > -- Lust, ein paar Euro nebenbei zu verdienen? Ohne Kosten, ohne Risiko! Satte Provisionen f?r GMX Partner: http://www.gmx.net/de/go/partner