]> granicus.if.org Git - libx264/commitdiff
param.b_repeat_headers (not yet used)
authorLoren Merritt <pengvado@videolan.org>
Sun, 27 Nov 2005 23:23:49 +0000 (23:23 +0000)
committerLoren Merritt <pengvado@videolan.org>
Sun, 27 Nov 2005 23:23:49 +0000 (23:23 +0000)
git-svn-id: svn://svn.videolan.org/x264/trunk@376 df754926-b1dd-0310-bc7b-ec298dee348c

encoder/encoder.c
x264.h

index ac5af3fd33b1836f414f270cedcab9a87445834a..50148104efd8f0af2ff5f64d0bc4fa58f8f7b1c2 100644 (file)
@@ -1325,7 +1325,7 @@ do_encode:
     h->i_nal_ref_idc = i_nal_ref_idc;
 
     /* Write SPS and PPS */
-    if( i_nal_type == NAL_SLICE_IDR )
+    if( i_nal_type == NAL_SLICE_IDR && h->param.b_repeat_headers )
     {
         if( h->fenc->i_frame == 0 )
         {
diff --git a/x264.h b/x264.h
index 1b914121accbb9283fdef4d445dd2896b107adaa..d30da7b0f91008f80137ac66d539b5cc4b3f50a3 100644 (file)
--- a/x264.h
+++ b/x264.h
@@ -35,7 +35,7 @@
 
 #include <stdarg.h>
 
-#define X264_BUILD 40
+#define X264_BUILD 41
 
 /* x264_t:
  *      opaque handler for decoder and encoder */
@@ -239,6 +239,7 @@ typedef struct
     } rc;
 
     int b_aud;                  /* generate access unit delimiters */
+    int b_repeat_headers        /* put SPS/PPS before each keyframe */
 } x264_param_t;
 
 typedef struct {