]> git.sesse.net Git - vlc/commitdiff
avcodec: fix vp8 default to check height for 720p
authorIlkka Ollakka <ileoo@videolan.org>
Sat, 5 Jun 2010 20:18:08 +0000 (23:18 +0300)
committerIlkka Ollakka <ileoo@videolan.org>
Sat, 5 Jun 2010 20:19:47 +0000 (23:19 +0300)
also fix sub 720p defaults

modules/codec/avcodec/encoder.c

index 90e76e65868982f0021f05a4da18d7476864134b..092dfee32f41fbf811fed80b45efa154aa3e01d3 100644 (file)
@@ -606,7 +606,7 @@ int OpenEncoder( vlc_object_t *p_this )
         if( !var_GetInteger( p_enc, ENC_CFG_PREFIX "keyint" ) )
            p_context->gop_size = 120;
         /* seems that ffmpeg presets have 720p as divider for buffers */
-        if( p_enc->fmt_out.video.i_width >= 720 )
+        if( p_enc->fmt_out.video.i_height >= 720 )
         {
            /* Check that we don't overrun users qmin/qmax values */
            if( !var_GetInteger( p_enc, ENC_CFG_PREFIX "qmin" ) )
@@ -626,7 +626,7 @@ int OpenEncoder( vlc_object_t *p_this )
         } else {
            if( !var_GetInteger( p_enc, ENC_CFG_PREFIX "qmin" ) )
            {
-              p_context->mb_qmin = p_context->qmin = FF_QP2LAMBDA;
+              p_context->mb_qmin = p_context->qmin = 1;
               p_context->mb_lmin = p_context->lmin = FF_QP2LAMBDA;
            }