MISR Toolkit  1.5.1
hcompi.h
Go to the documentation of this file.
1 /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
2  * Copyright by The HDF Group. *
3  * Copyright by the Board of Trustees of the University of Illinois. *
4  * All rights reserved. *
5  * *
6  * This file is part of HDF. The full HDF copyright notice, including *
7  * terms governing use, modification, and redistribution, is contained in *
8  * the files COPYING and Copyright.html. COPYING can be found at the root *
9  * of the source code distribution tree; Copyright.html can be found at *
10  * http://hdfgroup.org/products/hdf4/doc/Copyright.html. If you do not have *
11  * access to either file, you may request a copy from help@hdfgroup.org. *
12  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
13 
14 /* $Id: hcompi.h 4932 2007-09-07 17:17:23Z bmribler $ */
15 
16 /*-----------------------------------------------------------------------------
17  * File: hcompi.h
18  * Purpose: Internal library header file for compression information
19  * Dependencies: should be included after hdf.h
20  * Invokes:
21  * Contents:
22  * Structure definitions:
23  * Constant definitions:
24  *---------------------------------------------------------------------------*/
25 
26 /* avoid re-inclusion */
27 #ifndef __HCOMPI_H
28 #define __HCOMPI_H
29 
30 #include "hfile.h"
31 
32 /* Modeling information */
33 
34 /* structure for storing modeling information */
35 /* only allow modeling and master compression routines access */
36 
37 #include "mstdio.h" /* stdio modeling header */
38 
39 typedef struct comp_model_info_tag
40  {
41  comp_model_t model_type; /* model this stream is using */
42  union
43  { /* union of all the different types of model information */
44  comp_model_stdio_info_t stdio_info; /* stdio model info */
45  }
46  model_info;
47  funclist_t model_funcs; /* functions to perform modeling */
48  }
50 
51 /* Coding information */
52 
53 /* structure for storing modeling information */
54 /* only allow encoding and master compression routines access */
55 
56 #include "cnone.h" /* no encoding header */
57 #include "crle.h" /* run-length encoding header */
58 #include "cnbit.h" /* N-bit encoding header */
59 #include "cskphuff.h" /* Skipping huffman encoding header */
60 #include "cdeflate.h" /* gzip 'deflate' encoding header */
61 #include "cszip.h" /* szip encoding header */
62 
63 typedef struct comp_coder_info_tag
64  {
65  comp_coder_t coder_type; /* coding scheme this stream is using */
66  union
67  { /* union of all the different types of coding information */
68  comp_coder_none_info_t none_info; /* "None" coding info */
69  comp_coder_rle_info_t rle_info; /* RLE coding info */
70  comp_coder_nbit_info_t nbit_info; /* N-bit coding info */
71  comp_coder_skphuff_info_t skphuff_info; /* Skipping huffman coding info */
72  comp_coder_deflate_info_t deflate_info; /* gzip 'deflate' coding info */
73  comp_coder_szip_info_t szip_info; /* szip coding info */
74 
75  }
76  coder_info;
77  funclist_t coder_funcs; /* functions to perform encoding */
78  }
80 
81 /* structure for storing a state */
82 typedef struct comp_stateinfo_tag
83  {
84  uint32 d_offset; /* the offset of the state in the dataset */
85  uint32 c_offset; /* offset of the state in the compressed data */
86  comp_model_info_t minfo; /* modeling information */
87  comp_coder_info_t cinfo; /* coding information */
88  }
90 
91 /* structure for storing state caching information */
92 typedef struct comp_state_cache_tag
93  {
94  intn num_states; /* the number of states cached */
95  comp_stateinfo_t **comp_state; /* pointer to an array of pointers to
96  compression states */
97  }
99 
100 /* compinfo_t -- compressed element information structure */
101 typedef struct compinfo_tag
102  {
103  intn attached; /* number of access records attached
104  to this information structure */
105  int32 length; /* the actual length of the data elt */
106  uint16 comp_ref; /* compressed info ref. number */
107  int32 aid; /* AID of the compressed info */
108  comp_model_info_t minfo; /* modeling information */
109  comp_coder_info_t cinfo; /* coding information */
110  intn caching; /* whether caching is turned on */
111  comp_state_cache_t sinfo; /* state information for caching */
112  }
113 compinfo_t;
114 
115 #endif /* __HCOMPI_H */
comp_model_t
Definition: hcomp.h:31
comp_coder_t coder_type
Definition: hcompi.h:65
comp_model_info_t minfo
Definition: hcompi.h:86
struct comp_model_info_tag comp_model_info_t
intn caching
Definition: hcompi.h:110
comp_model_info_t minfo
Definition: hcompi.h:108
comp_state_cache_t sinfo
Definition: hcompi.h:111
struct comp_stateinfo_tag comp_stateinfo_t
struct comp_state_cache_tag comp_state_cache_t
comp_coder_deflate_info_t deflate_info
Definition: hcompi.h:72
intn attached
Definition: hcompi.h:103
comp_coder_rle_info_t rle_info
Definition: hcompi.h:69
comp_model_stdio_info_t stdio_info
Definition: hcompi.h:44
int32 length
Definition: hcompi.h:105
uint32 c_offset
Definition: hcompi.h:85
union comp_model_info_tag::@12 model_info
int32 aid
Definition: hcompi.h:107
funclist_t coder_funcs
Definition: hcompi.h:77
comp_coder_nbit_info_t nbit_info
Definition: hcompi.h:70
comp_coder_t
Definition: hcomp.h:38
struct comp_coder_info_tag comp_coder_info_t
comp_stateinfo_t ** comp_state
Definition: hcompi.h:95
uint16 comp_ref
Definition: hcompi.h:106
struct compinfo_tag compinfo_t
comp_coder_szip_info_t szip_info
Definition: hcompi.h:73
comp_coder_info_t cinfo
Definition: hcompi.h:109
funclist_t model_funcs
Definition: hcompi.h:47
uint32 d_offset
Definition: hcompi.h:84
comp_coder_none_info_t none_info
Definition: hcompi.h:68
comp_model_t model_type
Definition: hcompi.h:41
comp_coder_info_t cinfo
Definition: hcompi.h:87
comp_coder_skphuff_info_t skphuff_info
Definition: hcompi.h:71

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