MISR Toolkit  1.5.1
dfsd.h
Go to the documentation of this file.
1 
2 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
3  * Copyright by The HDF Group. *
4  * Copyright by the Board of Trustees of the University of Illinois. *
5  * All rights reserved. *
6  * *
7  * This file is part of HDF. The full HDF copyright notice, including *
8  * terms governing use, modification, and redistribution, is contained in *
9  * the files COPYING and Copyright.html. COPYING can be found at the root *
10  * of the source code distribution tree; Copyright.html can be found at *
11  * http://hdfgroup.org/products/hdf4/doc/Copyright.html. If you do not have *
12  * access to either file, you may request a copy from help@hdfgroup.org. *
13  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
14 
15 /* $Id: dfsd.h 5444 2010-08-25 16:40:05Z byrn $ */
16 
17 /*-----------------------------------------------------------------------------
18  * File: dfsd.h
19  * Purpose: header file for the Scientific Data set
20  * Invokes: dfrig.h
21  * Contents:
22  * Structure definitions: DFSsdg
23  * Constant definitions: DFS_MAXLEN
24  * Remarks: This is included with user programs which use SDG
25  * Currently defined to be 2-D. Will later be increased to
26  * multiple dimensions
27  *---------------------------------------------------------------------------*/
28 
29 #ifndef _DFSD_H /* avoid re-inclusion */
30 #define _DFSD_H
31 
32 #include "H4api_adpt.h"
33 
34 #include "hdf.h"
35 
36 /* include numbertype and aid for 3.2 S. Xu */
37 /* structure to hold SDG info */
38 typedef struct DFSsdg
39  {
40  DFdi data; /* tag/ref of data in file */
41  intn rank; /* number of dimensions */
42  int32 *dimsizes; /* dimensions of data */
43  char *coordsys;
44  char *dataluf[3]; /* label/unit/format of data */
45  char **dimluf[3]; /* label/unit/format for each dim */
46  uint8 **dimscales; /* scales for each dimension */
47  uint8 max_min[16]; /* max, min values of data, */
48  /* currently atmost 8 bytes each */
49  int32 numbertype; /* default is float32 */
50  uint8 filenumsubclass; /* number format in the file, default is IEEE */
51  int32 aid; /* access id */
52  int32 compression; /* 0 -- not compressed */
53  int32 isndg; /* 0 -- pure sdg, written by 3.1 else ndg */
54  float64 cal, cal_err; /* calibration multiplier stuff */
55  float64 ioff, ioff_err; /* calibration offset stuff */
56  int32 cal_type; /* number type of data after calibration */
57  uint8 fill_value[DFSD_MAXFILL_LEN]; /* fill value if any specified */
58  intn fill_fixed; /* whether ther fill value is a fixed value, or it can change */
59  }
60 DFSsdg;
61 
62 /* DFnsdgle is the internal structure which stores SDG or NDS and */
63 /* related SDG in an HDF file. */
64 /* It is a linked list. */
65 
66 typedef struct DFnsdgle
67  {
68  DFdi nsdg; /* NDG from 3.2 or SDG from 3.1 */
69  DFdi sdg; /* Only special NDF has values in this field */
70  struct DFnsdgle *next;
71  }
72 DFnsdgle;
73 
74 typedef struct DFnsdg_t_hdr
75  {
76  uint32 size;
78  }
80 
81 #if defined c_plusplus || defined __cplusplus
82 extern "C"
83 {
84 #endif /* c_plusplus || __cplusplus */
85 
86  HDFLIBAPI int32 DFSDIopen
87  (const char * filename, int acc_mode);
88 
90  (int32 file_id);
91 
93  (DFSsdg * sdg);
94 
96  (DFSsdg * sdg);
97 
99  (const char * filename, intn rank, int32 maxsizes[], VOIDP data,
100  int isfortran);
101 
103  (const char * filename, intn rank, int32 * dimsizes, VOIDP data,
104  int accmode, int isfortran);
105 
107  (const char * filename, int32 winst[], int32 windims[], VOIDP data,
108  int32 dims[], int isfortran);
109 
111  (int32 windims[], VOIDP data, int32 dims[], int isfortran);
112 
114  (int isfortran);
115 
117  (char * filename);
118 
120  (intn * isndg);
121 
123  (intn * rank);
124 
126  (intn * rank);
127 
129  (int dim, const char * label, const char * unit, const char * format);
130 
132  (const char * label, const char * unit, const char * format,
133  const char * coordsys);
134 
135 #if defined c_plusplus || defined __cplusplus
136 }
137 #endif /* c_plusplus || __cplusplus */
138 
139 #endif /* _DFSD_H */
HDFFCLIBAPI intf winst[]
HDFLIBAPI int DFSDIgetdata(const char *filename, intn rank, int32 maxsizes[], VOIDP data, int isfortran)
uint32 size
Definition: dfsd.h:76
int32 numbertype
Definition: dfsd.h:49
HDFLIBAPI int DFSDIisndg(intn *isndg)
HDFLIBAPI int DFSDIgetslice(const char *filename, int32 winst[], int32 windims[], VOIDP data, int32 dims[], int isfortran)
float64 ioff_err
Definition: dfsd.h:55
HDFLIBAPI int DFSDIsetdimstrs(int dim, const char *label, const char *unit, const char *format)
uint8 max_min[16]
Definition: dfsd.h:47
HDFLIBAPI intn DFSDIrefresh(char *filename)
float64 cal
Definition: dfsd.h:54
char * filename
Definition: cdjpeg.h:133
HDFFCLIBAPI _fcd label
HDFLIBAPI int32 DFSDIopen(const char *filename, int acc_mode)
int32 cal_type
Definition: dfsd.h:56
Definition: hdf.h:24
HDFFCLIBAPI void intf dims[]
float64 ioff
Definition: dfsd.h:55
intn fill_fixed
Definition: dfsd.h:58
char ** dimluf[3]
Definition: dfsd.h:45
DFdi nsdg
Definition: dfsd.h:68
int32 aid
Definition: dfsd.h:51
HDFLIBAPI int DFSDIgetwrank(intn *rank)
HDFFCLIBAPI intf intf maxsizes[]
int32 compression
Definition: dfsd.h:52
DFdi data
Definition: dfsd.h:40
struct DFnsdgle * next
Definition: dfsd.h:70
HDFLIBAPI int DFSDIclearNT(DFSsdg *sdg)
HDFLIBAPI int DFSDIputslice(int32 windims[], VOIDP data, int32 dims[], int isfortran)
HDFLIBAPI int DFSDIsdginfo(int32 file_id)
HDFLIBAPI int DFSDIsetdatastrs(const char *label, const char *unit, const char *format, const char *coordsys)
struct DFSsdg DFSsdg
int32 * dimsizes
Definition: dfsd.h:42
#define DFSD_MAXFILL_LEN
Definition: hlimits.h:143
HDFFCLIBAPI _fcd _fcd _fcd intf * isfortran
HDFLIBAPI int DFSDIclear(DFSsdg *sdg)
int32 isndg
Definition: dfsd.h:53
Definition: dfsd.h:38
float64 cal_err
Definition: dfsd.h:54
DFdi sdg
Definition: dfsd.h:69
char * coordsys
Definition: dfsd.h:43
Definition: dfsd.h:66
DFnsdgle * nsdg_t
Definition: dfsd.h:77
uint8 filenumsubclass
Definition: dfsd.h:50
HDFFCLIBAPI intf * acc_mode
struct DFnsdgle DFnsdgle
HDFLIBAPI int DFSDIputdata(const char *filename, intn rank, int32 *dimsizes, VOIDP data, int accmode, int isfortran)
HDFFCLIBAPI _fcd unit
#define HDFLIBAPI
Definition: H4api_adpt.h:195
HDFLIBAPI int DFSDIgetrrank(intn *rank)
HDFFCLIBAPI intf intf windims[]
struct DFnsdg_t_hdr DFnsdg_t_hdr
uint8 ** dimscales
Definition: dfsd.h:46
HDFFCLIBAPI _fcd _fcd format
uint8 fill_value[DFSD_MAXFILL_LEN]
Definition: dfsd.h:57
intn rank
Definition: dfsd.h:41
HDFLIBAPI int DFSDIendslice(int isfortran)
char * dataluf[3]
Definition: dfsd.h:44

MISR Toolkit - Copyright © 2005 - 2020 Jet Propulsion Laboratory
Generated on Fri Jun 19 2020 22:49:52