[Gdal-dev] Re: [Mapserver-users] offtopic ADRG to TIFF
Frank Warmerdam
warmerdam at pobox.com
Wed Apr 9 10:45:18 EDT 2003
Jorge Alberto Arocha Muñoz wrote:
> Hi,
>
> I need any software for convert images in ADRG format to format TIFF o
> GeoTIFF.
Jorge,
The GDAL library can support ADRG if built with OGDI support. If you download
the OpenEV_FW 1.5.4 release for Linux or windows from:
ftp://ftp.remotesensing.org/gdal/openev/
you should be able to use GDAL to do something like:
gdal_translate gltp:/adrg/usr4/mpp1/adrg/TPUS0101 out.tif
Note that the "gltp:/adrg" portion tells GDAL to use the OGDI gateway,
and for the OGDI gateway to use the adrg driver. The rest is a real
path to the dataset.
However, most (all?) ADRG files appear to GDAL as subdatasets so you should
do something like:
warmerda at gdal[108]% gdalinfo gltp:/adrg/usr4/mpp1/adrg/TPUS0101
Driver: OGDI/OGDI Bridge
Size is 1000, 1000
Coordinate System is:
GEOGCS["WGS 84",
DATUM["unknown",
SPHEROID["WGS84",6378137,298.257223563]],
PRIMEM["Greenwich",0],
UNIT["degree",0.0174532925199433]]
Origin = (-88.000183,36.000089)
Pixel Size = (0.007001,-0.004000)
Subdatasets:
SUBDATASET_1_NAME=gltp:/adrg/usr4/mpp1/adrg/TPUS0101:"TPUS0101.IMG":Matrix
SUBDATASET_1_DESC=TPUS0101.IMG as Matrix
SUBDATASET_2_NAME=gltp:/adrg/usr4/mpp1/adrg/TPUS0101:"TPUS0102.IMG":Matrix
SUBDATASET_2_DESC=TPUS0102.IMG as Matrix
SUBDATASET_3_NAME=gltp:/adrg/usr4/mpp1/adrg/TPUS0101:"TPUS0101.IMG":Image
SUBDATASET_3_DESC=TPUS0101.IMG as Image
SUBDATASET_4_NAME=gltp:/adrg/usr4/mpp1/adrg/TPUS0101:"TPUS0102.IMG":Image
SUBDATASET_4_DESC=TPUS0102.IMG as Image
Corner Coordinates:
Upper Left ( -88.0001833, 36.0000889) ( 88d 0'0.66"W, 36d 0'0.32"N)
Lower Left ( -88.0001833, 31.9998278) ( 88d 0'0.66"W, 31d59'59.38"N)
Upper Right ( -80.9996083, 36.0000889) ( 80d59'58.59"W, 36d 0'0.32"N)
Lower Right ( -80.9996083, 31.9998278) ( 80d59'58.59"W, 31d59'59.38"N)
Center ( -84.4998958, 33.9999583) ( 84d29'59.63"W, 33d59'59.85"N)
Band 1 Block=1000x1 Type=Byte, ColorInterp=Red
Overviews: arbitrary
Band 2 Block=1000x1 Type=Byte, ColorInterp=Green
Overviews: arbitrary
Band 3 Block=1000x1 Type=Byte, ColorInterp=Blue
Overviews: arbitrary
Band 4 Block=1000x1 Type=Byte, ColorInterp=Alpha
Overviews: arbitrary
Band 5 Block=1000x1 Type=Byte, ColorInterp=Red
Overviews: arbitrary
Band 6 Block=1000x1 Type=Byte, ColorInterp=Green
Overviews: arbitrary
Band 7 Block=1000x1 Type=Byte, ColorInterp=Blue
Overviews: arbitrary
Band 8 Block=1000x1 Type=Byte, ColorInterp=Alpha
Overviews: arbitrary
warmerda at gdal[109]% gdal_translate gltp:/adrg/usr4/mpp1/adrg/TPUS0101:"TPUS0102.IMG":Matrix tpus0102.tif
Input file size is 11904, 8960
0...10...20...30...40...50...60...70...80...90...100 - done.
The key here is picking out the appropriate SUBDATASET_n_NAME's from the
metadata for the overall dataset.
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