[MPlayer-cvslog] r37171 - trunk/gui/interface.c

ib subversion at mplayerhq.hu
Thu Apr 24 15:17:00 CEST 2014


Author: ib
Date: Thu Apr 24 15:17:00 2014
New Revision: 37171

Log:
Rewrite add_vf().

Add a parameter in order to pass options to a video filter to be added.

Modified:
   trunk/gui/interface.c

Modified: trunk/gui/interface.c
==============================================================================
--- trunk/gui/interface.c	Thu Apr 24 15:08:38 2014	(r37170)
+++ trunk/gui/interface.c	Thu Apr 24 15:17:00 2014	(r37171)
@@ -275,7 +275,7 @@ void guiDone(void)
     mp_msg(MSGT_GPLAYER, MSGL_V, "GUI done.\n");
 }
 
-static void add_vf(const char *vf)
+static void add_vf(const char *vf, const char *const *argvf)
 {
     if (vf_settings) {
         int i = 0;
@@ -295,7 +295,7 @@ static void add_vf(const char *vf)
 
             vf_settings = settings;
             vf_settings[i].name     = strdup(vf);
-            vf_settings[i].attribs  = NULL;
+            vf_settings[i].attribs  = listDup(argvf);
             memset(&vf_settings[i + 1], 0, sizeof(m_obj_settings_t));
         }
     } else {
@@ -305,7 +305,7 @@ static void add_vf(const char *vf)
             return;
 
         vf_settings[0].name    = strdup(vf);
-        vf_settings[0].attribs = NULL;
+        vf_settings[0].attribs = listDup(argvf);
     }
 
     mp_msg(MSGT_GPLAYER, MSGL_INFO, MSGTR_GUI_MSG_AddingVideoFilter, vf);
@@ -505,10 +505,10 @@ int gui(int what, void *data)
         if (video_driver_list && !gstrcmp(video_driver_list[0], "dxr3"))
             if (guiInfo.StreamType != STREAMTYPE_DVD && guiInfo.StreamType != STREAMTYPE_VCD)
                 if (gtkVfLAVC)
-                    add_vf("lavc");
+                    add_vf("lavc", NULL);
 
         if (gtkVfPP)
-            add_vf("pp");
+            add_vf("pp", NULL);
 
         /* audio opts */
 


More information about the MPlayer-cvslog mailing list