Skip to main content

I have a jp2 and jpw file. Reading the jp2 results in the data inspector showing the resulting data in the wrong location. How can I fix the location? I've tried setting the coordinate system on the reader but that doesn't fix it. I know the j2w file holds information about the location of the jp2 but I don't know how to read it along with the jp2. I know I'm likely missing something simple so I appreciate the help.

If you open the j2w file in a text editor you should see 6 lines, lines 1 and 4 contain the pixel size in x and negative y direction, lines 5 and 6 are the x and y coordinates of the center of the top left pixel.

 

Do those values match what you expect to see?


If you open the j2w file in a text editor you should see 6 lines, lines 1 and 4 contain the pixel size in x and negative y direction, lines 5 and 6 are the x and y coordinates of the center of the top left pixel.

 

Do those values match what you expect to see?

the xy matches where it's being shown in data inspector but they're not the xy of the actual location.


the xy matches where it's being shown in data inspector but they're not the xy of the actual location.

Okay, your j2w file is wrong then. If the pixel sizes are correct and you know what the x and y should be you can simply use an Offsetter to move it to the correct location. If it's a one-time thing you may also simply edit the file manually. If this has to be done more often you should check with whoever is supplying the file though.


the xy matches where it's being shown in data inspector but they're not the xy of the actual location.

I see. Thank you


Reply