[MapProxy] How do I get these tile sets overlayed with transparency?

Johannes Weskamm weskamm at terrestris.de
Thu Dec 5 00:22:58 PST 2024


Hi Michael,


You should switch the order of the layers sources, so that it reads

sources: [basemap_cache_schumm, basemap_cache_tiles]


Besides, you need to move the opacity parameter to the layers cache 
image options like this:


caches:
   basemap_cache_tiles:
     sources: [basemap_tiles]
     request_format: image/png
     image:
       format: image/png
       #mode: RGBA
       #transparent: true
       opacity: 0.5
     grids: [GLOBAL_WEBMERCATOR]


You dont need all those transparent and mode settings for your usecase 
and they can be removed.


Greetings,

Johannes



Am 04.12.24 um 15:14 schrieb Michael Heerdegen via MapProxy:
> Daniel Cebulla via MapProxy<mapproxy at lists.osgeo.org>  writes:
>
>> Is there a chance, that the term you are looking for in your use case
>> is "opacity" instead?? ...
> Of course.  Thank you for mentioning that point.
>
>>  From the docs:
>>
>> opacity
>> Configures the opacity of a layer or cache. This value is used when the source or cache
>> is placed on other layers and it can be used to overlay non-transparent images. It does
>> not alter the image itself, and only effects when multiple layers are merged to one
>> image. The value should be between 0.0 (full transparent) and 1.0 (opaque, i.e. the
>> layers below will not be rendered).
> I played with it for quite a while and didn't get it work.  Specifying
> opacity is not rejected (don't get a warning) but it has no effect.
> There are opacity related bugs, but maybe I'm trying wrong.  Tried a
> lot, though.
>
> There are also "transparent_color" and "transparent_color_tolerance",
> but also these don't have an effect.  Tried different combinations with
> different numbers of caches.
>
> I attach the end result of my today's trials, if somebody wants to play
> with it... Is there something obviously wrong?
>
> Thx, Michael.
>
>
>
> _______________________________________________
> MapProxy mailing list
> MapProxy at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/mapproxy

-- 
Dipl.-Geogr. Johannes Weskamm
   — Anwendungsentwickler —

   terrestris GmbH & Co. KG
   Kölnstraße 99
   53111 Bonn

   Tel: +49 (0)228 / 96 28 99 -51
   Fax: +49 (0)228 / 96 28 99 -57

   Email:weskamm at terrestris.de
   Web:https://www.terrestris.de

   Amtsgericht Bonn, HRA 6835
   Komplementärin: terrestris Verwaltungsgesellschaft mbH
   vertreten durch: Torsten Brassat, Marc Jansen
   
   Informationen über Ihre gespeicherten Daten finden Sie auf
   unserer Homepage unter folgendem Link:
   https://www.terrestris.de/datenschutzerklaerung/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapproxy/attachments/20241205/711c7500/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: RwBinu9RMCHgaGem.png
Type: image/png
Size: 289914 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/mapproxy/attachments/20241205/711c7500/attachment-0001.png>


More information about the MapProxy mailing list