Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: Hillshade provider #9

Open
Framstag opened this issue Mar 27, 2021 · 16 comments
Open

Question: Hillshade provider #9

Framstag opened this issue Mar 27, 2021 · 16 comments

Comments

@Framstag
Copy link

The screenshot suggests, this is already working. However the settings options does not seem to work. Bug or missing feature?

@janbar
Copy link
Owner

janbar commented Mar 27, 2021

No missed. You have to create the file "hillshade-tile-server.json" (copying the provided sample file hillshade-tile-server.json.sample) in the app folder "resources". But if your USB is broken ...

@janbar
Copy link
Owner

janbar commented Mar 27, 2021

The sample file provided with the app contains:

{
  "id": "wmflabs",
  "name": "wmflabs",
  "servers": [
    "http://tiles.wmflabs.org/hillshading/%1/%2/%3.png"
  ],
  "maximumZoomLevel": 18, 
  "copyright": "© wmflabs Hillshading"
}

@janbar
Copy link
Owner

janbar commented Mar 27, 2021

I could create it by default on the first startup. But I don't know if we can use this server without limits. For myself I used my own hillshade server.

@Framstag
Copy link
Author

Hmmm. The libosmscout answer would be to provide an offline solution. I do not know though if this is realistic. Would be worth to make a libosmscout feature request 😎

@janbar
Copy link
Owner

janbar commented Mar 28, 2021

IMO not realistic using tiles from tiff. In my own hillshade server the cache of tiles data size 20gb and the tiff data more than 50gb. Make tiles cost a lot for the cpu using the basic method (gdal).

@Framstag
Copy link
Author

I have now created Framstag/libosmscout#1030 to evaluate the chances to get offline hillshading implemented.

@Framstag
Copy link
Author

I also tried to find out what are the conditions for usage above tile server - but failed. Looks like it is part of the Wikipedia cloud infrastructure services: https://wikitech.wikimedia.org/wiki/Help:Cloud_Services_Introduction. The Teres and conditions do not explicitly forbid usage but frame it for tests.

@Karry
Copy link

Karry commented Mar 29, 2021

Hi @janbar , you may use my hillshade server: https://osmscout.karry.cz/hillshade/tile.php?z=%1&x=%2&y=%3, its performance is low (when tile is not ready in cache), but it will survive few more requests :-) Or if you have some server that you can use, you may setup own instance, here is howto.

@Framstag
Copy link
Author

@janbar It would be nice to have the option to simply enable/disable @Karry hillshade server.

@janbar
Copy link
Owner

janbar commented Mar 30, 2021

@Framstag , there is the option in settings. So I could copy the sample in the resource on startup if no one exists.

@Framstag
Copy link
Author

For me this is OK, @Karry should keep an eye on it infrastructure though, since he may get some additional load (but I assume you did not do any advertising up to now or have an sign for significant usage?).

@janbar
Copy link
Owner

janbar commented Mar 30, 2021

@Karry, @Framstag , I configured the app to Karry server and I get many "too many request". It is a hard job to make these tiles and also requires throughput. Staying over Greece since 5 minutes the tiles doesn't download yet. I am afraid to break your infra. May be we think about later. For instance the sample file is plugged to http://tiles.wmflabs.org/hillshading/ , and you will have at least the Europe with a good precision.

I have to release again the app and the new one will check if hillshade server file exists, if not it will copy from the sample. The wmflabs.org has a good throughput and many tiles are in cache. But only Europe and US are available with a good pitch.

@janbar
Copy link
Owner

janbar commented Mar 30, 2021

The commit is fd2504e.
The next release will be 1.3.4.
@Framstag , you will have to go in Settings / Configure Maps, then check the option Hillshade.

Also, it will be good to have a working USB ;-). That will allow you to tweak the app , push GPX or pull recorded track, save favorites etc...

@janbar
Copy link
Owner

janbar commented Mar 30, 2021

@Framstag , enabling hillshade will download tiles not yet cached in the phone from the internet. If you haven't wifi the phone will use the data mobil network.

@Framstag
Copy link
Author

Works. You can close the issue

@Karry
Copy link

Karry commented Mar 31, 2021

I get many "too many request".

There is limitation for two processes rendering tiles in parallel, because my raspberry has just 1 GiB of ram. Qt is using four parallel http streams (it is not configurable unfortunately), so when you are visiting area that is not cached, server have to reject some requests. But with some patience all tiles are rendered...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants