lz4_stream.h
Go to the documentation of this file.
1 #ifndef LZ4_STREAM_H_
2 #define LZ4_STREAM_H_
3 
4 //******************************************************************************
5 //
8 //
9 //******************************************************************************
10 
11 #include "lz4.h"
12 
13 //*****************************************************************************
14 //
15 // If building with a C++ compiler, make all of the definitions in this header
16 // have a C binding.
17 //
18 //*****************************************************************************
19 #ifdef __cplusplus
20 extern "C"
21 {
22 #endif
23 
24 #include <stdint.h>
25 #include <stdbool.h>
26 
27 //******************************************************************************
28 //
30 //
31 //******************************************************************************
32 typedef enum {
48 
49 //******************************************************************************
50 //
52 //
53 //******************************************************************************
56  LZ4_streamState state;
58  uint16_t literalLength;
60  uint16_t matchLength;
62  uint16_t matchOffset;
64  uint8_t *dstPtr;
66  uint8_t *dstOrigin;
69  uint32_t dstLength;
71 
72 //******************************************************************************
73 //
75 //
76 //******************************************************************************
79  void *dst;
81  int32_t dstLength;
87 
88 //******************************************************************************
89 //
104 //
105 //******************************************************************************
107 
108 //******************************************************************************
109 //
125 //
126 //******************************************************************************
127 extern uint32_t LZ4_streamDecompressBlock(LZ4_streamDecompressBlockState *state, const void *data, uint16_t length, LZ4_status *status);
128 
129 //*****************************************************************************
130 //
131 // Mark the end of the C bindings section for C++ compilers.
132 //
133 //*****************************************************************************
134 #ifdef __cplusplus
135 }
136 #endif
137 
138 //******************************************************************************
139 //
140 // Close the Doxygen group.
142 //
143 //******************************************************************************
144 
145 #endif /* LZ4_STREAM_H_ */
bool containsBlockSize
Definition: lz4_stream.h:85
Next byte is the token.
Definition: lz4_stream.h:36
Decompression state for a streaming LZ4 block.
Definition: lz4_stream.h:54
uint32_t LZ4_streamDecompressBlock(LZ4_streamDecompressBlockState *state, const void *data, uint16_t length, LZ4_status *status)
Decompress a single LZ4 block as a stream of data.
Definition: lz4_stream.c:34
Next byte is the token.
Definition: lz4_stream.h:34
struct LZ4_streamDecompressBlockState LZ4_streamDecompressBlockState
Decompression state for a streaming LZ4 block.
uint16_t literalLength
Length of literals.
Definition: lz4_stream.h:58
uint16_t matchLength
Length of match.
Definition: lz4_stream.h:60
int32_t dstLength
Length of the destination data buffer.
Definition: lz4_stream.h:81
Next byte is a literal character.
Definition: lz4_stream.h:40
Next byte is the match length.
Definition: lz4_stream.h:42
uint16_t matchOffset
Offset address of match.
Definition: lz4_stream.h:62
LZ4_status
LZ4 status return types.
Definition: lz4.h:38
LZ4_streamState state
Decompress stream state.
Definition: lz4_stream.h:56
Next byte is the low match address offset.
Definition: lz4_stream.h:44
Next byte is the literal length.
Definition: lz4_stream.h:38
uint8_t * dstOrigin
Destination buffer pointer origin.
Definition: lz4_stream.h:66
LZ4_streamState
LZ4 streaming API state.
Definition: lz4_stream.h:32
void * dst
Pointer to the destination data buffer to store uncompressed data.
Definition: lz4_stream.h:79
Next byte is the high match address offset.
Definition: lz4_stream.h:46
Decompression parameters for a streaming LZ4 block.
Definition: lz4_stream.h:77
void LZ4_streamDecompressBlockInit(const LZ4_streamDecompressBlockParams *params, LZ4_streamDecompressBlockState *state, LZ4_status *status)
Initialize LZ4 stream decompression.
Definition: lz4_stream.c:10
struct LZ4_streamDecompressBlockParams LZ4_streamDecompressBlockParams
Decompression parameters for a streaming LZ4 block.
uint32_t dstLength
Definition: lz4_stream.h:69
uint8_t * dstPtr
Pointer to the destination data buffer to write.
Definition: lz4_stream.h:64
Copyright 2018, Texas Instruments Incorporated