# HG changeset patch # User michaelni # Date 1017980581 0 # Node ID 072c4ff05e62f13de205c49a96676587246d1b98 # Parent 764aeec1320ebbfae5be0b7f9e766138af9346de b frames & slices bugfix diff -r 764aeec1320e -r 072c4ff05e62 h263dec.c --- a/h263dec.c Fri Apr 05 04:09:04 2002 +0000 +++ b/h263dec.c Fri Apr 05 04:23:01 2002 +0000 @@ -220,9 +220,15 @@ if (h > 16) h = 16; offset = y * s->linesize; - src_ptr[0] = s->current_picture[0] + offset; - src_ptr[1] = s->current_picture[1] + (offset >> 2); - src_ptr[2] = s->current_picture[2] + (offset >> 2); + if(s->pict_type==B_TYPE || (!s->has_b_frames)){ + src_ptr[0] = s->current_picture[0] + offset; + src_ptr[1] = s->current_picture[1] + (offset >> 2); + src_ptr[2] = s->current_picture[2] + (offset >> 2); + } else { + src_ptr[0] = s->last_picture[0] + offset; + src_ptr[1] = s->last_picture[1] + (offset >> 2); + src_ptr[2] = s->last_picture[2] + (offset >> 2); + } avctx->draw_horiz_band(avctx, src_ptr, s->linesize, y, s->width, h); }