Modify

Opened 12 years ago

Last modified 5 years ago

#7966 new defect

georef images wrong displayed after switching to correct projection

Reported by: skyper Owned by: rebsc
Priority: normal Milestone:
Component: Plugin piclayer Version:
Keywords: Cc:

Description (last modified by skyper)

  1. load .zip file containing jpeg + ref file in mercator projection
  2. switch to correct projection (Gauß-Krüger 3).

The picture(s) are misaligned which is really obvious if using several. Seems to exist for a long time and is 100% reproducable with Aerowest pictures.

First switching to correct projection and then opening the files works perfectly.

Repository Root: http://josm.openstreetmap.de/svn
Build-Date: 2012-08-15 01:31:10
Last Changed Author: akks
Revision: 5443
Repository UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
URL: http://josm.openstreetmap.de/svn/trunk
Last Changed Date: 2012-08-14 10:07:01 +0200 (Tue, 14 Aug 2012)
Last Changed Rev: 5443

Identification: JOSM/1.5 (5443 de)
Memory Usage: 976 MB / 976 MB (537 MB allocated, but free)
Java version: 1.6.0_24, Sun Microsystems Inc., OpenJDK 64-Bit Server VM
Operating system: Linux
Dataset consistency test: No problems found

Plugin: PicLayer (27883)
Plugin: utilsplugin2 (28551)

Attachments (0)

Change History (11)

comment:1 by skyper, 12 years ago

Description: modified (diff)

comment:2 by Larry0ua, 12 years ago

I see PicLayer code uses Main.getProjection() to convert to/from screen and latlon coordinates. Which behavior is needed?

Should I cache projection and tie it to picture layer and not share them between different layers?

How can I get projection name from world file (or what is used in that archive?)

How can I translate projection name to Projection using JOSM core to support future adding of some rare projections? I see only ProjectionPreferences that could work for me, but it is really not easily extendable and configurable

comment:3 by Larry0ua, 12 years ago

related to #7144

in reply to:  2 comment:4 by bastiK, 12 years ago

Replying to Larry0ua:

I see PicLayer code uses Main.getProjection() to convert to/from screen and latlon coordinates. Which behavior is needed?

Should I cache projection and tie it to picture layer and not share them between different layers?

You can either register a ProjectionChangeListener, like in MultipolygonCache, or save the projection and check on each access, like in CachedLatLon.

How can I get projection name from world file (or what is used in that archive?)

World file does not contain a projection, it assumes, that the projection is already known. Especially for the Aerowest imagery, there is no hint in the zip archive.

How can I translate projection name to Projection using JOSM core to support future adding of some rare projections? I see only ProjectionPreferences that could work for me, but it is really not easily extendable and configurable

That depends on what you mean by projection name. There is Projection.toCode and ProjectionInfo.getProjectionByCode for example.

comment:5 by Larry0ua, 12 years ago

Can you show scenario when projection is changed with some more details? I mean with files (or links to the files) and steps - when any projection is changed and what is the expected result on the each step. Sorry, I still cannot get what the issue is

comment:6 by bastiK, 12 years ago

  • Open any image with PicLayer, move it to a certain place (align against Bing or OSM background).
  • Go to preferences (F12), 3rd tab. Change map projection to something else, e.g. WGS84 or the UTM zone for your region.

Result: Image is moved to a random place on earth, there are no longer the same coordinates (lat/lon) in the center of the image.

comment:7 by Larry0ua, 12 years ago

appreciate any help with this bug - simple caching of Projection object did not help.

comment:8 by skyper, 12 years ago

Strange, today it worked changing from Mercator to Gauß-Krüger 3. I have to say though that the images have never been displayed with mercator but that is fine.

Last edited 12 years ago by skyper (previous) (diff)

comment:9 by skyper, 12 years ago

Can not reproduce. At least my part seems to be fixed.

Repository Root: http://josm.openstreetmap.de/svn
Build-Date: 2012-10-05 01:31:10
Last Changed Author: bastiK
Revision: 5530
Repository UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
URL: http://josm.openstreetmap.de/svn/trunk
Last Changed Date: 2012-10-04 23:31:21 +0200 (Thu, 04 Oct 2012)
Last Changed Rev: 5530

Identification: JOSM/1.5 (5530 de)
Memory Usage: 610 MB / 610 MB (198 MB allocated, but free)
Java version: 1.6.0_24, Sun Microsystems Inc., OpenJDK 64-Bit Server VM
Operating system: Linux
Dataset consistency test: No problems found

Plugin: PicLayer (28660)
Plugin: terracer (28656)
Plugin: utilsplugin2 (28656)

comment:10 by skyper, 11 years ago

As my part is fixed this seems to be a duplicate of #7144.

comment:11 by Don-vip, 5 years ago

Owner: changed from Larry0ua to rebsc

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain rebsc.
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from rebsc to the specified user.
Next status will be 'needinfo'. The owner will be changed from rebsc to skyper.
as duplicate The resolution will be set to duplicate. Next status will be 'closed'. The specified ticket will be cross-referenced with this ticket.
The owner will be changed from rebsc to anonymous. Next status will be 'assigned'.

Add Comment


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