Opened 20 years ago

Closed 15 years ago

#605 closed defect (fixed)

NITF Improvements Offered

Reported by: warmerdam Owned by: warmerdam
Priority: normal Milestone: 1.7.0
Component: GDAL_Raster Version: unspecified
Severity: normal Keywords: nitf
Cc: dougrm@…

Description (last modified by warmerdam)

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

Attachments (2)

diffs (5.5 KB ) - added by warmerdam 20 years ago.
Provided patch
nitfimage.c (71.2 KB ) - added by warmerdam 17 years ago.

Download all attachments as: .zip

Change History (9)

by warmerdam, 20 years ago

Attachment: diffs added

Provided patch

comment:1 by warmerdam, 17 years ago

Description: modified (diff)
Milestone: 1.5.0
Priority: highnormal
Status: newassigned

This needs to be reviewed and considered for 1.5.0. NITF is important to our sponsors.

by warmerdam, 17 years ago

Attachment: nitfimage.c added

comment:2 by warmerdam, 17 years ago

Frank,

One more thing, my email didn't disappear, I just couldn't find it right off. The source of the coefficient ordering was from the files ossimRpcModel.cpp and ossimNitfRpcModel.cpp from http://www.remotesensing.org/ossim/

Searching the code for thePolyType shows the interesting bits.

Doug

comment:3 by warmerdam, 16 years ago

Description: modified (diff)
Keywords: nitf added
Milestone: 1.5.01.6.0

Deferring to 1.6. Also of note may be #2040 about RPC00A vs. RPC00B.

comment:4 by Even Rouault, 15 years ago

I think that all what was contained in the patch has been implemented. ICHIPB reading was added in r6864 (in a slightly different but equivalent form from the patch)

comment:5 by hobu, 15 years ago

Even, this is a 1.7 ticket now, correct?

comment:6 by Even Rouault, 15 years ago

Milestone: 1.6.11.7.0

To me it looks like this ticket could be closed as AFAIK all elements in the patch have ended up being incorporated in gdal, but I'll let FrankW confirm. But for sure, this is certainly not a 1.6.1 ticket.

comment:7 by warmerdam, 15 years ago

Resolution: fixed
Status: assignedclosed

I believe this to be the case. Closing.

I feel bad we didn't make better use of Doug's contribution.

Note: See TracTickets for help on using tickets.