Documentation ¶
Index ¶
- Constants
- type LZSS
- func (c *LZSS) AddToCompressData(compressData []byte, tmpU, flags uint32, encoded bool) []byte
- func (c *LZSS) Compress(rawData []byte) []byte
- func (c *LZSS) CompressMode0(rawData []byte) []byte
- func (c *LZSS) CompressMode1(rawData []byte) []byte
- func (c *LZSS) CountBitToZero(n byte) uint32
- func (c *LZSS) Decompress(compressData []byte) []byte
- func (c *LZSS) DecompressMode0(compressData []byte) []byte
- func (c *LZSS) DecompressMode1(compressData []byte) []byte
- func (c *LZSS) GetChunkByte(data []byte, min, max int) []byte
- func (c *LZSS) GetEncodedData(chunk uint32) (position, length int)
- func (c *LZSS) Init()
- func (c *LZSS) PutByteToUint32(data []byte) uint32
- func (c *LZSS) PutUint32ToByte(x uint32) (buffer []byte, nbWrite int)
- func (c *LZSS) SearchBytePattern(data, pattern []byte, excludeIndex int) (position, length int)
Constants ¶
View Source
const RELATIVE = 1
RELATIVE define the started count to current index
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LZSS ¶
type LZSS struct { Mode int DictSize int PositionMode int NumByteEncode int MaxMatch int MinMatch int Length int Position int MaskLength uint32 MaskPosition uint32 }
LZSS config struct for lzss
func (*LZSS) AddToCompressData ¶
AddToCompressData add encoded data in final byte array
func (*LZSS) CompressMode0 ¶
CompressMode0 compress in lzss with mode 0
func (*LZSS) CompressMode1 ¶
CompressMode1 compress in lzss with mode 1
func (*LZSS) CountBitToZero ¶
CountBitToZero convert []byte to uint32
func (*LZSS) Decompress ¶
Decompress choose good mode for decompression
func (*LZSS) DecompressMode0 ¶
DecompressMode0 decompress in lzss with mode 0
func (*LZSS) DecompressMode1 ¶
DecompressMode1 decompress in lzss with mode 1
func (*LZSS) GetChunkByte ¶
GetChunkByte slice byte array without error bound range
func (*LZSS) GetEncodedData ¶
GetEncodedData return feature encoded pattern
func (*LZSS) PutByteToUint32 ¶
PutByteToUint32 convert []byte to uint32
func (*LZSS) PutUint32ToByte ¶
PutUint32ToByte convert uint32 to []byte
Click to show internal directories.
Click to hide internal directories.