Best practice to change WMS or WMTS style parameter?

Hi all,

we are using a couple of configurable WMS and WMTS layer. The user shall be able to select the styles for the layers (from a preconfigured list or styles).

As far as I can see, there is no possibility to change such settings of an existing layer, right?

What is the supposed way wo change between different layer styles? One possibility could be to remove the layer and create a new one. Or add one layer per preconfigured style and then just change the visibility?

Interesting finding: Although the WMS standard clearly defines a "STYLES" parameter, the Cesium WMS layer does not support it. It can only be set within the arbitrary "parameters" list.

All the best,

    Heiner

1 Like

I’d say changing the style and then removing and re-adding the layer is the best way, since this will trigger all tiles to be re-requested. This is what the base layer widget in the top right of the Cesium viewer does when you switch between imagery layers.