Opened 9 years ago
Closed 9 years ago
#11808 closed defect (needinfo)
Worse WMS imagery resolution in 8677 then in 8491
Reported by: | slodki | Owned by: | slodki |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | Core imagery | Version: | tested |
Keywords: | wms imagery zoom max-zoom regression | Cc: | wiktorn |
Description (last modified by )
What steps will reproduce the problem?
- Run JOSM
- Load some OSM data in new layer in Poland
- Refresh Imagery presets
- Load "Geoportal 2: Ortofotomapa (aerial image)" WMS layer
- Zoom in to view details of ortofoto map
What is the expected result?
In 8491 "wms:http" preset can load more detailed images. See attached example.
Using geoportal ortofoto gives following images resolutions:
[zoom in JOSM as show in main GUI ruler] -> [WMS image resolution as given by properties of WMS layer]
3.15m -> 2.39m
2.23m -> 2.39m
1.58m -> 1.19m
1.11m -> 1.19m
0.79m -> 0.6m
0.56m -> 0.6m
0.39m -> 0.6m
...
0.14m -> 0.6m
The "zoom to native resolution" command is not working for this WMS layer in 8491 version.
What happens instead?
In 8677 version "wms:http" preset is treated as "wms[20]:http" by default. This blocks images from WMS in higher resolutions. See attached example of the same settings in new JOSM version - you can see worse images resolution.
Clean 8677 JOSM gives:
[zoom in JOSM as show in main GUI ruler] -> [WMS image resolution as given by properties of WMS layer]
3.15m -> 20 (zoomlevel?)
2.23m -> 20
1.58m -> 20
1.11m -> 20
0.79m -> 20
0.56m -> 20
0.39m -> 20
...
0.14m -> 20
The "zoom to native resolution" command for WMS layer in "20" resolution sets main JOSM GUI ruler at 9.58m.
Changing WMS definition (see https://josm.openstreetmap.de/wiki/Maps/Poland?action=diff&version=41) gives better results:
3.15m -> 21 (zoomlevel?)
2.23m -> 22
1.58m -> 22
1.11m -> 22
0.79m -> 22
0.56m -> 22
0.39m -> 22
...
0.14m -> 22
Validator at https://josm.openstreetmap.de/wiki/Maps not allows max-zoom value >22.
After creation custom WMS preset directly in JOSM for geoportal ortofoto with "wms[24]:http" results are better:
3.15m -> 21 (zoomlevel?)
2.23m -> 22
1.58m -> 22
1.11m -> 23
0.79m -> 23
0.56m -> 24
0.39m -> 24
...
0.14m -> 24
It's hard to validate datails at such high zoom levels - maybe 24 zoom level is not avaiable for geoportal...
Setting native resolution for WMS images in JOSM 8677 gives following ruler value:
20 -> 9.58m
21 -> 4.79m
22 -> 2.39m
23 -> 1.2m
24 -> 0.6m
Please provide any additional information below. Attach a screenshot if possible.
Changes required:
- Remove hidden restriction of WMS preset definition (without max-zoom parameter) to 20 zoom level
- Remove restriction of JOSM wiki validator for map presets https://josm.openstreetmap.de/wiki/Maps to allow define max-zoom parameters >22 where available
- Change zoom treshold to load hi-res images at lover zooms (as in previous version)
- Optional: update map presets at wiki - add max-zoom parameter where required
Repository Root: http://josm.openstreetmap.de/svn Build-Date: 2015-08-21 23:32:08 Last Changed Author: Don-vip Revision: 8677 Repository UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b Relative URL: ^/trunk URL: http://josm.openstreetmap.de/svn/trunk Last Changed Date: 2015-08-21 22:18:03 +0200 (Fri, 21 Aug 2015) Last Changed Rev: 8677 Identification: JOSM/1.5 (8677 pl) Linux Slackware 14.1 Memory Usage: 432 MB / 897 MB (311 MB allocated, but free) Java version: 1.7.0_79, Oracle Corporation, OpenJDK Server VM Dataset consistency test: No problems found
Attachments (9)
Change History (19)
by , 9 years ago
Attachment: | geoportal-8491.png added |
---|
by , 9 years ago
Attachment: | geoportal-8677.png added |
---|
pixelized WMS image from current JOSM version
comment:1 by , 9 years ago
Description: | modified (diff) |
---|---|
Keywords: | regression added |
follow-up: 5 comment:4 by , 9 years ago
@slodki:
Requests 2 and 4 are done. 4 in scope of Geoportal Ortophotomap. I haven't touched any other ortophotomaps.
Request 1 - 20 is default value, that is assumed, when no max-zoom is present. As the max-zoom prevents JOSM from trying to download tiles which do not exists, its both good for performance of JOSM, as for tile servers. The default value should be the most common found "in nature". I'm not sure if any other value than 20 will be better
Request 3 - this I do not understand. From now on, WMS has some artificial "zoom levels", that helps a lot with caching the WMS imagery. If you zoom in (one tick on mouse wheel), you move "half point" closer. It means, that JOSM will still use what it has downloaded, but just rescale the images, as it is done for TMS imagery. If you zoom in again, then zoom level changes - and attempt to download new tiles is made. Do you want JOSM to download tiles at every zoom level? It will make WMS caching far less effective, and cache effectivnes was at the ground for this change.
follow-up: 6 comment:5 by , 9 years ago
Replying to wiktorn:
Ad 1 - maybe adding such default value is good for performance, but it brakes existing presets. JOSM 8491 doesn't restrict "wms:" preset to 20 zoom level, and it displays such presets at higher zoom. If you add new default 20 max-zoom value for presets, somebody (?) has to check all already defined presets and add max-zoom parameter for broken ones.
Ad 4 - so only one preset is fixed, but many of them are still broken and needs extra parameter to be added to work as expected (in earlier JOSM versions), not only at JOSM website, but user defined also (maybe some instructions at startup page for users is needed?)
Ad 2 - ok
Ad 3 - described mechanism of refreshing wms images only at some zoom and scaling them between is ok, but the images are downloaded with to low res to be usable. Maybe you should download images with better resolution (from next zoom level) and display them smaller (download image 512x512 and display it as 300x300 or 400x400)? Or there is a problem related to dpi used for display?
Screenshots from 8491 and 8699:
- Original picture from geoportal web service (displayed in web browser at max zoom):
- Same place as displayed by JOSM 8491 at similar and next zoom levels (from wms service), info about wms layer zoom displayed: 9.55m/9.55m/4.77m
- Same place as displayed by JOSM 8699 at similar and next zoom levels (from wms service), info about wms layer zoom displayed: 19@724x724/20@511x512/20@723x724
As you can see:
a) web browser is the best, old JOSM is better, current JOSM is the worst
b) old JOSM and new version downloads new resolution of wms image at different thresholds: old between 2nd and 3rd, new between 1st and 2nd
b) I don't know why one 512x512 image is scaled to 724x724, but next one to 723x724 - changing aspect ratio is really needed?
comment:6 by , 9 years ago
Replying to slodki:
Replying to wiktorn:
Ad 1 - maybe adding such default value is good for performance, but it brakes existing presets. JOSM 8491 doesn't restrict "wms:" preset to 20 zoom level, and it displays such presets at higher zoom. If you add new default 20 max-zoom value for presets, somebody (?) has to check all already defined presets and add max-zoom parameter for broken ones.
Yes, I know.
Ad 4 - so only one preset is fixed, but many of them are still broken and needs extra parameter to be added to work as expected (in earlier JOSM versions), not only at JOSM website, but user defined also (maybe some instructions at startup page for users is needed?)
That's a good idea.
Ad 3 - described mechanism of refreshing wms images only at some zoom and scaling them between is ok, but the images are downloaded with to low res to be usable. Maybe you should download images with better resolution (from next zoom level) and display them smaller (download image 512x512 and display it as 300x300 or 400x400)? Or there is a problem related to dpi used for display?
This is possible, but this would result in wasted bandwith (when you download picture say, 500x500 and downscale it to 200x200), and requires more CPU power (more images to process) and memory. But I plan to add such tunable in Imagery Preferences, so you can choose - resources conservative way, and resource hungry, but hopefully, with better quality.
As you can see:
a) web browser is the best, old JOSM is better, current JOSM is the worst
I only see the difference in number 1. Bear in mind, that you're probably taking this screenshot in Mercator projection which is not supported by WMS service. That's why you see better results by WWW service.
When you click left button on the tile, and choose "Show tile info" menu, you'll get exact URL that was used to download the tile. Please compare this tile (loaded by browser for example) with what is shown in JOSM. If this tile in browser is looking bad, then problem is due to changed queries to WMS servers, if it looks good, then it should be addressed by additional setting, that I mentioned earlier.
comment:8 by , 9 years ago
Did you tried zoom level controls? -1 setting should give you the behaviour as described in ad 3.
Is there anything left to fix?
comment:9 by , 9 years ago
Owner: | changed from | to
---|---|
Status: | new → needinfo |
comment:10 by , 9 years ago
Resolution: | → needinfo |
---|---|
Status: | needinfo → closed |
more detailed WMS image from previous JOSM version