[vlc-devel] [PATCH] deinterlace: inherit the deinterlace mode from the upper objects

Steve Lhomme robux4 at videolabs.io
Mon Jul 3 10:11:15 CEST 2017


We don't need it locally.

--
replaces https://patches.videolan.org/patch/17246/
- remove another unused define
---
 modules/video_filter/deinterlace/deinterlace.c | 13 ++-----------
 modules/video_filter/deinterlace/deinterlace.h | 14 --------------
 2 files changed, 2 insertions(+), 25 deletions(-)

diff --git a/modules/video_filter/deinterlace/deinterlace.c b/modules/video_filter/deinterlace/deinterlace.c
index d028834998..a73cb7bc59 100644
--- a/modules/video_filter/deinterlace/deinterlace.c
+++ b/modules/video_filter/deinterlace/deinterlace.c
@@ -51,11 +51,6 @@
  * Module descriptor
  *****************************************************************************/
 
-#define MODE_TEXT N_("Deinterlace mode")
-
-#define SOUT_MODE_TEXT N_("Streaming deinterlace mode")
-#define SOUT_MODE_LONGTEXT N_("Deinterlace method to use for streaming.")
-
 #define FILTER_CFG_PREFIX "sout-deinterlace-"
 
 /* Tooltips drop linefeeds (at least in the Qt GUI);
@@ -100,10 +95,6 @@ vlc_module_begin ()
     set_category( CAT_VIDEO )
     set_subcategory( SUBCAT_VIDEO_VFILTER )
 
-    add_string( FILTER_CFG_PREFIX "mode", "blend", SOUT_MODE_TEXT,
-                SOUT_MODE_LONGTEXT, false )
-        change_string_list( mode_list, mode_list_text )
-        change_safe ()
     add_integer( FILTER_CFG_PREFIX "phosphor-chroma", 2, PHOSPHOR_CHROMA_TEXT,
                 PHOSPHOR_CHROMA_LONGTEXT, true )
         change_integer_list( phosphor_chroma_list, phosphor_chroma_list_text )
@@ -127,7 +118,7 @@ vlc_module_end ()
  * and reading logic for them implemented in Open().
  */
 static const char *const ppsz_filter_options[] = {
-    "mode", "phosphor-chroma", "phosphor-dimmer",
+    "phosphor-chroma", "phosphor-dimmer",
     NULL
 };
 
@@ -320,7 +311,7 @@ notsupp:
 
     config_ChainParse( p_filter, FILTER_CFG_PREFIX, ppsz_filter_options,
                        p_filter->p_cfg );
-    char *psz_mode = var_InheritString( p_filter, FILTER_CFG_PREFIX "mode" );
+    char *psz_mode = var_InheritString( p_filter, "deinterlace-mode" );
     SetFilterMethod( p_filter, psz_mode, packed );
 
     InitDeinterlacingContext( &p_sys->context );
diff --git a/modules/video_filter/deinterlace/deinterlace.h b/modules/video_filter/deinterlace/deinterlace.h
index ecc26e0d60..8584a072b2 100644
--- a/modules/video_filter/deinterlace/deinterlace.h
+++ b/modules/video_filter/deinterlace/deinterlace.h
@@ -45,20 +45,6 @@ struct vlc_object_t;
 #include "common.h"
 
 /*****************************************************************************
- * Local data
- *****************************************************************************/
-
-/** Available deinterlace modes. */
-static const char *const mode_list[] = {
-    "discard", "blend", "mean", "bob", "linear", "x",
-    "yadif", "yadif2x", "phosphor", "ivtc" };
-
-/** User labels for the available deinterlace modes. */
-static const char *const mode_list_text[] = {
-    N_("Discard"), N_("Blend"), N_("Mean"), N_("Bob"), N_("Linear"), "X",
-    "Yadif", "Yadif (2x)", N_("Phosphor"), N_("Film NTSC (IVTC)") };
-
-/*****************************************************************************
  * Data structures
  *****************************************************************************/
 
-- 
2.12.1



More information about the vlc-devel mailing list