[gdal-dev] Copy coordinate system and corner coordinates

Chaitanya kumar CH chaitanya.ch at gmail.com
Tue Jun 22 04:43:13 EDT 2010


Alessandro,

Refer to http://www.gdal.org/gdal_tutorial.html for a tutorial on how to do
handle raster data with GDAL.
Look closely at GDALCreateCopy() or GDALDriver::CreateCopy().

On Tue, Jun 22, 2010 at 1:33 PM, canduc17 <candini at meeo.it> wrote:

>
> I have an input dataset like this:Driver: GTiff/GeoTIFF
> Files: aot.2007154.0950.geo.tif
> Size is 5657, 2287
> Coordinate System is:
> GEOGCS["WGS 84",
>    DATUM["WGS_1984",
>        SPHEROID["WGS 84",6378137,298.2572235630016,
>            AUTHORITY["EPSG","7030"]],
>        AUTHORITY["EPSG","6326"]],
>    PRIMEM["Greenwich",0],
>    UNIT["degree",0.0174532925199433],
>    AUTHORITY["EPSG","4326"]]
> Origin = (0.452892184257507,72.917350769042969)
> Pixel Size = (0.010000000000000,-0.010000000000000)
> Metadata:
>  AREA_OR_POINT=Area
> Image Structure Metadata:
>  COMPRESSION=LZW
>  INTERLEAVE=BAND
> Corner Coordinates:
> Upper Left  (   0.4528922,  72.9173508) (  0d27'10.41"E, 72d55'2.46"N)
> Lower Left  (   0.4528922,  50.0473508) (  0d27'10.41"E, 50d 2'50.46"N)
> Upper Right (  57.0228922,  72.9173508) ( 57d 1'22.41"E, 72d55'2.46"N)
> Lower Right (  57.0228922,  50.0473508) ( 57d 1'22.41"E, 50d 2'50.46"N)
> Center      (  28.7378922,  61.4823508) ( 28d44'16.41"E, 61d28'56.46"N)
> Band 1 Block=5657x1 Type=Float32, ColorInterp=Gray



> and I want to copy
> coordinate system, origin, pixel size and corner coordinates from this
> dataset to the output one.
> How to do this in C++?
> Thanks in advance.
> --
> View this message in context:
> http://osgeo-org.1803224.n2.nabble.com/Copy-coordinate-system-and-corner-coordinates-tp5207721p5207721.html
> Sent from the GDAL - Dev mailing list archive at Nabble.com.
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev
>



-- 
Best regards,
Chaitanya kumar CH.
/tʃaɪθənjə/ /kʊmɑr/
+91-9494447584
17.2416N 80.1426E
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20100622/c048a463/attachment.html


More information about the gdal-dev mailing list