Commit 090aaaf7 authored by Alex Converse's avatar Alex Converse

mpeg12enc: Remove write-only variables.

parent 7c5dfc17
......@@ -77,10 +77,9 @@ static void init_uni_ac_vlc(RLTable *rl, uint8_t *uni_ac_vlc_len){
if (!level)
continue;
for(run=0; run<64; run++){
int len, bits, code;
int len, code;
int alevel= FFABS(level);
int sign= (level>>31)&1;
if (alevel > rl->max_level[0][run])
code= 111; /*rl->n*/
......@@ -88,25 +87,15 @@ static void init_uni_ac_vlc(RLTable *rl, uint8_t *uni_ac_vlc_len){
code= rl->index_run[0][run] + alevel - 1;
if (code < 111 /* rl->n */) {
/* store the vlc & sign at once */
/* length of vlc and sign */
len= rl->table_vlc[code][1]+1;
bits= (rl->table_vlc[code][0]<<1) + sign;
} else {
len= rl->table_vlc[111/*rl->n*/][1]+6;
bits= rl->table_vlc[111/*rl->n*/][0]<<6;
bits|= run;
if (alevel < 128) {
bits<<=8; len+=8;
bits|= level & 0xff;
len += 8;
} else {
bits<<=16; len+=16;
bits|= level & 0xff;
if (level < 0) {
bits|= 0x8001 + level + 255;
} else {
bits|= level & 0xffff;
}
len += 16;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment