apps/ccam/gzio_compress.c File Reference

#include <stdio.h>
#include "zlib/zutil.h"
#include "gzio_compress.h"

Include dependency graph for gzio_compress.c:

Go to the source code of this file.

Data Structures

struct  internal_state
struct  gz_stream

Defines

#define Z_BUFSIZE   16384
#define Z_PRINTF_BUFSIZE   4096
#define ALLOC(size)   malloc(size)
#define TRYFREE(p)   {if (p) free(p);}
#define ASCII_FLAG   0x01
#define HEAD_CRC   0x02
#define EXTRA_FIELD   0x04
#define ORIG_NAME   0x08
#define COMMENT   0x10
#define RESERVED   0xE0

Functions

gzFile gz_useFile (FILE *file, const char *mode)
local gzFile gz_open OF ((const char *path, const char *mode, intfd))
local int do_flush OF ((gzFile file, int flush))
local int destroy OF ((gz_stream *s))
local void putLong OF ((FILE *file, uLong x))
local int destroy (gz_stream *s)
int ZEXPORT gzwrite (gzFile file, const voidp buf, unsigned len)
int ZEXPORTVA gzprintf (gzFile file, const char *format, int a1, int a2, int a3, int a4, int a5, int a6, int a7, int a8, int a9, int a10, int a11, int a12, int a13, int a14, int a15, int a16, int a17, int a18, int a19, int a20)
local int do_flush (gzFile file, int flush)
z_off_t ZEXPORT gzseek (gzFile file, z_off_t offset, int whence)
z_off_t ZEXPORT gztell (gzFile file)
int ZEXPORT gzeof (gzFile file)
local void putLong (FILE *file, uLong x)
int ZEXPORT gzclose (gzFile file)
const char *ZEXPORT gzerror (gzFile file, int *errnum)

Variables

static int gz_magic [2] = {0x1f, 0x8b}


Define Documentation

#define ALLOC ( size   )     malloc(size)

Definition at line 28 of file gzio_compress.c.

Referenced by gz_useFile(), gzerror(), and gzseek().

#define ASCII_FLAG   0x01

Definition at line 34 of file gzio_compress.c.

#define COMMENT   0x10

Definition at line 38 of file gzio_compress.c.

#define EXTRA_FIELD   0x04

Definition at line 36 of file gzio_compress.c.

#define HEAD_CRC   0x02

Definition at line 35 of file gzio_compress.c.

#define ORIG_NAME   0x08

Definition at line 37 of file gzio_compress.c.

#define RESERVED   0xE0

Definition at line 39 of file gzio_compress.c.

#define TRYFREE (  )     {if (p) free(p);}

Definition at line 29 of file gzio_compress.c.

Referenced by destroy(), and gzerror().

#define Z_BUFSIZE   16384

Definition at line 21 of file gzio_compress.c.

Referenced by do_flush(), gz_useFile(), gzseek(), and gzwrite().

#define Z_PRINTF_BUFSIZE   4096

Definition at line 25 of file gzio_compress.c.

Referenced by gzprintf().


Function Documentation

local int destroy ( gz_stream s  ) 

Definition at line 162 of file gzio_compress.c.

References TRYFREE.

Referenced by gz_useFile(), and gzclose().

local int do_flush ( gzFile  file,
int  flush 
)

Definition at line 298 of file gzio_compress.c.

References s, and Z_BUFSIZE.

Referenced by gzclose().

gzFile gz_useFile ( FILE *  file,
const char *  mode 
)

Definition at line 72 of file gzio_compress.c.

References ALLOC, crc32, destroy(), gz_magic, s, and Z_BUFSIZE.

Referenced by exportVRMLStart().

int ZEXPORT gzclose ( gzFile  file  ) 

Definition at line 431 of file gzio_compress.c.

References destroy(), do_flush(), putLong(), and s.

Referenced by export_vrml(), and main().

int ZEXPORT gzeof ( gzFile  file  ) 

Definition at line 404 of file gzio_compress.c.

References s.

const char* ZEXPORT gzerror ( gzFile  file,
int errnum 
)

Definition at line 461 of file gzio_compress.c.

References ALLOC, s, and TRYFREE.

int ZEXPORTVA gzprintf ( gzFile  file,
const char *  format,
int  a1,
int  a2,
int  a3,
int  a4,
int  a5,
int  a6,
int  a7,
int  a8,
int  a9,
int  a10,
int  a11,
int  a12,
int  a13,
int  a14,
int  a15,
int  a16,
int  a17,
int  a18,
int  a19,
int  a20 
)

Definition at line 270 of file gzio_compress.c.

References gzwrite(), snprintf(), and Z_PRINTF_BUFSIZE.

Referenced by export_vrml(), exportBottomEdges(), exportBottomFaces(), exportColorSet(), exportCoordinateSet(), exportFacesAppearance(), exportIFLSEnd(), exportIFSStart(), exportILSStart(), exportIsolineCoord(), exportIsolineNode(), exportIsolinesAppearance(), exportSideEdges(), exportSideFaces(), exportSwitchEnd(), exportSwitchStart(), exportTopEdges(), exportTopFaces(), exportTransformEnd(), exportTransformStart(), exportVRMLStart(), exportVRMLViewpoints(), and main().

z_off_t ZEXPORT gzseek ( gzFile  file,
z_off_t  offset,
int  whence 
)

Definition at line 347 of file gzio_compress.c.

References ALLOC, gzwrite(), s, and Z_BUFSIZE.

Referenced by gztell().

z_off_t ZEXPORT gztell ( gzFile  file  ) 

Definition at line 394 of file gzio_compress.c.

References gzseek().

int ZEXPORT gzwrite ( gzFile  file,
const voidp  buf,
unsigned  len 
)

Definition at line 200 of file gzio_compress.c.

References crc32, s, and Z_BUFSIZE.

Referenced by gzprintf(), and gzseek().

local void putLong OF ( (FILE *file, uLong x  ) 

local int destroy OF ( (gz_stream *s  ) 

local int do_flush OF ( (gzFile file, int flush)   ) 

local gzFile gz_open OF ( (const char *path, const char *mode, intfd)   ) 

local void putLong ( FILE *  file,
uLong  x 
)

Definition at line 415 of file gzio_compress.c.

Referenced by gzclose().


Variable Documentation

int gz_magic[2] = {0x1f, 0x8b} [static]

Definition at line 31 of file gzio_compress.c.

Referenced by gz_useFile().


Generated on Thu Aug 7 16:19:37 2008 for elphel by  doxygen 1.5.1