1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

Cleanup decode_block_progressive()

Originally committed as revision 25543 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
Michael Niedermayer 2010-10-21 22:44:34 +00:00
parent 614252863d
commit 7f4a1e8f6c

View File

@ -506,13 +506,13 @@ static int decode_block_progressive(MJpegDecodeContext *s, DCTELEM *block, uint8
if(run == 0xF){// ZRL - skip 15 coefficients if(run == 0xF){// ZRL - skip 15 coefficients
i += 15; i += 15;
}else{ }else{
val = run; val = (1 << run);
run = (1 << run); if(run){
UPDATE_CACHE(re, &s->gb); UPDATE_CACHE(re, &s->gb);
run += (GET_CACHE(re, &s->gb) >> (32 - val)) & (run - 1); val += NEG_USR32(GET_CACHE(re, &s->gb), run);
if(val) LAST_SKIP_BITS(re, &s->gb, run);
LAST_SKIP_BITS(re, &s->gb, val); }
*EOBRUN = run - 1; *EOBRUN = val - 1;
break; break;
} }
} }