changeset 7839:e6348a5656e0 libavcodec

Add support for creating Simple Profile (I-frame only, no arithmetic coding) Dirac bytestreams. patch by Anuradha Suraparaju, anuradha rd.bbc.co uk
author diego
date Tue, 09 Sep 2008 14:47:47 +0000
parents 88f4153caa21
children 38dd4fd9f107
files libdiracenc.c libschroedingerenc.c
diffstat 2 files changed, 9 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/libdiracenc.c	Tue Sep 09 14:42:50 2008 +0000
+++ b/libdiracenc.c	Tue Sep 09 14:47:47 2008 +0000
@@ -175,9 +175,11 @@
     }
 
     /* Intra-only sequence */
-    if (avccontext->gop_size == 0 )
+    if (avccontext->gop_size == 0 ) {
         p_dirac_params->enc_ctx.enc_params.num_L1 = 0;
-    else
+        if (avccontext->coder_type == FF_CODER_TYPE_VLC)
+            p_dirac_params->enc_ctx.enc_params.using_ac = 0;
+    } else
         avccontext->has_b_frames = 1;
 
     if (avccontext->flags & CODEC_FLAG_QSCALE) {
--- a/libschroedingerenc.c	Tue Sep 09 14:42:50 2008 +0000
+++ b/libschroedingerenc.c	Tue Sep 09 14:47:47 2008 +0000
@@ -149,6 +149,11 @@
         schro_encoder_setting_set_double (p_schro_params->encoder,
                                           "gop_structure",
                                           SCHRO_ENCODER_GOP_INTRA_ONLY);
+
+        if (avccontext->coder_type == FF_CODER_TYPE_VLC) {
+            schro_encoder_setting_set_double (p_schro_params->encoder,
+                                              "enable_noarith", 1);
+        }
     }
     else {
         schro_encoder_setting_set_double (p_schro_params->encoder,