[GRASS-user] [gdal-dev] Working with NTF files (2)
    Nikos Alexandris 
    nik at nikosalexandris.net
       
    Wed Jul 31 01:55:27 PDT 2013
    
    
  
Yet another NITF related "problem". An ntf file contains (no SUBDATASETS)
gdalinfo -nogcp -nomd -mm M1BS.ntf
,--%<---
Band 1 Block=1024x1024 Type=UInt16, ColorInterp=Blue
    Computed Min/Max=183.000,2047.000
  Overviews: 3438x3448, 1719x1724, 859x862, 429x431, 214x215
  Overviews: arbitrary
Band 2 Block=1024x1024 Type=UInt16, ColorInterp=Green
    Computed Min/Max=252.000,2047.000
  Overviews: 3438x3448, 1719x1724, 859x862, 429x431, 214x215
  Overviews: arbitrary
Band 3 Block=1024x1024 Type=UInt16, ColorInterp=Red
    Computed Min/Max=86.000,2047.000
  Overviews: 3438x3448, 1719x1724, 859x862, 429x431, 214x215
  Overviews: arbitrary
Band 4 Block=1024x1024 Type=UInt16, ColorInterp=Alpha
    Computed Min/Max=50.000,2047.000
  Overviews: 3438x3448, 1719x1724, 859x862, 429x431, 214x215
  Overviews: arbitrary
`--->%--
Attempting to warp the data with the -rpc switch and convert to GeoTIFF, 
begins with
"Using band 4 of source image as alpha."
This results in an "empty" NIR band  in the GeoTIFF file.
,--%<---
Band 1 Block=6728x1 Type=UInt16, ColorInterp=Gray
    Computed Min/Max=0.000,2047.000
Band 2 Block=6728x1 Type=UInt16, ColorInterp=Undefined
    Computed Min/Max=0.000,2047.000
Band 3 Block=6728x1 Type=UInt16, ColorInterp=Undefined
    Computed Min/Max=0.000,2047.000
Band 4 Block=6728x1 Type=UInt16, ColorInterp=Undefined
    Computed Min/Max=0.000,0.000
`--->%--
No success using '-co "ALPHA=NO"'.  Same "problem" when using gdal_translate 
on the whole ntf file. However, instructing 
gdal_translate -b 4 M1BS.ntf b4.tif
gives
gdalinfo -nogcp -nomd -mm b4.tif
,--%<---
Band 1 Block=6876x1 Type=UInt16, ColorInterp=Gray
    Computed Min/Max=50.000,2047.000
`--->%--
But, this is not "fine". How is this to be done correctly, RPC-based warping 
and conversion in one go?
Thanks, Nikos
    
    
More information about the grass-user
mailing list