How to do Latitude/Longitude for Lambert Geotiff with Model Transform Tag Matrix?

StackOverflow https://stackoverflow.com/questions/22214249

  •  10-06-2023
  •  | 
  •  

سؤال

I have a number of charts using lambert transformation. Some of them use the Tie Point tag. For this I have figured out the Lat/Long<=>X,Y transformation.

I also have some charts that use a model transform tag instead. So far I am unable to figure out how to do the point conversion.

The Geotiff documentation says Model-Coordinates = Matrix * Image Coordinates

One chart has this matrix.

798.320542  0.009593987 0   -6084843.93
0.020321671 -798.350061 0   3716484.45
0                     0 0   0
0                     0 0   1 

Through Photoshop I have found

9572    2107 (X/Y) corresponds to 50N on the prime meridian and that
4957    410 corresponds to 60N 60W

When I multiply the matrices (vectors transposed) I get

M * [9572   2107 0 1] = [1556700.513 2034555.391 0 1]
M * [4957   410 0 1] = [-2127565.07 3389261.66 0 1]

I don't get anything like the degrees (radians) I am expecting. Nor does reversing the X/Y. This leads me to believe that I am missing something.

What I have I left out from the Pixel to Geo coordinate transformation?

Here are some of the other Geotiff data

Image Width                     : 24000
Image Height                    : 7998
Proj Linear Units               : Linear Meter
Proj Std Parallel 1             : 45
Proj Std Parallel 2             : 33
Proj Nat Origin Long            : -95
Proj False Origin Long          : -95
Proj False Origin Lat           : 39
Proj False Origin Easting       : 0
Proj False Origin Northing      : 0
هل كانت مفيدة؟

المحلول

For pixel to lat/lon, the input vector is, [x, y, 0, 1] transformed. Post multiplying the transform matrix by the vector gives (x, y) coordinates for the lambert transform.

For the reverse, do the inverse lambert transform to get the (x, y) coordinates. Then you you have to solve a 2x2 system of linear equations to get the pixel locations.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top