comparison h264.c @ 7314:def12c3c7742 libavcodec

Do not forget marking disposed delayed pics as unused. Fixes issue335
author michael
date Sat, 19 Jul 2008 03:33:42 +0000
parents 094536cc2e18
children c7db87e35cae
comparison
equal deleted inserted replaced
7313:094536cc2e18 7314:def12c3c7742
7864 { 7864 {
7865 s->low_delay = 0; 7865 s->low_delay = 0;
7866 s->avctx->has_b_frames++; 7866 s->avctx->has_b_frames++;
7867 } 7867 }
7868 7868
7869 if(out_of_order || pics > s->avctx->has_b_frames)
7870 out->reference &= ~DELAYED_PIC_REF;
7869 if(pics <= s->avctx->has_b_frames || out_of_order) 7871 if(pics <= s->avctx->has_b_frames || out_of_order)
7870 out = NULL; 7872 out = NULL;
7871 7873
7872 if(out_of_order || pics > s->avctx->has_b_frames){ 7874 if(out_of_order || pics > s->avctx->has_b_frames){
7873 for(i=out_idx; h->delayed_pic[i]; i++) 7875 for(i=out_idx; h->delayed_pic[i]; i++)
7875 } 7877 }
7876 7878
7877 if(out){ 7879 if(out){
7878 *data_size = sizeof(AVFrame); 7880 *data_size = sizeof(AVFrame);
7879 7881
7880 out->reference &= ~DELAYED_PIC_REF;
7881 h->outputed_poc = out->poc; 7882 h->outputed_poc = out->poc;
7882 } 7883 }
7883 #endif 7884 #endif
7884 7885
7885 if(out) 7886 if(out)