MISR Toolkit
1.5.1
|
Go to the source code of this file.
Macros | |
#define | MAX_LENGTH 1000 |
Functions | |
MTKt_status | MtkGenericMapInfoRead (const char *Filename, MTKt_GenericMapInfo *Map_info) |
Initialize a MTKt_GenericMapInfo structure using data from an external file. More... | |
#define MAX_LENGTH 1000 |
Definition at line 23 of file MtkGenericMapInfoRead.c.
MTKt_status MtkGenericMapInfoRead | ( | const char * | Filename, |
MTKt_GenericMapInfo * | Map_info | ||
) |
Initialize a MTKt_GenericMapInfo structure using data from an external file.
The external file must be simple text format with parameter_name = value pairs.
Parameter names recognized by this routine are as follows: min_corner_x is the minimum X coordinate at the edge of the map. min_corner_y is the minimum Y coordinate at the edge of the map. resolution_x is the size of a pixel along the X-axis. resolution_y is the size of a pixel along the Y-axis. number_pixel_x is the size of the map in pixels, along the X-axis. number_pixel_y is the size of the map in pixels, along the Y-axis. origin_code defines the corner of the map at which pixel 0,0 is located. pix_reg_code defines whether a pixel value is related to the corner or center of the corresponding area of that pixel on the map. If the corner is used, then it is always the corner corresponding to the corner of the origin.
Possible values for origin_code are: UL - Upper Left (min X, max Y) UR - Upper Right (max X, max Y) LL - Lower Left (min X, min Y) LR - Lower Right (max X, min Y)
Possible values are: CENTER - Center CORNER - Corner
Unrecognized parameter names are ignored. Lines starting with a '#' character are ignored. Comments may be placed on the same line, after a name = value pair as well.
Example map information file:
min_corner_x = 10000.0 min_corner_y = 20000.0 resolution_x = 250.0 resolution_y = 250.0 number_pixel_x = 1000 number_pixel_y = 2000 origin_code = UL # min x, max y pix_reg_code = CENTER
[in] | Filename | Filename |
[out] | Map_info | Map information. |
Definition at line 78 of file MtkGenericMapInfoRead.c.