mirror of
https://github.com/Xevion/easy7zip.git
synced 2025-12-14 20:11:38 -06:00
4.44 beta
This commit is contained in:
committed by
Kornel Lesiński
parent
804edc5756
commit
d9666cf046
20
C/Compress/Huffman/HuffmanEncode.h
Executable file
20
C/Compress/Huffman/HuffmanEncode.h
Executable file
@@ -0,0 +1,20 @@
|
||||
// Compress/HuffmanEncode.h
|
||||
|
||||
#ifndef __COMPRESS_HUFFMANENCODE_H
|
||||
#define __COMPRESS_HUFFMANENCODE_H
|
||||
|
||||
#include "../../Types.h"
|
||||
|
||||
#define HUFFMAN_TEMP_SIZE(num) (num * 2)
|
||||
|
||||
/*
|
||||
Conditions:
|
||||
num <= 1024 = 2 ^ NUM_BITS
|
||||
Sum(freqs) < 4M = 2 ^ (32 - NUM_BITS)
|
||||
maxLen <= 16 = kMaxLen
|
||||
Num_Items(p) >= HUFFMAN_TEMP_SIZE(num)
|
||||
*/
|
||||
|
||||
void Huffman_Generate(const UInt32 *freqs, UInt32 *p, Byte *lens, UInt32 num, UInt32 maxLen);
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user