ocssw
V2022
|
#include <time.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <inttypes.h>
#include <unistd.h>
#include <proj.h>
#include <math.h>
#include "hdf5.h"
#include "hdf5_hl.h"
#include "goci.h"
Go to the source code of this file.
Functions | |
int | goci_proj4_open (goci_l1b_t *l1b) |
void | goci_proj4_close (goci_l1b_t *l1b) |
int | goci_l1b_open (const char *src_path, goci_l1b_t **goci_l1b) |
int | goci_l1b_close (goci_l1b_t *goci_l1b) |
int | goci_l1b_get_date (goci_l1b_t *goci_l1b, char *tstr_name, int *year, int *month, int *day) |
int | goci_l1b_get_time (goci_l1b_t *goci_l1b, char *tstr_name, int *hour, int *min, int *sec) |
int | goci_l1b_get_band (goci_l1b_t *goci_l1b, int band, int line, uint32_t *buf) |
Detailed Description
GOCI file format reader.
Definition in file goci.c.
Function Documentation
◆ goci_l1b_close()
int goci_l1b_close | ( | goci_l1b_t * | goci_l1b | ) |
◆ goci_l1b_get_band()
int goci_l1b_get_band | ( | goci_l1b_t * | goci_l1b, |
int | band, | ||
int | line, | ||
uint32_t * | buf | ||
) |
read specified band and line from GOCI file.
- Parameters
-
[in] goci_l1b GOCI file [in] band Band number to read (0-7) [in] line Line to read [out] buf buffer to contain data
This function reads a scan line from the GOCI data. The returned value can be converted to radiance by multiply the value by 1E-07.
- Returns
- 0 for success, -4 for read error, -6 for invalid parameter
◆ goci_l1b_get_date()
int goci_l1b_get_date | ( | goci_l1b_t * | goci_l1b, |
char * | tstr_name, | ||
int * | year, | ||
int * | month, | ||
int * | day | ||
) |
read a date of GOCI data
- Parameters
-
[in] goci_l1b GOCI l1b file information structure [in] tstr_name name of time string to read from (char *) [out] year Year [out] month Month (1-12) [out] day Day (1-31)
This function gets the date from the GOCI data file.
- Returns
- 0 for success, -3 for invalid format
◆ goci_l1b_get_time()
int goci_l1b_get_time | ( | goci_l1b_t * | goci_l1b, |
char * | tstr_name, | ||
int * | hour, | ||
int * | min, | ||
int * | sec | ||
) |
read a time of GOCI data
- Parameters
-
[in] goci_l1b GOCI file [in] tstr_name name of time string to read from (char *) [out] hour Hour of day (0-23) [out] min Minute (0-59) [out] sec Second (0-59)
This function gets the time from the GOCI data file.
- Returns
- 0 for success, -3 for invalid format
◆ goci_l1b_open()
int goci_l1b_open | ( | const char * | src_path, |
goci_l1b_t ** | goci_l1b | ||
) |
open GOCI bands
- Parameters
-
[in] src_path path to one GOCI file [out] goci_l1b GOCI file structure
Opens a GOCI data file and attaches to the main data set "Image Data" which is stored as a GRID.
- Returns
- -1 for open error, -2 for close error, -3 for invalid format -4 for read error, -5 for memory error W. Robinson, SAIC, Nov 2014, the position in the file is really ( radius, sub-sat lon, sub-sat lat ), so derive position accordingly W. Robinson, SAIC, 5 Dec 2014, set up the slot navigation to get better times
◆ goci_proj4_close()
void goci_proj4_close | ( | goci_l1b_t * | l1b | ) |
◆ goci_proj4_open()
int goci_proj4_open | ( | goci_l1b_t * | l1b | ) |
init proj4 for GOCI geolocation
- Parameters
-
[in/out] goci_l1b GOCI file structure
Uses the information in the goci_l1b structure to init the proj4 structure for converting the geolocation information.
- Returns
- -1 for open error, -2 for close error, -4 for read error