unsigned char codelength;
} SHUFFCODE;
-int shuff_decode_file(char *inputfile, char *outputfile);
-int shuff_encode_file(char *inputfile, char *outputfile, long volsize);
+typedef struct t_huff {
+ FILE *tmpfp; /* filepointer al temporal para un shuff_bychunk */
+ char *sourcefile; /* Nombre del archivo a comprimir */
+ char *targetfile; /* Nombre del archivo comprimido */
+ t_freq *freqtable; /* Tabla de frecuencias */
+ t_freq sumfreq; /* Frecuencia total acumulada */
+ long volsize; /* Tamanio de volumen para multivol */
+ char preloadfreq; /* 1 freqtable preloaded (bychunk|canonico) - 0 byfile */
+
+} HUFF_STATE;
+
+HUFF_STATE *shuff_init_static_byfile(char *inputfile, char *outputfile, long volsize);
+HUFF_STATE *shuff_init_static_bychunk(char *outputfile, long volsize);
+void shuff_deinit_static_byfile(HUFF_STATE *fshuff);
+void shuff_deinit_static_bychunk(HUFF_STATE *cshuff);
+int shuff_decode_file(HUFF_STATE *shuff);
+int shuff_encode_file(HUFF_STATE *shuff);
#endif /* _STATICHUFF_H_ */