[Gdal-dev] LANDSAT7 format question: GLCF

Markus Neteler neteler at itc.it
Fri Mar 9 04:54:40 EST 2007


On Fri, Mar 09, 2007 at 09:33:39AM +0100, Markus Neteler wrote:
> On Thu, Mar 08, 2007 at 10:24:24PM -0500, Mario Beauchamp wrote:
> > On 3/8/07, Markus Neteler <neteler at itc.it> wrote:
> > >Hi,
> > >
> > >for the upcoming OSGeo educational data set I would like
> > >to process
> > >ftp://ftp.glcf.umiacs.umd.edu/glcf/Landsat/WRS2/p016/r035/p016r035_7x20000331.ETM-EarthSat
> > >(LANDSAT7)
> > >Apparently the format isn't recognized or I am doing something
> > >wrong.
> > 
> > You might want to take a look at
> > http://glcf.umiacs.umd.edu/data/guide/fileformat/
> > and http://glcf.umiacs.umd.edu/data/guide/namingconvention/
> > 
> > And I remember I had to do a bit of hacking to get GDAL to read those
> > files but for the life of me, I cannot remember what!! Try gdalinfo on
> > each .b0x, .hdr, .ip3, etc until it recognizes something...

I have hacked the .hdr file to get the correctly FILENAME extracted):

diff -u p016r035_7p20000331.hdr.org p016r035_7p20000331.hdr
--- p016r035_7p20000331.hdr.org 2007-03-09 10:26:53.000000000 +0100
+++ p016r035_7p20000331.hdr     2007-03-09 10:27:21.000000000 +0100
@@ -12,7 +12,7 @@
 START LINE # =      BLOCKING FACTOR =   REC SIZE  =200832593 PIXEL SIZE =14.25
 OUTPUT BITS PER PIXEL =8  ACQUIRED BITS PER PIXEL =8
 BANDS PRESENT =8
-FILENAME =L72016035_03520000331_B80.FSTFILENAME =
+FILENAMEL72016035_03520000331_B80.FST  FILENAME =
 FILENAME =                             FILENAME =
 FILENAME =                             FILENAME =

Then set a link (since the FILENAME is different):
ln -s p016r035_7p20000331.b01 L72016035_03520000331_B80.FST

Now it reports at least:
gdalinfo p016r035_7p20000331.hdr
Driver: FAST/EOSAT FAST Format
Size is 15352, 13081
Coordinate System is `'
Origin = (0.000000000000000,0.000000000000000)
Pixel Size = (1.000000000000000,1.000000000000000)
Metadata:
  ACQUISITION_DATE=20000331
  SATELLITE=LANDSAT7
  SENSOR=ETM+
  BIAS1=-5.675590383724904
  GAIN1=0.975590574459767
Corner Coordinates:
Upper Left  (   0.0000000,   0.0000000)
Lower Left  (       0.000,   13081.000)
Upper Right (   15352.000,       0.000)
Lower Right (   15352.000,   13081.000)
Center      (    7676.000,    6540.500)
Band 1 Block=15352x1 Type=Byte, ColorInterp=Undefined

The next trick would be to make it read UL, UR, LL, LR...
I assume that it is also shifted a bit (white space or such) in
ftp://ftp.glcf.umiacs.umd.edu/glcf/Landsat/WRS2/p016/r035/p016r035_7x20000331.ETM-EarthSat/p016r035_7p20000331.hdr

Maybe everything is there, but just the positions a bit messed
up in the hdr file. Unfortunately my C++ knowledge doesn't suffice to
modify 
frmts/raw/fastdataset.cpp
accordingly.

best,
Markus


------------------
ITC -> dall'1 marzo 2007 Fondazione Bruno Kessler
ITC -> since 1 March 2007 Fondazione Bruno Kessler
------------------




More information about the Gdal-dev mailing list