GNOME Bugzilla – Bug 571106
Add new GStreamer flags to gvc
Last modified: 2009-05-22 19:08:37 UTC
Note GStreamer enhancement request bug #570832 to add some new flags to the base GStreamer mixer class. This makes it possible to do some new things with gvc. Namely: 1) sliders can specify not to show the MUTE or RECORD buttons if they are not meaningful for a specific slider. 2) To group switches and options on the Recording or Playback tabs if the switch or slider makes more sense on that tab. This is managed by adding a table (flagbuttonbox) underneath the sliders where the switches and options will be displayed. So, if the plugin specifies that the switch or option should be displayed on the INPUT or OUTPUT tabs, it will do so. 3) Whether to ignore the built-in whitelist or not. The code is reasonably backwards compatible so that even if you use a plugin with the flags with a version of gvc which doesn't support this patch it will still work, but will the user-interface won't be exactly right. For example, a MUTE or RECORD button would be displayed where it isn't meaningful, etc. Also, note that this patch depends on the fix in bug #571068 which makes the preferences.c sort_by_page_num function a bit smarter and more efficient. This patch will only apply on top of that patch. You could probably make this work without applying that patch, but the code in preferences.c would need to be reworked a bit differently to pass the mixer flag (now needed by get_page_num) into the function. Perhaps via userdata. Note Garrett D'Amore <garrett.damore@sun.com> wrote this patch.
Created attachment 128338 [details] [review] patch adding feature
Created attachment 128339 [details] picture showing changes Here is a picture showing gvc with this feature and making use of an OSSv4 plugin making use of the new flags.
Created attachment 128948 [details] [review] picture showing Options tab This picture shows gvc with some options relating to jack retasking on a Solaris system with a new audio framework.
Created attachment 128949 [details] picture showing Switches tab This shows a simple switches tab for a device with only one switch, which is the enabling of the keyboard beep.
Note bug #570832 was just approved today, so that now the GStreamer flags are supported in gst-plugins-base. Can this patch (and the patch for bug #571068) go upstream so that g-v-c can also support these new flags? Thanks!
Created attachment 129984 [details] [review] updated patch This updated patch resolves a minor issue with the vertical separators showing up incorrectly. This changes the cb_gconf function in element.c so that it doesn't create vertical separators when "n <2 && track->num_channels ==0". In other words, when an object is added to the flagbuttonbox, and is not a slider, it shows up in the area below the sliders, so no vertical separator should be shown in this case. With this change, the GUI looks better. I also merged the change from bug #571080 into this patch. I was previously confused and thought that this was unrelated to this patch. But obviously all the code that checks for "num_channels == 0" is trying to ensure that any objects which show up in the flagbuttonbox are handled differently.
Created attachment 130077 [details] [review] updated patch This patch now applies against SVN head. Probably best to not commit this until a new release of gst-plugins-base is released that actually contains the new flag.
And you'll need to update configure.ac to show the required version as well.
Created attachment 135198 [details] [review] updated patch This patch adds the change to configure.ac, as requested.
I committed the latest patch to gnome-media GIT master, so marking this as Fixed.