SLD: Implement SLD "Painters Model" Style Layering#5839
SLD: Implement SLD "Painters Model" Style Layering#5839jmckenna merged 7 commits intoMapServer:masterfrom
Conversation
|
The alternative here to achieve similar visual effects would be use multiple layers, correct? I could see this being more broadly popular so we really should expose this functionality via the mapfile/mapscript as well. I think that means exposing the layer RENDERMODE property and then the associated values. I guess that would mean on supporting something like: RENDERMODE FIRSTCLASS|ANYCLASS @geographika might have some opinion in terms of syntax. ANYCLASS is probably more descriptive than painter mode. |
|
Would a possible option be to have it as a PROCESSING directive? E.g.
I think this would then already be supported by MapScript looking at this test, without need for modifications. A couple of other options for the option naming (agree
Or slightly more literal but longer:
|
|
With regards to using multiple classes from the same layer for a single feature, it is possible using |
|
We don't have a good definition on when to add a full-on attribute vs using a processing directive. I agree that this feels more like a the latter... |
|
You read my mind! Exposing layer RENDERMODE property was something I thought of when developing the feature for SLD. I will be more available on september for implementing this. I let you choose the syntax details that best fit existing usage. |
|
I wonder what will happen if CLASSes have STYLEs with OPACITY. What is the result when RGBA 200 0 0 128 is rendered over RGBA 0 200 0 128? |
435c362 to
857a138
Compare
|
@geographika, @sdlime: As suggested, I have added a processing directive: |
|
@jbo-ads cool feature, thanks! |
This pull request proposes an implementation of SLD "Painters Model" style layering, where all applicable classes are used for rendering a feature instead of only the first one in original MapServer policy. This is described in third section of MS RFC 124: Improving SLD Support in MapServer.