# HG changeset patch # User andoma # Date 1191480238 0 # Node ID 65b71bd21a4dd3c0cb535c3beb16d5a520447bfc # Parent 5290a3850c03fedd29dec0eba8aa88515a6a9530 Fix h->curr_pic_num for field pictures. Necessary for proper PAFF support. patch by Jeff Downs, heydowns a borg d com original thread: Subject: [FFmpeg-devel] [PATCH] Implement PAFF in H.264 Date: 18/09/07 20:30 diff -r 5290a3850c03 -r 65b71bd21a4d h264.c --- a/h264.c Thu Oct 04 06:41:49 2007 +0000 +++ b/h264.c Thu Oct 04 06:43:58 2007 +0000 @@ -3742,7 +3742,7 @@ h->curr_pic_num= h->frame_num; h->max_pic_num= 1<< h->sps.log2_max_frame_num; }else{ - h->curr_pic_num= 2*h->frame_num; + h->curr_pic_num= 2*h->frame_num + 1; h->max_pic_num= 1<<(h->sps.log2_max_frame_num + 1); } diff -r 5290a3850c03 -r 65b71bd21a4d h264.h --- a/h264.h Thu Oct 04 06:41:49 2007 +0000 +++ b/h264.h Thu Oct 04 06:43:58 2007 +0000 @@ -285,7 +285,7 @@ int prev_frame_num; ///< frame_num of the last pic for POC type 1/2 /** - * frame_num for frames or 2*frame_num for field pics. + * frame_num for frames or 2*frame_num+1 for field pics. */ int curr_pic_num;