It is intended that nearly all associated binary data files have the same format provided by the label service utility routines. Each record of an associated file has the following format:
Length Type Key Char Data Data (B,I*2,I*4,R*4,R*8) ------------------------------------------------------- | | | | | | | 13 Char | 3 Char | 16 Char | x Bytes | y Bytes | | | | | | | -------------------------------------------------------
The DDR file contains descriptive image information. There is one DDR file per image. This file is in label services format. The DDR file structure contains the following label service records for each image:
First record
long nl; /* number of lines in image */ long ns; /* number of samples in image */ long nbands; /* number of bands in image */ long dtype; /* data type of samples: */ /* =1: unsigned char */ /* =2: short /* /* =3: long /* /* =4: float /* long master_line; /* line relative to master image */ long master_sample;/* sample relative to master image */ long valid[8]; /* valid flags: */ /* =0: INVALID /* =1: VALID /* =2: UNKNOWN /* valid[0] => projection code */ /* valid[1] => zone code */ /* valid[2] => datum code */ /* valid[3] => proj_coef */ /* valid[4] => ground units */ /* valid[5] => ground distance */ /* valid[6] => corner coordinates */ /* valid[7] => line/sample increments */ long proj_code; /* GCTP projection code */ long zone_code; /* UTM or State Plane zone */ long datum_code; /* GCTP datum code */ long spare; /* spare integer value for future use */ char system[12] /* computer system data is on */ char proj_units[12]; /* Projection units (GCTP units+other) */ char last_used_date[12]; /* last modified date */ /* NOTE: All ddr dates are stored as: */ /* "dd-mmm-yy". For example, a date */ /* of December 31, 1986 is stored as: */ /* "31-dec-86" with month in lower */ /* case. */ char last_used_time[11]; /* last modified time */ /* NOTE: All ddr times are stored */ /* using a twenty-four hour clock. */ /* Seconds are separated by a colon. */ /* Example: 1:05:55 pm is stored as */ /* 1305:55 */ /* Note that this field is not zero /* terminated in the file. */Second record
double proj_coef[15]; /* GCTP projection parameters */ /* refer to GCTP documentation for */ /* field definitions */ double upleft[2]; /* Corner coordinates entered */ double loleft[2]; /* in latitude/longitude or */ double upright[2]; /* northing/easting order */ double loright[2]; /* projection coordinates (y,x) */ double pdist_y; /* projection distance/pixel (y) */ double pdist_x; /* projection distance/pixel (x) */ double line_inc; /* line increment for sampling */ double sample_inc; /* sample increment for sampling */ /* NOTE: The line/sample increments are */ /* the values applied to the original */ /* image to obtain this image. If re- */ /* or sub-sampling was not applied, */ /* value contained in these fields is */ /* 1.0 */Third + records (One record for each band)
double minval; /* minimum intensity value */ double maxval; /* maximum intensity value */ /* Band DDR string data */ char bandno[4]; /* band number */ char valid[2]; /* validity flag for min/max */ /* =0: INVALID */ /* =1: VALID */ /* =2: BOUNDED */ char source[32]; /* source of data */ char instrument[32]; /* type of sensor */ char direction[64]; /* direction of the capture process */ char date[10]; /* capture date (See date format above) */ char time[8]; /* capture time (See time format above) */ /* Note that this field is not zero /* terminated in the file. */The format for the DDR file follows:
First record
Length Type Key Char Data Integer Data ------------------------------------------------------- | | | | | | | 13 Char | 3 Char | 16 Char | 47 Bytes | 72 Bytes | | | | | | | -------------------------------------------------------Second record
Length Type Key Double Data ------------------------------------------ | | | | | | 13 Char | 3 Char | 16 Char | 216 Bytes | | | | | | ------------------------------------------Third record +, one record for each band
Length Type Key Char Data Double Data ------------------------------------------------------- | | | | | | | 13 Char | 3 Char | 16 Char | 151 Bytes | 16 Bytes | | | | | | | -------------------------------------------------------
This file contains lookup table data. The DLTF stores parameters necessary to redisplay an image in the same state in which it was last viewed. A user may save an image at any step in processing and thus always be able to return to that point without having to execute the modules necessary to recreate the image. The DLTF format follows:
First record
Length Type Key Window Zoom Shift Description ----------------------------------------------------------------------- | | | | | | | | | 13 Char | 3 Char | 16 Char | 28 Char | 32 Char | 32 Char | 81 Char | | | | | | | | | ----------------------------------------------------------------------- #Bands Bands ---------------------------- | | | | 4 Char | #bands * 4 Char | | | | ----------------------------Second record (one for each band):
Length Type Key Slope Offset Startpt Entpt LUT data ------------------------------------------------------------------- | | | | | | | |13 Char|3 Char|16 Char|28 Char|12 Char|2 * Type + #entries *Type | | | | | | | | -------------------------------------------------------------------
The projection definition file format contains all information relative to a call to proj and projon. The file is in labeled table format. It may contain as many records as needed to define various projections in a project. This file is generated by the projprm module.
Example:
; "PROJFILE","Projection parameter file"; "PROJKEY","C","Uniquely identify the defined projection",1,8 "PROJTYPE","I4","Projection type code",1,1 "PROJZONE","I4","Projection zone code",1,1 "PROJUNITS","I4","Units code",1,1 "PROJSPH","I4","Speroid code",1,1 "PROJPARMS","R8","Projection parameters",1,15; "geo",0,62,4,0,0.00000000000000000000E+00,0.00000000000000000000E+00 0.00000000000000000000E+00,0.00000000000000000000E+00, 0.00000000000000000000E+00
The geometric mapping grid file contains a geometric mapping grid, information needed to fill the output space image's DDR, and miscellaneous mapping grid parameters and statistics. The format follows:
First record:
Length Type Key Model Units Proj_valid Fiterr_valid ----------------------------------------------------------------------- | | | | | | | | | 13 Char | 3 Char | 16 Char | 15 Char | 12 Char | 4 Bytes | 4 Bytes | | | | | | | | | ----------------------------------------------------------------------- Griderr_valid Ncoeff Code Zone Datum Nrows Ncols -------------------------------------------------------------------------- | | | | | | | | | 4 Bytes | 4 Bytes | 4 Bytes | 4 Bytes | 4 Bytes | 4 Bytes | 4 Bytes | | | | | | | | | -------------------------------------------------------------------------- Lines Samples Out_lines Out_samps ------------------------------------------------------------- | | | | | | 4 Bytes | 4 Bytes | (4 * Nrows) Bytes | (4 * Ncols) Bytes | | | | | | -------------------------------------------------------------Second record:
Length Type Key Corners Pdist Projprms ----------------------------------------------------------------- | | | | | | | | 13 Char | 3 Char | 16 Char | 64 Bytes | 16 Bytes | 120 Bytes | | | | | | | | ----------------------------------------------------------------- Coeffs Max_grid_error Ave_grid_error RMS_grid_error ------------------------------------------------------------------ | | | | | | (2 * Ncoef * 8) Bytes | 16 Bytes | 16 Bytes | 8 Bytes | | | | | | ------------------------------------------------------------------ Act_fit_err Grid_tol Max_fit_error Ave_fit_error RMS_fit_error --------------------------------------------------------------- | | | | | | | 256 Bytes | 8 Bytes| 16 Bytes | 16 Bytes | 8 Bytes | | | | | | | --------------------------------------------------------------- In_lines In_Samps --------------------------------------------------------- | | | | (Nrows * Ncols * 8) Bytes | (Nrows * Ncols * 8) Bytes | | | | ---------------------------------------------------------
Graphics overlay files contain information necessary to display graphics data along with their descriptive attributes. These files use the label services format. Therefore, any other LAS applications that operate on label services files also operate on GOFs. Each file may contain any number of records. The information stored for each record type follows:
All coordinate pairs stored in the GOF are sample
and line (X,Y) file coordinates within a defined
image space.
Finally, the XID application may be used to
add records to a GOF or
to modify existing
GOF records. The interface to GOFs
is image I/O independent because it makes use of
the label services file format. For this
reason, they may be used outside of the
LAS image processing package.
The format for
each type of GOF is expanded upon in the following
subsections.
The GOF union and its underlying structures are
defined in the "gof.h" include file (see the
Include Files section).
** The length given for each character field allows for a null character at the end of the
string. (For example, label has a length of 16; however, the user may only enter 15
characters.)
Header Ancillary Annotation Trailer (HAAT) files contain all of the information accompanying an
image in the same format as it was on tape. The HAAT files are associated files, one file for
each type of record. The records are written to a binary, fixed length file. Each function using
the HAAT files has to unpack the fields that it needs for processing. The programmer should refer to the tape format documentation for a description of the files or to the dspassoc module. File contents, as well as the
number of files, vary with the type of data being used.
The TAE naming convention is as follows:
15.5 Graphics Overlay Files (GOFs)
Each GOF also contains a header record storing the user-specified attribute names for the file. Attribute names are used to describe the attribute information contained in each record. For example, record 1 of a point GOF may contain a value of 4 for the first attribute. The corresponding attribute name (for example, "CLASS") gives the user a basis for interpreting the meaning of the attribute value. Each file may contain a maximum of 35 unique attribute names.
These names may be eight characters in length, and
each must have a data type definition (character,
integer, real). These data types are used for
conversion purposes when necessary. Attribute
names are defined by the GOF function in the XID application
and may be deleted by the delatt application.
Attribute values may contain a maximum of 12
characters and must be compatible with the type
defined for the attribute. Attribute values are
defined when a GOF record is created or modified using the
XID application.
Each type of graphics data (point, line, poly, and annot) is stored in a separate file whose filename extension describes the graphics type. For example: MCKINLEY;GOF_POLY is a graphics overlay file containing polygon data; MCKINLEY;GOF_POINT
contains point data; MCKINLEY;GOF_LINE contains
line data; and MCKINLEY;GOF_ANNOT contains
annotation data. Graphics overlay files may
optionally be associated with images. The
filename is again used to determine this. Using
this example, if MCKINLEY is an existing image
file, the graphics overlay file MCKINLEY;GOF_POLY
is associated with the image. If however,
MCKINLEY is not an existing image file, then the
GOF is not associated with any particular image.
Point File (GOF_POINT)
Header Record:
Length Type Key # Recs Attribute Names Attrib Data Types Att Mask
----------------------------------------------------------------------------
| | | | | | | |
|13 Char|3 Char|16 Char|16 Char|35 9-Char fields|35 4-Char fields |35 Bytes|
| | | | | | | |
----------------------------------------------------------------------------
Point Data Records:
Length Type Label Attributes 1-35 X Y
---------------------------------------------------------------
| | | | | | |
|13 Char|3 Char|16 Char|35 13-Character fields| Float | Float |
| | | | | | |
---------------------------------------------------------------
Line File (GOF_LINE)
Header Record:
Length Type Key # Recs Attribute Names Attrib Data Types Att Mask
----------------------------------------------------------------------------
| | | | | | | |
|13 Char|3 Char|16 Char|16 Char|35 9-Char fields|35 4-Char fields |35 Bytes|
| | | | | | | |
----------------------------------------------------------------------------
Line Data Records:
Length Type Label Attributes 1-35 # Pts Future
---------------------------------------------------------------
| | | | | | |
|13 Char|3 Char|16 Char|35 13-Character fields| Float | Float |
| | | | | | |
---------------------------------------------------------------
X, Y Pairs (X1,Y1 ... Xn,Yn)
------------------------------------------
| | | | | |
| Float | Float | . . . | Float | Float |
| | | | | |
------------------------------------------
Polygon File (GOF_POLY)
Header Record:
Length Type Key # Recs Attribute Names Attrib Data Types Att Mask
----------------------------------------------------------------------------
| | | | | | | |
|13 Char|3 Char|16 Char|16 Char|35 9-Char fields|35 4-Char fields |35 Bytes|
| | | | | | | |
----------------------------------------------------------------------------
Polygon Data Records:
Length Type Label Attributes 1-35 # Pts Future
---------------------------------------------------------------
| | | | | | |
|13 Char|3 Char|16 Char|35 13-Character fields| Float | Float |
| | | | | | |
---------------------------------------------------------------
X, Y Pairs (X1,Y1 ... Xn,Yn)
------------------------------------------
| | | | | |
| Float | Float | . . . | Float | Float |
| | | | | |
------------------------------------------
Annotation File (GOF_ANNOT)
Header Record:
Length Type Key # Recs Attribute Names Attrib Data Types Att Mask
----------------------------------------------------------------------------
| | | | | | | |
|13 Char|3 Char|16 Char|16 Char|35 9-Char fields|35 4-Char fields |35 Bytes|
| | | | | | | |
----------------------------------------------------------------------------
Annotation Data Records:
Length Type Label Attributes 1-35 Annotation
---------------------------------------------------------------
| | | | | |
|13 Char|3 Char|16 Char|35 13-Character fields| 509 Characters|
| | | | | |
---------------------------------------------------------------
Size Angle X Y
--------------------------------
| | | | |
| Float | Float |Float | Float |
| | | | |
--------------------------------
15.6 Header Ancillary Annotation Trailer (HAAT) File(s)
filename;format.record-type
An example from edipsin where filename=test:
test;edips.ancil - contains EDIPS ancillary recordstest;edips.annot - contains EDIPS annotation records
test;edips.headr - contains EDIPS header records
test;edips.trail - contains EDIPS trailer records
There is one history file per image. The file is in label services format. File format for the history file is:
Length Type Key Date System User Module Parms ----------------------------------------------------------------- | | | | | | | | | |13 Char|3 Char|16 Char|17 Char|4 Char|20 Char|20 Char|as needed| | | | | | | | | | -----------------------------------------------------------------
The merged tie point files record the approximate coordinates of tie points and specifies options to be used during automatic, precision correlation of each tie point. Each file consists of a single header record, followed by a record for each tie point. The format follows:
First record
Length Type Key Chip_mode Units Sea_name Ref_name -------------------------------------------------------------------- | | | | | | | | | 13 Char| 3 Char| 16 Char| 9 Char| 12 Char| CMLEN Char| CMLEN Char| | | | | | | | | -------------------------------------------------------------------- Corners Pdist Projprms Proj_valid Code Zone Dataum -------------------------------------------------------------------------- | | | | | | | | |64 Bytes| 16 Bytes | 120 Bytes | 8 Bytes | 8 bytes | 8 Bytes | 8 Bytes| | | | | | | | | --------------------------------------------------------------------------Second record
Length Type Key Pt_id Ref_chip Sea_chip ----------------------------------------------------------- | | | | | | | | 13 Char| 3 Char| 16 Char| 20 Char|CMLEN Char| CMLEN Char| | | | | | | | ----------------------------------------------------------- Geo_coord Nominal Ref_coord Elevation Zoom_factor Chip_size Offsets _________________________________________________________________________ | | | | | | | | |16 Bytes| 16 Bytes| 16 Bytes| 8 Bytes | 8 Bytes | 16 Bytes | 16 Bytes| | | | | | | | | _________________________________________________________________________
"NOCHIPS" Reference chip images not used "CHIPTEM" Reference chips used to establish temporal registration "CHIPFUL" Reference chips used to establish geographic registration--extract from full input image "CHIPPRE" Reference chips used to establish geographic registration--search subimages prescaled or rotated.
The resampling weight table files contains up to three 33 by N matrices of separable interpolation weights to be used in brightness level resampling. N is the resampling kernel dimension and 33 identifies the 32 subdivisions between pixel values, including both endpoints. The format follows:
Length Type Key Size1 Size2 Size3 -------------------------------------------------------- | | | | | | | | 13 Char| 3 Char| 16 Char| 8 Bytes | 8 Bytes| 8 Bytes | | | | | | | | -------------------------------------------------------- Table1 Table2 Table3 ------------------------------------------------------------------ | | | | |(Size1 * 264) Bytes | (Size1 * 264) Bytes | (Size1 * 264) Bytes | | | | | ------------------------------------------------------------------
The file is made up of fixed length records of 512 bytes each. This is a binary file and not a text file. The first record points directly to all the classes. Each class has a record which points to all its sites. The user's data is kept as linked lists of records off the appropriate node. There is also a linked list of deleted records which is pointed to by the first record.
The first 70 bytes of all records are used to hold the same information regardless of the tree level to which the record belongs.
The following is a list of the common fields in the records.
Field name Function ---------- -------- Data-type Type of data the record holds. (e.g., "CLASS-LIST", "SITE-LIST","NAME","HIST001","MEAN","POLYGON" "COVARIANCE_MATRIX" Continuation If the data record does not fit in our data record space, Pointer put a pointer to the next record here. If the data is not continued, then put NULL here. Next This indicates the next record at this level. Shape[9] This describes the data that is to follow.The following documentation contains the record formats in more detail. The values which are fixed for each record type have been given.
Image Level Records (level 0)
----------------------------------------------------------------------- | First record of the file | | | | Byte #'s Bytes Function | | -------- ----- -------- | | | | 1 - 26 26 Data-type = "CLASS-LIST" | | 27 - 30 4 Continuation ptr. = NULL | | 31 - 34 4 Next image-level data (ptr) | | 35 - 70 36 Shape vector | | 71 - 74 4 Number of classes | | 75 - 474 400 Pointers to classes | | 475 - 478 4 First deleted record (ptr) | | 479 - 512 34 Empty | | | | The "first deleted record pointer" points to the first | | record of the deleted record linked list. | | | | | | Data Record | | | | Byte #'s Bytes Function | | -------- ----- -------- | | | | 1 - 26 26 Data-type | | 27 - 30 4 Continuation ptr. | | 31 - 34 4 Next image-level data (ptr) | | 35 - 70 36 Shape vector | | 71 - 512 442 Image-level data | | | | Note: All stats files must have at least one record | | which is the first record. Its data type is | | "CLASS-LIST." | -----------------------------------------------------------------------Class Level Records (level 1)
----------------------------------------------------------------------- | First record for each class | | | | | | Byte #'s Bytes Function | | -------- ----- -------- | | | | 1 - 26 26 Data-type = "SITE-LIST" | | 27 - 30 4 Continuation ptr. = NULL | | 31 - 34 4 Next class-level data (ptr)for this site | | 35 - 70 36 Shape vector | | 71 - 74 4 Number of sites for this class | | 75 - 474 400 Pointers to sites | | 475 - 512 38 Empty | | | | | | Data Record - Level 1 (class level) | | | | Byte #'s Bytes Function | | -------- ----- -------- | | | | 1 - 26 26 Data-type | | 27 - 30 4 Continuation ptr. | | 31 - 34 4 Next class-level data (ptr) for this class | | 35 - 70 36 Shape vector | | 71 - 512 442 Class-level data | | | | Note: All class must have at least one record which is | | its first. Its data type is "SITE-LIST." | | | -----------------------------------------------------------------------Site Level Records (level 2)
----------------------------------------------------------------------- | Data Record | | | | Byte #'s Bytes Function | | -------- ----- -------- | | | | 1 - 26 26 Data-type | | 27 - 30 4 Continuation ptr. | | 31 - 34 4 Next site-level data (ptr) for this site | | 35 - 70 36 Shape vector | | 71 - 512 442 Site-level data | -----------------------------------------------------------------------
The tie point location files record the results of automatic or manual correlation for subsequent use in generating geometric mapping grids for the rectification process. Each tie point location file consists of a single header record followed by one record for each tie point. The format follows:
First record
Length Type Key Ref_mode Units Peak_method Corr_type -------------------------------------------------------------------- | | | | | | | | | 13 Char| 3 Char| 16 Char| 9 Char| 12 Char| 25 Char | 7 Char | | | | | | | | | -------------------------------------------------------------------- Sea_name Ref_name --------------------------- | | | | CMLEN Char | CMLEN Char | | | | --------------------------- Corners Pdist Projprms Edge_thres Min_str Max_dis _________________________________________________________________ | | | | | | | |64 Bytes| 16 Bytes | 120 Bytes | 8 Bytes | 8 bytes | 8 Bytes | | | | | | | | _________________________________________________________________ Proj_valid Code Zone Datum ----------------------------------------- | | | | | | 8 Bytes | 8 Bytes | 8 Bytes | 8 Bytes | | | | | | -----------------------------------------Second record
Length Type Key Pt_id Ref_chip ----------------------------------------------- | | | | | | | 13 Char| 3 Char| 16 Char| 20 Char|CMLEN Char| | | | | | | ----------------------------------------------- Geo_coord Sea_coord Ref_coord RMS_error Strength Displacement ----------------------------------------------------------------- | | | | | | | | 16 Bytes | 16 Bytes | 16 Bytes | 16 Bytes | 8 Bytes | 8 Bytes | | | | | | | | ----------------------------------------------------------------- Nominal Elevation Zoom_factor Ref_size Offsets Chip_loc Sea_size -------------------------------------------------------------------------- | | | | | | | | |16 Bytes | 8 Bytes | 8 Bytes | 16 Bytes | 16 Bytes | 16 Bytes | 16 Bytes| | | | | | | | | -------------------------------------------------------------------------- Chip_coord Req_size Location Active -------------------------------------------- | | | | | | 16 Bytes | 16 Bytes | 16 Bytes | 8 Bytes | | | | | | --------------------------------------------
"IMAGE" Reference scene is a full image "MAP" Reference area is a map "CHIPTEM" Reference chips used to establish temporal registration "CHIPFUL" Reference chips used to establish geographic registration--extract from full input image "CHIPPRE" Reference chips used to establish geographic registration--search subimages prescaled or rotated.
"RECIPROCAL" Elliptic paraboloid fit to reciprocal of correlation values "PARABOLOID" Elliptic paraboloid fit "GAUSSIAN" Elliptic gaussian fit "NEAR_INT" No surface fit. Tie point assigned the integer coordinate which gave the largest correlation value. "NO_CORR" Auto correlation not performed
"EDGE" Edge correlation "GREY" Grey level correlation "PHASE" Phase correlation "MANUAL" Manually correlated--automatic correlation not performed
0 --> Accept manually extracted tie point 1 --> Accept automatically registered tie point 2 --> Reject; correlation peak too near edge of search area. 3 --> Reject; subsidiary peak comparable in strength to main peak 4 --> Reject; strength of peak below minimum specified by user 5 --> Reject; diagonal displacement from nominal location exceeds maximum specified by user 6 --> Correlation not attempted; error in correlation parameters 7 --> Reject; manually by user 8 --> Reject; automatically by the modeling process 9 --> Reject; manually by user during the modeling process 1X --> Previously rejected tie point reaccepted manually by user. X indicates original active code of tie point (0 9) before being reaccepted
Each tie point selection file contains coordinates relative to a single image. Two tie point selection files, one for the search image and one for the reference image or geographic data, must be merged to specify temporal or geographic registration.
Although merging the files requires an extra processing step, the initial generation of two separate data sets permits measurement of map coordinates in a separate step from tie point selection and also facilitates reusing a set of reference image tie points for temporal registration of a series of images.
The tie point selection file consists of a single header record and one tie point selection record for each tie point. The format follows:
First Record
Length Type Key Mode Units Name -------------------------------------------------------- | | | | | | | | 13 Char| 3 Char| 16 Char| 4 Char| 12 Char| CMLEN Char| | | | | | | | -------------------------------------------------------- Corners Pdist Projprms Proj_valid Code Zone Datum __________________________________________________________________________ | | | | | | | | |64 Bytes| 16 Bytes | 120 Bytes | 8 Bytes | 8 bytes | 8 Bytes | 8 Bytes | | | | | | | | | __________________________________________________________________________Second Record
Length Type Key Pt_id Chip_name ----------------------------------------------- | | | | | | | 13 Char| 3 Char| 16 Char| 20 Char|CMLEN Char| | | | | | | ----------------------------------------------- Coord Image_coord Elevation Zoom_factor Chip_size Offsets ------------------------------------------------------------------ | | | | | | | | 16 Bytes | 16 Bytes | 8 Bytes | 8 Bytes | 16 Bytes | 16 Bytes | | | | | | | | ------------------------------------------------------------------
"GEO" Geographic Coordinates "REF" Reference Image Coordinates "SEA" Search Image Coordinates "PRO" Projection Coordinates "USR" User Defined Coordinates