Frank,
I have just begun using GDAL to work with NITF images. Nice package. Thankyou. I needed a few new features and added them. Attached is a patch file you can do with as you will. The changes do this:
$ Add NITF_ICORDS to the dataset's metadata.
$ Add all ICHIPB fields to the metadata.
$ Read RPC00A exactly as RPC00B is read.
(I've never been able to see any difference between the A and B versions. The gov't's
STDI-0002-version-2.1-16-Nov-2000.pdf document says they differ in some coefficient ordering, but comparing with STDI-0002-version-1.0-25-Aug-1998.pdf, I see no difference at all.)
I think you might want to move the ICORDS change to a different spot and change the comments. There are also /*DRM:*/ comments you'll want to remove. They mark every change.
FYI, I needed NITF_ICORDS to interface with some annotation feature of IMAGINE with a NITF reader module.
Here are some possible bug/deficiencies I noticed while poking around:
- The NITF_MIN/MAX_LAT/LONG metadata items look wrong. The RPC region usually straddles LAT/LONG_OFFSET by LAT/LONG_SCALE. However, the metadata items begin at LAT/LONG_OFFSET and extend from there by 2*LAT/LONG_OFFSET
- The RPC projection code doesn't know about ICHIPB and so will incorrectly project points for a NITF file with ICHIPB.
- The ERR_BIAS and ERR_RAND RPC00B fields aren't put in the dataset's metadata.
Thanks again for GDAL,
Doug