Exemplo n.º 1
0
        public int Encode(string in_f, string out_f)
        {
            HuffTable table = new HuffTable(in_f);

            MkTree(table);
            //table.Print();
            //Console.ReadLine();
            //write_encode(tree, out_f);
            return(0);
        }
Exemplo n.º 2
0
        private void MkTree(HuffTable t)
        {
            int index = 0;

            Nodes = t.Table;

            while (Nodes.Count > 1)
            {
                Combine(Nodes[index], Nodes[index + 1], index);
            }
        }