Modify

Opened 15 years ago

Closed 10 years ago

#3016 closed defect (fixed)

Zoom limitations

Reported by: avarab@… Owned by: team
Priority: minor Milestone:
Component: Core Version: tested
Keywords: zoom Cc: Gubaer

Description (last modified by xeen)

Under r1816 I can:

  1. Open JoSM
  2. Create a new document with C-n
  3. Click around with the drawing tool to create new nodes

All of the nodes I'm creating will be added at lat/lon 0.0, furthermore I can't see them as I'm drawing them nor the lines between them (the only hint is the updated selection dialog).

I also can't scroll the mouse wheel to zoom in/out. Nor does the lat/lon display at the bottom of the screen update from 0.0/0.0. But I can grab the zoom adjuster and zoom out that way.

This also has nothing to do with my preferences since JOSM does the same thing once I move my preferences file elsewhere.

<?xml version='1.0' encoding='UTF-8'?>
<osm version='0.6' generator='JOSM'>
  <node id='-1' visible='true' lat='0.0' lon='0.0' />
  <node id='-2' visible='true' lat='0.0' lon='0.0' />
  <node id='-3' visible='true' lat='0.0' lon='0.0' />
  <node id='-4' visible='true' lat='0.0' lon='0.0' />
  <node id='-5' visible='true' lat='0.0' lon='0.0' />
  <way id='-6' action='modify' visible='true'>
    <nd ref='-1' />
    <nd ref='-2' />
    <nd ref='-3' />
    <nd ref='-4' />
    <nd ref='-5' />
  </way>
</osm>

Attachments (2)

scale.patch (580 bytes ) - added by landwirt@… 15 years ago.
set initial scale
wrong_deefault_zoom.patch (13.1 KB ) - added by xeen 15 years ago.
Adds a default zoom level method for each projection. The center is derived from the world bounds, this is why it doesn't (yet) work with Lambert projections. The comment says we do not handle handle coordinates outside the boundaries correctly, but doesn't go into further detail.

Download all attachments as: .zip

Change History (20)

comment:1 by avarab@…, 15 years ago

Priority: criticalblocker

I tested this with josm-tested.jar (r1788) where the bug didn't occur but it does happen in HEAD.

Marking this as a release blocker. JOSM versions with this bug are likely to upload corrupt data do the server.

comment:2 by Gubaer, 15 years ago

Cc: Gubaer added
Owner: changed from team to stoecker

Hmm, can't find it. Dirk? Any hint?

comment:3 by stoecker, 15 years ago

Priority: blockermajor
Summary: JOSM produces nodes with lat/lon 0.0 when I create a new OSM documentZoom limitations

Press <STRG>-<N> after josm Start.

The reason is that such a new datalayer is deep-zoomed and scroll-wheel zooming does help to get out. The accuracy of variables is not high enought to have any effect.

Fix: Prevent to deep zoom as well as zooming out of the world in NavigatableComponent.

  • Deepzoom: Maxzoomdepth = 0.1m
  • Maxzoom: Whole world could be visible
  • Zooming should not allow to zoom to positions outside of world

Remove the blocker as this affects only new layers which anyway should not be used for uploading anything.

in reply to:  3 comment:4 by anonymous, 15 years ago

Replying to stoecker:

Press <STRG>-<N> after josm Start.

The reason is that such a new datalayer is deep-zoomed and scroll-wheel zooming does help to get out. The accuracy of variables is not high enought to have any effect.

Fix: Prevent to deep zoom as well as zooming out of the world in NavigatableComponent.

  • Deepzoom: Maxzoomdepth = 0.1m
  • Maxzoom: Whole world could be visible
  • Zooming should not allow to zoom to positions outside of world

Remove the blocker as this affects only new layers which anyway should not be used for uploading anything.

They should not, but I had in mind the inexperienced user who might create a new layer, try to edit something, not notice any changes and then discovering the download button and not choosing "Download in a new layer". That would result 0.0/0.0 nodes uploaded to the server.

comment:5 by stoecker, 15 years ago

Resolution: fixed
Status: newclosed

Fixed in r1815 (I believe). Anyway is fixed now. No more deep zoom possible.

in reply to:  5 comment:6 by anonymous, 15 years ago

Resolution: fixed
Status: closedreopened

Replying to stoecker:

Fixed in r1815 (I believe). Anyway is fixed now. No more deep zoom possible.

When I open a new document in r1859 I get the exact same behavior described when I originally opened this bug report.

comment:7 by plaicy, 15 years ago

see also #3204

in reply to:  5 comment:8 by vsandre, 15 years ago

Version: latesttested

Replying to stoecker:

Fixed in r1815 (I believe). Anyway is fixed now. No more deep zoom possible.

You are right, you could not do a deep zoom yourself. But when starting josm it seems that the bbox is not set and so you starts in the deep zoom. The next Problem is that the zoom slider is in the middle position instead of being in the right. Zooming out once and you never get in the deep zoom back.

by landwirt@…, 15 years ago

Attachment: scale.patch added

set initial scale

comment:9 by anonymous, 15 years ago

Summary: Zoom limitations[patch] Zoom limitations

Till a proper fix arrives, just set an initial value for new layers, as mentioned in #3204.

comment:10 by xeen, 15 years ago

Owner: changed from stoecker to xeen
Status: reopenednew

Setting an initial scale only works for some projections. I'm still investigating a proper way to let each projection specify their own default center and zoom level, but I ran into NPEs that I suspect arise from some code parts being static (haven't found exact issue yet).

Also, fixing this is merely a minor issue, I only ever used new layers for testing. It's certainly not something the non-developer mapper will run into.

comment:11 by anonymous, 15 years ago

Priority: majorminor
Summary: [patch] Zoom limitationsZoom limitations

comment:12 by vsandre, 15 years ago

Keywords: zoom added

See also #3326

by xeen, 15 years ago

Attachment: wrong_deefault_zoom.patch added

Adds a default zoom level method for each projection. The center is derived from the world bounds, this is why it doesn't (yet) work with Lambert projections. The comment says we do not handle handle coordinates outside the boundaries correctly, but doesn't go into further detail.

comment:13 by xeen, 15 years ago

Summary: Zoom limitations[patch?] Zoom limitations

comment:14 by stoecker, 15 years ago

(In [2114]) see #3016 - patch by xeen - fixes some zooming issues

comment:15 by stoecker, 15 years ago

Summary: [patch?] Zoom limitationsZoom limitations

Well, probably not the best solution, but applied anyway. But I don't think the bug is closed yet. There are still other issues regarding e.g. switching projections when the switching moves center out of world.

Regarding coordinates outside the world: Nobody knows what these will be handled like. The projection code may work or it may produce invalid results. Currently JOSM ignores these problems totally. I have a method in mind to fix this - Move the outlying nodes near the next border and draw them there. Each projection should have a method to "FIX" outlying coordinates in some way for proper display.

comment:16 by xeen, 12 years ago

Description: modified (diff)
Owner: changed from xeen to team

comment:17 by Don-vip, 11 years ago

Is there something to do in this ticket or can we close it ?

comment:18 by Don-vip, 10 years ago

Resolution: fixed
Status: newclosed

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.