[FFmpeg-cvslog] h264: Fix concealment regression introduced by babf4fe01a808327d53977ba319c113a930180b1

Michael Niedermayer git at videolan.org
Sat Dec 10 23:39:06 CET 2011


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sat Dec 10 23:26:38 2011 +0100| [3dea28cc2ef22861347918b6740c4c05c46a6614] | committer: Michael Niedermayer

h264: Fix concealment regression introduced by babf4fe01a808327d53977ba319c113a930180b1
Limit the new case to when the decoder is flushed instead of at each idr frame

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=3dea28cc2ef22861347918b6740c4c05c46a6614
---

 libavcodec/h264.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/libavcodec/h264.c b/libavcodec/h264.c
index 2d60470..7daca10 100644
--- a/libavcodec/h264.c
+++ b/libavcodec/h264.c
@@ -2371,7 +2371,7 @@ static void implicit_weight_table(H264Context *h, int field){
 static void idr(H264Context *h){
     int i;
     ff_h264_remove_all_refs(h);
-    h->prev_frame_num= -1;
+    h->prev_frame_num= 0;
     h->prev_frame_num_offset= 0;
     h->prev_poc_msb= 1<<16;
     h->prev_poc_lsb= 0;
@@ -2391,6 +2391,7 @@ static void flush_dpb(AVCodecContext *avctx){
     h->outputed_poc=h->next_outputed_poc= INT_MIN;
     h->prev_interlaced_frame = 1;
     idr(h);
+    h->prev_frame_num= -1;
     if(h->s.current_picture_ptr)
         h->s.current_picture_ptr->f.reference = 0;
     h->s.first_field= 0;



More information about the ffmpeg-cvslog mailing list