[vlc-commits] avcodec/encoder: remove no-op (refs #18697)

Rémi Denis-Courmont git at videolan.org
Sat Nov 4 13:29:58 CET 2017


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sat Nov  4 14:25:52 2017 +0200| [6b42af3f7fe98ddd59b493281ffb80d6c26b24a0] | committer: Rémi Denis-Courmont

avcodec/encoder: remove no-op (refs #18697)

Changing AVCodecContext.noise_reduction at run-time has no effects.
Libavcodec only reads it during open.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=6b42af3f7fe98ddd59b493281ffb80d6c26b24a0
---

 modules/codec/avcodec/encoder.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/modules/codec/avcodec/encoder.c b/modules/codec/avcodec/encoder.c
index a1afe91040..37a0979559 100644
--- a/modules/codec/avcodec/encoder.c
+++ b/modules/codec/avcodec/encoder.c
@@ -1094,16 +1094,11 @@ static void check_hurry_up( encoder_sys_t *p_sys, AVFrame *frame, encoder_t *p_e
         if ( current_date + HURRY_UP_GUARD2 > frame->pts )
         {
             p_sys->p_context->trellis = 0;
-            p_sys->p_context->noise_reduction = p_sys->i_noise_reduction
-                + (HURRY_UP_GUARD2 + current_date - frame->pts) / 500;
             msg_Dbg( p_enc, "hurry up mode 2" );
         }
         else
         {
             p_sys->p_context->trellis = p_sys->b_trellis;
-
-            p_sys->p_context->noise_reduction =
-               p_sys->i_noise_reduction;
         }
     }
 



More information about the vlc-commits mailing list