0

I have degines style for my osm data, but background is transparent for png tiles. Is possible to seed tiles with background color?

I want seed tiles with same result like calling wms with these parameters:

...&&BGCOLOR=0xfefefe&TRANSPARENT=false

current style: enter image description here

black places are in tiles transparent, and my client app can not change this color, so I generate tiles with native background.

2
  • what is a "degines style"? Are you wanting all your PNG to have a background colour rather than being transparent?
    – Midavalo
    Commented Mar 19, 2017 at 17:37
  • I've added image of my actual map ... black color are transaprent in generated tiles ... that color has been added by client app, and I can not change it in client app, so I need set this color in Geoserver tiles. Commented Mar 19, 2017 at 17:53

1 Answer 1

2

GeoWebCache always requests transparent images to the WMS as there is no way to predict if they are going to be used as overlays or backgrounds.

That said, I've tried a hack that seems to work. If you are using the version integrated with GeoServer, go to the layer tile caching tab and add two custom parameter filters, forcing transparent to false and the background to the desired colors like this:

enter image description here

This gives me solid background tiles in the GWC preview:

enter image description here

I cannot ensure it's a general solution, but it sure works on my computer :-p

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.