[gdal-dev] Re: Help with setting GCPs in a GeoTiff

matt.feemster matt.feemster at ga-asi.com
Fri Oct 7 10:44:05 EDT 2011


Thanks for the help guys. I've managed to figure it out in code.

A quick note though, wouldn't X correspond to lon (increase/decrease
horizontally) and Y correspond to lat (increase/decrease vertically)?

And shouldn't the far pixel count be the extent minus one since it's zero
indexed?

Here is an example of the way I am setting up the upper right corner in
code.

gcpList[1].dfGCPPixel = width - 1;
gcpList[1].dfGCPLine = 0;
gcpList[1].dfGCPX = ur.lng;
gcpList[1].dfGCPY = ur.lat;
gcpList[1].dfGCPZ = ur.hae;

Let me know if this is correct?

Regarding this:

http://www.gdal.org/gdal_datamodel.html

More concrete information and examples there on GCPs would be helpful.

Thanks.


--
View this message in context: http://osgeo-org.1803224.n2.nabble.com/Help-with-setting-GCPs-in-a-GeoTiff-tp6867532p6869597.html
Sent from the GDAL - Dev mailing list archive at Nabble.com.


More information about the gdal-dev mailing list