[gdal-dev] ICORDS error creating NITF with BLOCKA
Jacklin Matthew D
MDJACKLIN at qinetiq.com
Fri May 21 10:42:49 EDT 2010
Hi,
I am trying to create a NITF file using the BLOCKA extension but the
ICORDS field in the resulting file appears to be incorrect.
The following is an example attempt - the lat/lon positions are in
decimal format and the ICORDS field is set to be "D" (decimal). However
after processing the resulting NITF file has an ICORDS field of "G"
(geographic) and as the IGEOLO fields are in decimal format the NITF
file is invalid.
REM format is lat: "+dd.dddddd" and lon: +ddd.dddddd"
set ul_lat=+51.236900
set ul_lon=-002.053840
set lr_lat=+51.233300
set lr_lon=-002.042380
set a=-co "BLOCKA_BLOCK_COUNT=1"
set b=-co "BLOCKA_BLOCK_INSTANCE_01=01"
set c=-co "BLOCKA_N_GRAY_01=00000"
set d=-co "BLOCKA_L_LINES_01=01000"
set e=-co "BLOCKA_LAYOVER_ANGLE_01= "
set f=-co "BLOCKA_SHADOW_ANGLE_01= "
REM set g=-co "BLOCKA_BLANKS_01=16 chars"
set h=-co "BLOCKA_FRLC_LOC_01=%lr_lat%%ul_lon%"
set i=-co "BLOCKA_LRLC_LOC_01=%lr_lat%%lr_lon%"
set j=-co "BLOCKA_LRFC_LOC_01=%ul_lat%%lr_lon%"
set k=-co "BLOCKA_FRFC_LOC_01=%ul_lat%%ul_lon%"
gdal_translate -of NITF -a_srs WGS84 -a_ullr ul_lon ul_lat lr_lon lr_lat
a% %b% %c% %d% %e% %f% %h% %i% %j% %k% -co "ICORDS=D" input.png
output.ntf
I have also noticed if the BLOCKA_L_LINES fields is less than the actual
number of lines in the input file, it appears the ICORDS field will be
set to "G" and the IGEOLO fields will be converted to geographic
format?!
Any ideas or help appreciated.
Thanks.
Matt Jacklin.
This email and any attachments to it may be confidential and are
intended solely for the use of the individual to whom it is
addressed. If you are not the intended recipient of this email,
you must neither take any action based upon its contents, nor
copy or show it to anyone. Please contact the sender if you
believe you have received this email in error. QinetiQ may
monitor email traffic data and also the content of email for
the purposes of security. QinetiQ Limited (Registered in England
& Wales: Company Number: 3796233) Registered office: 85
Buckingham Gate, London SW1E 6PD http://www.qinetiq.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20100521/b9ed62a6/attachment.html
More information about the gdal-dev
mailing list