gst-plugins-base: alsasink: fix high sample rates being rejected
Vincent Penquerc'h
vincent at kemper.freedesktop.org
Mon Jan 16 03:46:56 PST 2012
Module: gst-plugins-base
Branch: master
Commit: 8d29fe88345621032b277c0a21afdf94bb8e09fd
URL: http://cgit.freedesktop.org/gstreamer/gst-plugins-base/commit/?id=8d29fe88345621032b277c0a21afdf94bb8e09fd
Author: Vincent Penquerc'h <vincent.penquerch at collabora.co.uk>
Date: Mon Jan 16 11:43:25 2012 +0000
alsasink: fix high sample rates being rejected
An ALSA sink may select a different rate (as we use the _set_rate_near
API, which is not guaranteed to set the exact target rate).
The rest of the code seems to already handle this well, as output
from a 88200 Hz file seems to have the correct pitch when selecting
a 96 kHz rate.
---
ext/alsa/gstalsasink.c | 9 ---------
1 files changed, 0 insertions(+), 9 deletions(-)
diff --git a/ext/alsa/gstalsasink.c b/ext/alsa/gstalsasink.c
index 20de864..7a5604a 100644
--- a/ext/alsa/gstalsasink.c
+++ b/ext/alsa/gstalsasink.c
@@ -376,8 +376,6 @@ retry:
rrate = alsa->rate;
CHECK (snd_pcm_hw_params_set_rate_near (alsa->handle, params, &rrate, NULL),
no_rate);
- if (rrate != alsa->rate)
- goto rate_match;
#ifndef GST_DISABLE_GST_DEBUG
/* get and dump some limits */
@@ -507,13 +505,6 @@ no_rate:
alsa->rate, snd_strerror (err)));
return err;
}
-rate_match:
- {
- GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
- ("Rate doesn't match (requested %iHz, get %iHz)", alsa->rate, rrate));
- snd_pcm_hw_params_free (params);
- return -EINVAL;
- }
buffer_size:
{
GST_ELEMENT_ERROR (alsa, RESOURCE, SETTINGS, (NULL),
More information about the gstreamer-commits
mailing list