|
|
|
@ -170,13 +170,13 @@ static int build_table(VLC *vlc, int table_nb_bits, int nb_codes, |
|
|
|
|
return -1; |
|
|
|
|
table = &vlc->table[table_index]; |
|
|
|
|
|
|
|
|
|
for(i=0;i<table_size;i++) { |
|
|
|
|
for (i = 0; i < table_size; i++) { |
|
|
|
|
table[i][1] = 0; //bits
|
|
|
|
|
table[i][0] = -1; //codes
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/* first pass: map codes and compute auxillary table sizes */ |
|
|
|
|
for(i=0;i<nb_codes;i++) { |
|
|
|
|
for (i = 0; i < nb_codes; i++) { |
|
|
|
|
n = codes[i].bits; |
|
|
|
|
code = codes[i].code; |
|
|
|
|
symbol = codes[i].symbol; |
|
|
|
@ -192,7 +192,7 @@ static int build_table(VLC *vlc, int table_nb_bits, int nb_codes, |
|
|
|
|
j = bitswap_32(code); |
|
|
|
|
inc = 1 << n; |
|
|
|
|
} |
|
|
|
|
for(k=0;k<nb;k++) { |
|
|
|
|
for (k = 0; k < nb; k++) { |
|
|
|
|
#ifdef DEBUG_VLC |
|
|
|
|
av_log(NULL, AV_LOG_DEBUG, "%4x: code=%d n=%d\n", |
|
|
|
|
j, i, n); |
|
|
|
|