Modify

Opened 15 years ago

Closed 15 years ago

#3717 closed defect (fixed)

slippy map problems (mainly performance issues)

Reported by: bastiK Owned by: team
Priority: normal Milestone:
Component: Core imagery Version:
Keywords: Cc: hansendc

Description

The slippy map plugin has some strange behavior:

  • When a new area is loaded the entire map is colored red (with some strange stripes at the border). Then after 10 seconds, it says 'pending download', and at least the data layer is now visible. After further 4 second the first tiles are shown. The CPU is at 100% for this time.

In contrast to that, the download dialog shows the tiles with no delay. Furthermore, without the plugin, the data layer is shown immediately.

  • Moving the map is quite sluggish.
Created-By: 1.5.0_16-b02 (Sun Microsystems Inc.)
Main-Version: 2271 SVN
Java version: 1.6.0_14
Plugin slippymap Version: 17822
OS: Ubuntu

Attachments (2)

Screenshot-OpenStreetMap-Editor in Java.png (75.9 KB ) - added by bastiK 15 years ago.
red background when loading
Screenshot.png (255.9 KB ) - added by bastiK 15 years ago.
shrinked mapnik

Download all attachments as: .zip

Change History (11)

in reply to:  description comment:1 by bastiK, 15 years ago

Owner: changed from framm to team

Quote from the mailing list:

I have exactly the same issue (even with the stripes, 100% CPU, red
bg). Working on Ubuntu 9.04 with latest (some days ago). That's why I
temporarily disactivated the plugin and turn it on just in case I
really need it.

forgot this: mercator.

java version "1.6.0_0"
OpenJDK Runtime Environment (IcedTea6 1.4.1) (6b14-1.4.1-0ubuntu11)
OpenJDK Client VM (build 14.0-b08, mixed mode, sharing)

comment:2 by hansendc, 15 years ago

Cc: hansendc added

by bastiK, 15 years ago

red background when loading

comment:3 by lars@…, 15 years ago

To me JOSM did the same thing until I changed the minimum zoom level of the slippy map.

Previously it was set to 13. So if you zoom to a lower level (say equal to 4 in slippymap zoom - the scale shows about "100 km" or something), instead of loading 5-8 tiles at level 4, JOSM trys to load say 1000-2000 tiles at level 13. And thats a lot of tiles! ;-)

Ridiculously there is only a "Maximum zoom level" in the configuration for the slippymap plugin.
You gonna have to change the min. zoomlevel in config file:
Its called "slippymap.min_zoom_lvl" in ~/.josm/preferences for linux or "c:\Documents and Settings\Account\Application Data\JOSM\preferences" for windows.

Change that to 3 or something that low.

comment:4 by bastiK, 15 years ago

@Hansen: do you know why minimum zoom is set to 13 by default? When zooming out I noticed this as well: The tiles get very small and it tries to load a lot of them.

Nevertheless setting it to 3 did not help with the initial problems. It's the same.

I noticed, that it the first phase (10 s) there is very little, but constant network traffic (~ 2 KiB/s). Then it shoots up in the second phase.

If you have a version of the plugin that produces some debug output, I can run it and send you the results.

comment:5 by hansendc, 15 years ago

OK, here's an updated version. I've made a lot of changes.

  1. Switched over to the jmaplayer code for tile loading. We can't actually use it for display, but we use all of its objects for fetching and caching and so forth. Lots of code changes here, but lots of benefits. May even share the tile cache with the slippymapchooser.
  2. Rewrote some of the tile drawing code. It used to go and draw the entire layer with every single one of the tiles that was available in +-3 layers. Now it just draws those layers for the missing tiles in the "best" layer.
  3. Added an input dialog for the minZoomLevel. That was missing before
  4. Rewrote the preference parsing code to be a bit cleaner
  5. Use a SpinnerNumberModel to limit the input range of the preference zoom levels in the gui

You need a really recent version of JOSM because I added some code the OSM SVN jmaplayer code.

comment:6 by bastiK, 15 years ago

It has improved a lot, thanks!

What I noticed after first testing:

  • There is no maximum zoom level anymore. These values should be hardcoded (18 for mapnik, 17 for osmarenderer).
  • The mapnik tiles don't look too good, when shrinked. The fonts are already at minimum possible size. (see screenshot)
  • Could we have mapnik as default? (Everyone who knows about t@h should be able to set the option. The rest might be more content with mapniks style.)

Apart from that it works really flawless, nice work. :)

by bastiK, 15 years ago

Attachment: Screenshot.png added

shrinked mapnik

in reply to:  6 comment:7 by hansendc, 15 years ago

Replying to bastiK:

It has improved a lot, thanks!

What I noticed after first testing:

  • There is no maximum zoom level anymore. These values should be hardcoded (18 for mapnik, 17 for osmarenderer).

Heh. There is one, but I set it to 30. :) I'll fix that up.

  • The mapnik tiles don't look too good, when shrinked. The fonts are already at minimum possible size. (see screenshot)

Again, this is more of a JOSM problem. We *HAVE* to scale these and JOSM's zooming limits how we're able to do that now. We're only going to be able to make big jumps in JOSM zoom levels if we try to make these look better.

For now, how about a "Snap to tile" option? Try this new version, and right click on the slippymap.

  • Could we have mapnik as default? (Everyone who knows about t@h should be able to set the option. The rest might be more content with mapniks style.)

Yeah, I can do that. The selection is actually broken at the moment, but I'll make it mapnik when I fix it up. I need to fix it up to use the jmapviewer list of tile servers.

Apart from that it works really flawless, nice work. :)

Very nice to hear. Thanks for the very quick testing.

comment:8 by bastiK, 15 years ago

"snap to tile" works nice.

There are still things to do:

  1. e. the lower zoom level tiles (that are shown while it is still downloading the appropriate zoom level) are just drawn as a square tile.

This way the smaller "good" tiles are covered by the coarse tiles for some time.

Could you please commit your work, so that others can help out?

comment:9 by hansendc, 15 years ago

Resolution: fixed
Status: newclosed

Hi bastiK,

I've committed the things that we've talked about so far. Please take a look. I'm going to resolve this bug, and we can follow up on any new enhancements in a new ticket.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.