|
ocssw
1.0
|
#include <stdio.h>#include <stdlib.h>#include <stdint.h>#include <string.h>#include "hdf.h"#include "mfhdf.h"#include "passthebuck.h"Go to the source code of this file.
Classes | |
| struct | idDS |
Defines | |
| #define | READ_GLBL_ATTR(nam, ptr) |
| #define | READ_GLBL_ATTR_E(nam, ptr) |
| #define | READ_SDS(nam, ptr, s0, s1, s2, e0, e1, e2) |
| #define | READ_SDS_E(nam, ptr, s0, s1, s2, e0, e1, e2) |
| #define | READ_SDS_ID(sd_id, nam, ptr, s0, s1, s2, s3, e0, e1, e2, e3) |
| #define | READ_SDS_ID_E(sd_id, nam, ptr, s0, s1, s2, s3, e0, e1, e2, e3) |
Functions | |
| int32 | hdf_sizeof (int32 dtype) |
| return the sizeof dtype in bytes | |
| char * | GetFileDesc (char *filename) |
| int | SetChrGA (idDS ds_id, char *, char *) |
| int | SetF32GA (idDS ds_id, char *, float32) |
| int | SetF64GA (idDS ds_id, char *name, float64 value) |
| int | SetI8GA (idDS ds_id, char *, uint8) |
| int | SetI16GA (idDS ds_id, char *, int16) |
| int | SetI32GA (idDS ds_id, char *, int32) |
| int | CreateSDS (int32 sd_id, char *sname, char *lname, char *standard_name, char *units, double low, double high, float slope, float offset, int32 nt, int32 rank, int32 d0, int32 d1, int32 d2, char *dn0, char *dn1, char *dn2) |
| int | sd_create (int32, char *, int32, int32, int32, int32, int32, int32 *) |
| int | sd_select (int32, char *, int32 *) |
| int | sd_endaccess (int32) |
| int | sd_setdimnames (int32, char *, char *, char *) |
| int | sd_setdimname (int32, int32, char *) |
| int | sd_setattr (int32, char *, int32, int32, VOIDP) |
| int | sd_writedata (int32 sd_id, char *, VOIDP, int32, int32, int32, int32, int32, int32) |
| int | AddSdsToVgroup (int32 sd_id, int32 v_id, char *name) |
| int | v_attach (int32 h_id, int32 *v_id) |
| int | getDims (int32 fileID, char sdsname[], int32 dims[]) |
| int | getDimsDS (idDS ds_id, char sdsname[], int32 dims[]) |
| int | get_type (int32 fileID, char sdsname[], int32 *dtype) |
| int | getTypeDS (idDS ds_id, char sdsname[H4_MAX_NC_NAME], int32 *dtype) |
| int | rdSDS (int32 fileID, char sdsname[], int32 start1, int32 start2, int32 edges1, int32 edges2, VOIDP array_data) |
| int | getHDFattr (int32 fileID, char attrname[], char sdsname[], VOIDP data) |
| int32 | read_SDS (int32 sdfid, char *sds_name, void *buffer) |
| intn | attach_vdata (int32 fid, char *sname) |
| intn | rdvdata (int32 vskey, char *fields, int32 start, int32 nelt, unsigned char *databuf) |
| void | check_err (const int stat, const int line, const char *file) |
| int | setAttr (idDS ds_id, char *nam, int32 typ, int32 cnt, VOIDP data) |
| int8_t | findAttr (idDS ds_id, char *nam) |
| int | readAttr (idDS ds_id, char *nam, VOIDP data) |
| int | infoAttr (idDS ds_id, char *nam, int32 *dtype, int32 *count) |
| int | createDS (idDS ds_id, char *sname, char *lname, char *standard_name, char *units, double low, double high, float slope, float offset, int32 nt, int32 rank, int32 d0, int32 d1, int32 d2, char *dn0, char *dn1, char *dn2) |
| int32 | selectDS (idDS ds_id, char *l2_prod_names) |
| int32 | checkDS (idDS ds_id, char *l2_prod_name) |
| int | writeDS (idDS ds_id, char *name, VOIDP data, int32 s0, int32 s1, int32 s2, int32 e0, int32 e1, int32 e2) |
| int | readDS (idDS ds_id, char *name, int32 *start, int32 *stride, int32 *count, VOIDP data) |
| idDS | startDS (char *filename, int32 format, int32 accessmode) |
| int | endaccessDS (idDS ds_id) |
| int | endDS (idDS ds_id) |
| int | getProdlist (char *fname, char **prodlist, int32 *l2_flags_type) |
| int | CreateNCDF (int32_t nc_id, char *sname, char *lname, char *standard_name, char *units, double low, double high, float slope, float offset, int32_t nt, int32_t rank, int32_t dimids[3]) |
| int | writeBinList_nc (int32_t grpid, int32_t nbins_to_write, void *data) |
| int | writeBinData_nc (int32_t grpid, int32_t nbins_to_write, int32_t iprod, char *prodname, void *data) |
| int | writeBinIndex_nc (int32_t grpid, int32_t nbins_to_write, void *data) |
| #define READ_GLBL_ATTR | ( | nam, | |
| ptr | |||
| ) |
{ \
if(SDreadattr(sd_id,SDfindattr(sd_id,(nam)),(VOIDP)(ptr))){ \
fprintf(stderr, \
"-E- %s line %d: Could not get global attribute, %s.\n", \
__FILE__,__LINE__,(nam)); \
} \
}
Definition at line 70 of file hdf_utils.h.
| #define READ_GLBL_ATTR_E | ( | nam, | |
| ptr | |||
| ) |
{ \
if(SDreadattr(sd_id,SDfindattr(sd_id,(nam)),(VOIDP)(ptr))){ \
fprintf(stderr, \
"-E- %s line %d: Could not get global attribute, %s.\n", \
__FILE__,__LINE__,(nam)); \
exit(1); \
} \
}
Definition at line 78 of file hdf_utils.h.
| #define READ_SDS | ( | nam, | |
| ptr, | |||
| s0, | |||
| s1, | |||
| s2, | |||
| e0, | |||
| e1, | |||
| e2 | |||
| ) |
{ \
int32 start[3]; \
int32 edge[3]; \
edge[0]=(e0); edge[1]=(e1); edge[2]=(e2); \
start[0]=(s0); start[1]=(s1); start[2]=(s2); \
if(SDreaddata(SDselect(sd_id, SDnametoindex(sd_id, (nam))), \
start, NULL, edge, (VOIDP)(ptr)) == FAIL){ \
fprintf(stderr,"-E- %s line %d: Could not read SDS, %s.\n", \
__FILE__,__LINE__,(nam)); \
} \
}
Definition at line 87 of file hdf_utils.h.
| #define READ_SDS_E | ( | nam, | |
| ptr, | |||
| s0, | |||
| s1, | |||
| s2, | |||
| e0, | |||
| e1, | |||
| e2 | |||
| ) |
{ \
int32 start[3]; \
int32 edge[3]; \
edge[0]=(e0); edge[1]=(e1); edge[2]=(e2); \
start[0]=(s0); start[1]=(s1); start[2]=(s2); \
if(SDreaddata(SDselect(sd_id, SDnametoindex(sd_id, (nam))), \
start, NULL, edge, (VOIDP)(ptr)) == FAIL){ \
fprintf(stderr,"-E- %s line %d: Could not read SDS, %s.\n", \
__FILE__,__LINE__,(nam)); \
exit(1); \
} \
}
Definition at line 99 of file hdf_utils.h.
| #define READ_SDS_ID | ( | sd_id, | |
| nam, | |||
| ptr, | |||
| s0, | |||
| s1, | |||
| s2, | |||
| s3, | |||
| e0, | |||
| e1, | |||
| e2, | |||
| e3 | |||
| ) |
{ \
int32 start[4]; \
int32 edge[4]; \
edge[0]=(e0); edge[1]=(e1); edge[2]=(e2); edge[3]=(e3); \
start[0]=(s0); start[1]=(s1); start[2]=(s2); start[3]=(s3); \
if(SDreaddata(SDselect((sd_id), SDnametoindex((sd_id), (nam))), \
start, NULL, edge, (VOIDP)(ptr)) == FAIL){ \
fprintf(stderr,"-E- %s line %d: Could not read SDS, %s.\n", \
__FILE__,__LINE__,(nam)); \
} \
}
Definition at line 112 of file hdf_utils.h.
| #define READ_SDS_ID_E | ( | sd_id, | |
| nam, | |||
| ptr, | |||
| s0, | |||
| s1, | |||
| s2, | |||
| s3, | |||
| e0, | |||
| e1, | |||
| e2, | |||
| e3 | |||
| ) |
{ \
int32 start[4]; \
int32 edge[4]; \
edge[0]=(e0); edge[1]=(e1); edge[2]=(e2); edge[3]=(e3); \
start[0]=(s0); start[1]=(s1); start[2]=(s2); start[3]=(s3); \
if(SDreaddata(SDselect((sd_id), SDnametoindex((sd_id), (nam))), \
start, NULL, edge, (VOIDP)(ptr)) == FAIL){ \
fprintf(stderr,"-E- %s line %d: Could not read SDS, %s.\n", \
__FILE__,__LINE__,(nam)); \
exit(1); \
} \
}
Definition at line 124 of file hdf_utils.h.
| int AddSdsToVgroup | ( | int32 | sd_id, |
| int32 | v_id, | ||
| char * | name | ||
| ) |
Definition at line 352 of file hdf_utils.c.
| intn attach_vdata | ( | int32 | fid, |
| char * | sname | ||
| ) |
Definition at line 505 of file calib_get_cal_misc.c.
| int CreateNCDF | ( | int32_t | nc_id, |
| char * | sname, | ||
| char * | lname, | ||
| char * | standard_name, | ||
| char * | units, | ||
| double | low, | ||
| double | high, | ||
| float | slope, | ||
| float | offset, | ||
| int32_t | nt, | ||
| int32_t | rank, | ||
| int32_t | dimids[3] | ||
| ) |
Definition at line 24 of file ncdf_utils.c.
| int CreateSDS | ( | int32 | sd_id, |
| char * | sname, | ||
| char * | lname, | ||
| char * | standard_name, | ||
| char * | units, | ||
| double | low, | ||
| double | high, | ||
| float | slope, | ||
| float | offset, | ||
| int32 | nt, | ||
| int32 | rank, | ||
| int32 | d0, | ||
| int32 | d1, | ||
| int32 | d2, | ||
| char * | dn0, | ||
| char * | dn1, | ||
| char * | dn2 | ||
| ) |
Definition at line 76 of file hdf_utils.c.
| int endaccessDS | ( | idDS | ds_id | ) |
| int get_type | ( | int32 | fileID, |
| char | sdsname[], | ||
| int32 * | dtype | ||
| ) |
| int getDims | ( | int32 | fileID, |
| char | sdsname[], | ||
| int32 | dims[] | ||
| ) |
| char* GetFileDesc | ( | char * | filename | ) |
Definition at line 719 of file hdf_utils.c.
| int getHDFattr | ( | int32 | fileID, |
| char | attrname[], | ||
| char | sdsname[], | ||
| VOIDP | data | ||
| ) |
| int getProdlist | ( | char * | fname, |
| char ** | prodlist, | ||
| int32 * | l2_flags_type | ||
| ) |
| int32 hdf_sizeof | ( | int32 | dtype | ) |
return the sizeof dtype in bytes
Definition at line 27 of file hdf_utils.c.
| int rdSDS | ( | int32 | fileID, |
| char | sdsname[], | ||
| int32 | start1, | ||
| int32 | start2, | ||
| int32 | edges1, | ||
| int32 | edges2, | ||
| VOIDP | array_data | ||
| ) |
| intn rdvdata | ( | int32 | vskey, |
| char * | fields, | ||
| int32 | start, | ||
| int32 | nelt, | ||
| unsigned char * | databuf | ||
| ) |
Definition at line 977 of file l3stat_chk.c.
| int32 read_SDS | ( | int32 | sdfid, |
| char * | sds_name, | ||
| void * | buffer | ||
| ) |
Definition at line 640 of file calib_get_cal_misc.c.
| int sd_create | ( | int32 | , |
| char * | , | ||
| int32 | , | ||
| int32 | , | ||
| int32 | , | ||
| int32 | , | ||
| int32 | , | ||
| int32 * | |||
| ) |
Definition at line 1394 of file swl1_hdf.c.
| int sd_endaccess | ( | int32 | ) |
Definition at line 1422 of file swl1_hdf.c.
| int sd_select | ( | int32 | , |
| char * | , | ||
| int32 * | |||
| ) |
Definition at line 1489 of file swl1_hdf.c.
| int sd_setattr | ( | int32 | , |
| char * | , | ||
| int32 | , | ||
| int32 | , | ||
| VOIDP | |||
| ) |
Definition at line 1384 of file swl1_hdf.c.
| int sd_setdimname | ( | int32 | , |
| int32 | , | ||
| char * | |||
| ) |
Definition at line 1443 of file swl1_hdf.c.
| int sd_setdimnames | ( | int32 | , |
| char * | , | ||
| char * | , | ||
| char * | |||
| ) |
Definition at line 1432 of file swl1_hdf.c.
| int sd_writedata | ( | int32 | sd_id, |
| char * | , | ||
| VOIDP | , | ||
| int32 | , | ||
| int32 | , | ||
| int32 | , | ||
| int32 | , | ||
| int32 | , | ||
| int32 | |||
| ) |
Definition at line 268 of file hdf_utils.c.
| int v_attach | ( | int32 | h_id, |
| int32 * | v_id | ||
| ) |
Definition at line 1510 of file swl1_hdf.c.
| int writeBinData_nc | ( | int32_t | grpid, |
| int32_t | nbins_to_write, | ||
| int32_t | iprod, | ||
| char * | prodname, | ||
| void * | data | ||
| ) |
| int writeBinIndex_nc | ( | int32_t | grpid, |
| int32_t | nbins_to_write, | ||
| void * | data | ||
| ) |
| int writeBinList_nc | ( | int32_t | grpid, |
| int32_t | nbins_to_write, | ||
| void * | data | ||
| ) |
1.7.6.1