Geant4-11
Data Structures | Macros | Typedefs | Functions | Variables
deflate.h File Reference
#include "zutil.h"

Go to the source code of this file.

Data Structures

struct  ct_data_s
 
struct  internal_state
 
struct  tree_desc_s
 

Macros

#define _tr_tally_dist(s, distance, length, flush)
 
#define _tr_tally_lit(s, c, flush)
 
#define BL_CODES   19
 
#define Buf_size   16
 
#define BUSY_STATE   113 /* deflate -> FINISH_STATE */
 
#define Code   fc.code
 
#define COMMENT_STATE   91 /* gzip comment -> HCRC_STATE */
 
#define d_code(dist)    ((dist) < 256 ? _dist_code[dist] : _dist_code[256+((dist)>>7)])
 
#define D_CODES   30
 
#define Dad   dl.dad
 
#define EXTRA_STATE   69 /* gzip extra block -> NAME_STATE */
 
#define FINISH_STATE   666 /* stream complete */
 
#define Freq   fc.freq
 
#define GZIP
 
#define GZIP_STATE   57 /* gzip header -> BUSY_STATE | EXTRA_STATE */
 
#define HCRC_STATE   103 /* gzip header CRC -> BUSY_STATE */
 
#define HEAP_SIZE   (2*L_CODES+1)
 
#define INIT_STATE   42 /* zlib header -> BUSY_STATE */
 
#define L_CODES   (LITERALS+1+LENGTH_CODES)
 
#define Len   dl.len
 
#define LENGTH_CODES   29
 
#define LITERALS   256
 
#define MAX_BITS   15
 
#define MAX_DIST(s)   ((s)->w_size-MIN_LOOKAHEAD)
 
#define max_insert_length   max_lazy_match
 
#define MIN_LOOKAHEAD   (MAX_MATCH+MIN_MATCH+1)
 
#define NAME_STATE   73 /* gzip file name -> COMMENT_STATE */
 
#define put_byte(s, c)   {s->pending_buf[s->pending++] = (Bytef)(c);}
 
#define WIN_INIT   MAX_MATCH
 

Typedefs

typedef struct ct_data_s ct_data
 
typedef struct internal_state deflate_state
 
typedef unsigned IPos
 
typedef ush Pos
 
typedef Pos FAR Posf
 
typedef struct static_tree_desc_s static_tree_desc
 
typedef struct tree_desc_s tree_desc
 

Functions

void ZLIB_INTERNAL _tr_init OF ((deflate_state *s))
 
void ZLIB_INTERNAL _tr_flush_block OF ((deflate_state *s, charf *buf, ulg stored_len, int last))
 
int ZLIB_INTERNAL _tr_tally OF ((deflate_state *s, unsigned dist, unsigned lc))
 

Variables

uch ZLIB_INTERNAL _dist_code []
 
uch ZLIB_INTERNAL _length_code []
 

Macro Definition Documentation

◆ _tr_tally_dist

#define _tr_tally_dist (   s,
  distance,
  length,
  flush 
)
Value:
{ uch len = (uch)(length); \
ush dist = (ush)(distance); \
s->d_buf[s->last_lit] = dist; \
s->l_buf[s->last_lit++] = len; \
dist--; \
s->dyn_ltree[_length_code[len]+LITERALS+1].Freq++; \
s->dyn_dtree[d_code(dist)].Freq++; \
flush = (s->last_lit == s->lit_bufsize-1); \
}
static constexpr double s
Definition: G4SIunits.hh:154
#define LITERALS
Definition: deflate.h:32
#define d_code(dist)
Definition: deflate.h:307
uch ZLIB_INTERNAL _length_code[]
Definition: trees.h:102
unsigned short ush
Definition: zutil.h:44
unsigned char uch
Definition: zutil.h:42

Definition at line 332 of file deflate.h.

◆ _tr_tally_lit

#define _tr_tally_lit (   s,
  c,
  flush 
)
Value:
{ uch cc = (c); \
s->d_buf[s->last_lit] = 0; \
s->l_buf[s->last_lit++] = cc; \
s->dyn_ltree[cc].Freq++; \
flush = (s->last_lit == s->lit_bufsize-1); \
}

Definition at line 325 of file deflate.h.

◆ BL_CODES

#define BL_CODES   19

Definition at line 41 of file deflate.h.

◆ Buf_size

#define Buf_size   16

Definition at line 50 of file deflate.h.

◆ BUSY_STATE

#define BUSY_STATE   113 /* deflate -> FINISH_STATE */

Definition at line 61 of file deflate.h.

◆ Code

#define Code   fc.code

Definition at line 79 of file deflate.h.

◆ COMMENT_STATE

#define COMMENT_STATE   91 /* gzip comment -> HCRC_STATE */

Definition at line 59 of file deflate.h.

◆ d_code

#define d_code (   dist)     ((dist) < 256 ? _dist_code[dist] : _dist_code[256+((dist)>>7)])

Definition at line 307 of file deflate.h.

◆ D_CODES

#define D_CODES   30

Definition at line 38 of file deflate.h.

◆ Dad

#define Dad   dl.dad

Definition at line 80 of file deflate.h.

◆ EXTRA_STATE

#define EXTRA_STATE   69 /* gzip extra block -> NAME_STATE */

Definition at line 57 of file deflate.h.

◆ FINISH_STATE

#define FINISH_STATE   666 /* stream complete */

Definition at line 62 of file deflate.h.

◆ Freq

#define Freq   fc.freq

Definition at line 78 of file deflate.h.

◆ GZIP

#define GZIP

Definition at line 22 of file deflate.h.

◆ GZIP_STATE

#define GZIP_STATE   57 /* gzip header -> BUSY_STATE | EXTRA_STATE */

Definition at line 55 of file deflate.h.

◆ HCRC_STATE

#define HCRC_STATE   103 /* gzip header CRC -> BUSY_STATE */

Definition at line 60 of file deflate.h.

◆ HEAP_SIZE

#define HEAP_SIZE   (2*L_CODES+1)

Definition at line 44 of file deflate.h.

◆ INIT_STATE

#define INIT_STATE   42 /* zlib header -> BUSY_STATE */

Definition at line 53 of file deflate.h.

◆ L_CODES

#define L_CODES   (LITERALS+1+LENGTH_CODES)

Definition at line 35 of file deflate.h.

◆ Len

#define Len   dl.len

Definition at line 81 of file deflate.h.

◆ LENGTH_CODES

#define LENGTH_CODES   29

Definition at line 29 of file deflate.h.

◆ LITERALS

#define LITERALS   256

Definition at line 32 of file deflate.h.

◆ MAX_BITS

#define MAX_BITS   15

Definition at line 47 of file deflate.h.

◆ MAX_DIST

#define MAX_DIST (   s)    ((s)->w_size-MIN_LOOKAHEAD)

Definition at line 288 of file deflate.h.

◆ max_insert_length

#define max_insert_length   max_lazy_match

Definition at line 181 of file deflate.h.

◆ MIN_LOOKAHEAD

#define MIN_LOOKAHEAD   (MAX_MATCH+MIN_MATCH+1)

Definition at line 283 of file deflate.h.

◆ NAME_STATE

#define NAME_STATE   73 /* gzip file name -> COMMENT_STATE */

Definition at line 58 of file deflate.h.

◆ put_byte

#define put_byte (   s,
 
)    {s->pending_buf[s->pending++] = (Bytef)(c);}

Definition at line 280 of file deflate.h.

◆ WIN_INIT

#define WIN_INIT   MAX_MATCH

Definition at line 293 of file deflate.h.

Typedef Documentation

◆ ct_data

typedef struct ct_data_s ct_data

◆ deflate_state

typedef struct internal_state deflate_state

◆ IPos

typedef unsigned IPos

Definition at line 93 of file deflate.h.

◆ Pos

typedef ush Pos

Definition at line 91 of file deflate.h.

◆ Posf

typedef Pos FAR Posf

Definition at line 92 of file deflate.h.

◆ static_tree_desc

Definition at line 83 of file deflate.h.

◆ tree_desc

typedef struct tree_desc_s tree_desc

Function Documentation

◆ OF() [1/3]

◆ OF() [2/3]

void ZLIB_INTERNAL _tr_flush_block OF ( (deflate_state *s, charf *buf, ulg stored_len, int last)  )

◆ OF() [3/3]

int ZLIB_INTERNAL _tr_tally OF ( (deflate_state *s, unsigned dist, unsigned lc)  )

Variable Documentation

◆ _dist_code

uch ZLIB_INTERNAL _dist_code[]
extern

Definition at line 73 of file trees.h.

Referenced by tr_static_init().

◆ _length_code

uch ZLIB_INTERNAL _length_code[]
extern

Definition at line 102 of file trees.h.

Referenced by _tr_tally(), compress_block(), and tr_static_init().