libx264: Fix noise_reduction option assignment
authorVittorio Giovara <vittorio.giovara@gmail.com>
Tue, 16 Feb 2016 17:12:23 +0000 (12:12 -0500)
committerVittorio Giovara <vittorio.giovara@gmail.com>
Tue, 23 Feb 2016 00:06:48 +0000 (19:06 -0500)
First check the context, then check internal option. Drop the ! typo.
Introduced in 60f0fde3092d18d4d36555962c192af8691a099c.

libavcodec/libx264.c

index 7798ef3..8d72f1c 100644 (file)
@@ -457,11 +457,11 @@ FF_ENABLE_DEPRECATION_WARNINGS
         x4->params.analyse.i_me_range   = avctx->me_range;
 #if FF_API_PRIVATE_OPT
     FF_DISABLE_DEPRECATION_WARNINGS
-    if (!x4->noise_reduction >= 0)
+    if (avctx->noise_reduction >= 0)
         x4->noise_reduction = avctx->noise_reduction;
     FF_ENABLE_DEPRECATION_WARNINGS
 #endif
-    if (!x4->noise_reduction >= 0)
+    if (x4->noise_reduction >= 0)
         x4->params.analyse.i_noise_reduction = x4->noise_reduction;
     if (avctx->me_subpel_quality >= 0)
         x4->params.analyse.i_subpel_refine   = avctx->me_subpel_quality;