On 07/06/11 22:54, mett wrote:

Jean-Claude Repetto wrote:

Probably because your projection is not cylindrical. What projection are
you using ?

The projection is
`PROJCS["User-Defined WGS84/Lambert Conformal Conic (IS.)",GEOGCS["WGS
84",DATUM["WGS_1984",SPHEROID["WGS
84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433],AUTHORITY["EPSG","4326"]],PROJECTION["Lambert_Conformal_Conic_2SP"],PARAMETER["standard_parallel_1",64.25],PARAMETER["standard_parallel_2",65.75],PARAMETER["latitude_of_origin",65],PARAMETER["central_meridian",-19],PARAMETER["false_easting",500000],PARAMETER["false_northing",500000],UNIT["metre",1,AUTHORITY["EPSG","9001"]]]'

I did the follow step:
- Got the Upper Left corner of the image with
GetGeoTransform(adfGeoTransform)
- Found out the others corners in this way:
double miny = adfGeoTransform[3] + width*adfGeoTransform[4] +
height*adfGeoTransform[5];
double maxx = adfGeoTransform[0] + width*adfGeoTransform[1] +
height*adfGeoTransform[2];
- Convert all these 4 points related to the corners with TransformPoint();

So, what should I do to have correct values from the conversion? I cannot
find a good solution.


I think your results are correct, because PROJ.4 gives exactly the same ones :

proj -I -f "%.12f" +proj=lcc +lat_1=64.25 +lat_2=65.75 +lat_0=65 +lon_0=-19 +x_0=500000 +y_0=500000 +datum=WGS84 +units=m +no_defs
258321.25943477 655225.28062628
-24.391630217716        66.299640570965
258321.25943477 574605.28062628
-24.242820669640        65.579229590843

Jean-Claude
_______________________________________________
gdal-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to