commit 83b4c6dd19a5df7e67f0920ab2455e518d2a2c7b
Author: Bastien Nocera <hadess(a)fedoraproject.org>
Date: Fri Apr 18 13:14:31 2008 +0000
- Add patch to avoid sync problems in the ALSA sink when a specific track
has both playback and record flags
....19-alsasink-mixed-record-playback-tracks.patch | 60 ++++++++++++++++++++++
gstreamer-plugins-base.spec | 9 +++-
2 files changed, 68 insertions(+), 1 deletion(-)
---
diff --git a/gstreamer-0.10.19-alsasink-mixed-record-playback-tracks.patch
b/gstreamer-0.10.19-alsasink-mixed-record-playback-tracks.patch
new file mode 100644
index 0000000..c663736
--- /dev/null
+++ b/gstreamer-0.10.19-alsasink-mixed-record-playback-tracks.patch
@@ -0,0 +1,60 @@
+diff -Nur -x '*.orig' -x '*~'
gst-plugins-base0.10-0.10.18/ext/alsa/gstalsamixertrack.c
gst-plugins-base0.10-0.10.18.new/ext/alsa/gstalsamixertrack.c
+--- gst-plugins-base0.10-0.10.18/ext/alsa/gstalsamixertrack.c 2008-03-03
22:29:49.000000000 +0000
++++ gst-plugins-base0.10-0.10.18.new/ext/alsa/gstalsamixertrack.c 2008-04-10
15:15:15.000000000 +0100
+@@ -75,28 +75,40 @@
+ alsa_track->alsa_flags = 0;
+ alsa_track->capture_group = -1;
+
++ /* common flags */
+ if (snd_mixer_selem_has_common_volume (alsa_track->element))
+ alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_VOLUME;
+
+- if (snd_mixer_selem_has_playback_volume (alsa_track->element))
+- alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_PVOLUME;
+-
+- if (snd_mixer_selem_has_capture_volume (alsa_track->element))
+- alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_CVOLUME;
+-
+ if (snd_mixer_selem_has_common_switch (alsa_track->element))
+ alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_SWITCH;
+
+- if (snd_mixer_selem_has_playback_switch (alsa_track->element))
+- alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_PSWITCH;
+-
+- if (snd_mixer_selem_has_capture_switch (alsa_track->element)) {
+- alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_CSWITCH;
+-
+- if (snd_mixer_selem_has_capture_switch_exclusive (alsa_track->element)) {
+- alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_CSWITCH_EXCL;
+- alsa_track->capture_group =
+- snd_mixer_selem_get_capture_group (alsa_track->element);
++ /* Since we create two separate mixer track objects for alsa elements that
++ * support both playback and capture, we're going to 'hide' the alsa
flags
++ * that don't pertain to this mixer track from alsa_flags, otherwise
++ * gst_alsa_mixer_track_update() is going to do things we don't want */
++
++ /* playback flags */
++ if ((GST_MIXER_TRACK (alsa_track)->flags & GST_MIXER_TRACK_OUTPUT)) {
++ if (snd_mixer_selem_has_playback_volume (alsa_track->element))
++ alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_PVOLUME;
++
++ if (snd_mixer_selem_has_playback_switch (alsa_track->element))
++ alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_PSWITCH;
++ }
++
++ /* capture flags */
++ if ((GST_MIXER_TRACK (alsa_track)->flags & GST_MIXER_TRACK_INPUT)) {
++ if (snd_mixer_selem_has_capture_volume (alsa_track->element))
++ alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_CVOLUME;
++
++ if (snd_mixer_selem_has_capture_switch (alsa_track->element)) {
++ alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_CSWITCH;
++
++ if (snd_mixer_selem_has_capture_switch_exclusive (alsa_track->element)) {
++ alsa_track->alsa_flags |= GST_ALSA_MIXER_TRACK_CSWITCH_EXCL;
++ alsa_track->capture_group =
++ snd_mixer_selem_get_capture_group (alsa_track->element);
++ }
+ }
+ }
+
diff --git a/gstreamer-plugins-base.spec b/gstreamer-plugins-base.spec
index 59cc22f..59e053a 100644
--- a/gstreamer-plugins-base.spec
+++ b/gstreamer-plugins-base.spec
@@ -5,7 +5,7 @@
Name: %{gstreamer}-plugins-base
Version: 0.10.19
-Release: 1%{?dist}
+Release: 2%{?dist}
Summary: GStreamer streaming media framework base plug-ins
Group: Applications/Multimedia
@@ -15,6 +15,8 @@
Source:
http://gstreamer.freedesktop.org/src/gst-plugins-base/gst-plugins-base-
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Patch0: gstpb-0.10.15-cd-speed.patch
+#
http://bugzilla.gnome.org/show_bug.cgi?id=518082
+Patch1: gstreamer-0.10.19-alsasink-mixed-record-playback-tracks.patch
Requires: %{gstreamer} >= %{_gst}
Requires: liboil >= 0.3.12-9
@@ -52,6 +54,7 @@ This package contains a set of well-maintained base plug-ins.
%prep
%setup -q -n gst-plugins-base-%{version}
%patch0 -p1 -b .cd-speed
+%patch1 -p1 -b .alsasink
%build
%configure \
@@ -246,6 +249,10 @@ GStreamer Base Plugins library development and header files.
%doc %{_datadir}/gtk-doc/html/gst-plugins-base-plugins-%{majorminor}
%changelog
+* Fri Apr 18 2008 - Bastien Nocera <bnocera(a)redhat.com> - 0.10.19-2
+- Add patch to avoid sync problems in the ALSA sink when a specific
+ track has both playback and record flags
+
* Fri Apr 04 2008 - Bastien Nocera <bnocera(a)redhat.com> - 0.10.19-1
- Update to 0.10.19