[Ffmpeg-cvslog] r8055 - trunk/libavcodec/h264.c

michael subversion
Wed Feb 21 22:16:08 CET 2007


Author: michael
Date: Wed Feb 21 22:16:07 2007
New Revision: 8055

Modified:
   trunk/libavcodec/h264.c

Log:
output delayed frames
fixes:
CANL4_SVA_B.264
NL3_SVA_C.264
NL3_SVA_E.264


Modified: trunk/libavcodec/h264.c
==============================================================================
--- trunk/libavcodec/h264.c	(original)
+++ trunk/libavcodec/h264.c	Wed Feb 21 22:16:07 2007
@@ -8244,6 +8244,26 @@
 
    /* no supplementary picture */
     if (buf_size == 0) {
+        Picture *out;
+        int i, out_idx;
+
+//FIXME factorize this with the output code below
+        out = h->delayed_pic[0];
+        out_idx = 0;
+        for(i=1; h->delayed_pic[i] && !h->delayed_pic[i]->key_frame; i++)
+            if(h->delayed_pic[i]->poc < out->poc){
+                out = h->delayed_pic[i];
+                out_idx = i;
+            }
+
+        for(i=out_idx; h->delayed_pic[i]; i++)
+            h->delayed_pic[i] = h->delayed_pic[i+1];
+
+        if(out){
+            *data_size = sizeof(AVFrame);
+            *pict= *(AVFrame*)out;
+        }
+
         return 0;
     }
 




More information about the ffmpeg-cvslog mailing list