[Gdal-dev] Save GeoTiff
Frank Warmerdam
warmerdam at pobox.com
Tue Mar 11 11:19:43 EST 2003
Ayman Kamal wrote:
> I debugged through "gdal_translate" demo application
> and found that the two functions I care about are:
>
> poVDS->SetProjection( pszProjection );
> poVDS->SetGeoTransform( adfGeoTransform );
>
> I know that pszProjection is the projection string,
> and adfGeoTransform is likely coordinates of area.
>
> I want to know what are the minimum parameters that I
> have to provide for both those functions to generate a
> GeoTiff file?
>
> And if you can help me to know what are the different
> possiblities of (valid) parameters ranges that can be entered?
Ayman,
I presume you received and reviewed my last email demonstrating
SetGeoTransform(). If you have specific questions let me know.
The SetProjection() method (like most other methods) is documented
at:
http://www.remotesensing.org/gdal/class_GDALDataset.html
You may want to read this topic for a little greater understanding of
the OpenGIS Well Known Text format for coordinate system definitions:
http://gdal.velocet.ca/projects/opengis/ogrhtml/osr_tutorial.html
Depending on the generality of solution you need, it is generally a good
idea to generate sample GeoTIFF files for the coordinate systems you want
and then use gdalinfo to dump the corresponding "WKT". You can then
manipulate the actual parameter values as needed in your actual code, or
use the OGRSpatialReference methods to create a WKT string.
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