[Gdal-dev] rotations in Get/SetGeoTransform
Stephane Routelous
route at cae.com
Fri Oct 1 14:21:44 EDT 2004
Hi Frank,
thanks a lot for your answer. I didn't thought about that.
But I have another question :
what if I want to convert my image format with the GCPs to a gdal originaly
supported format( ex : asciigrid ), or reverse ?
How can I convert those GCPs into/from geotransform ?
I checked the aaigriddataset.cpp file (as example), and there is no
reference or conversion from GCPs.
thanks a lot for your time.
Stephane
-----Original Message-----
From: Frank Warmerdam [mailto:warmerdam at pobox.com]
Sent: Friday, October 01, 2004 1:07 PM
To: Stephane Routelous
Cc: 'Gdal-Dev (E-mail)
Subject: Re: [Gdal-dev] rotations in Get/SetGeoTransform
Stephane Routelous wrote:
> I need to make a driver for GDAL, where the georeferencement of the image
is
> defined in an XML file with the 4 corners of the image in decimal degrees.
> So, I need to transform those 4 points into this transformation matrix.
>
> The other problem I have is that the image can be "stretched". Basically,
it
> means that I can have the 4 points like :
> P1(0,0)
> P2(-2,2)
> P3(2,3)
> P4(4,1)
>
> In this case, the image is not just rectangular and rotated anymore,
because
> the angle between the x-axis an P1-P4 is different than the angle betwen
the
> y-axis and P1-P2
Stephane,
The normal approach to this is to leave the GetGeoTransform() method
defaulted,
and instead implement this as an image with 4 ground control points (GCPs).
Best regards,
--
---------------------------------------+------------------------------------
--
I set the clouds in motion - turn up | Frank Warmerdam,
warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush | Geospatial Programmer for Rent
More information about the Gdal-dev
mailing list