summaryrefslogtreecommitdiffstats
path: root/sys/oss
diff options
context:
space:
mode:
authorDavid Schleef <ds@schleef.org>2004-07-03 02:54:53 +0000
committerDavid Schleef <ds@schleef.org>2004-07-03 02:54:53 +0000
commit13dd7366cd958cf9a9177f7e08848b0b9a77ee2d (patch)
tree8a975ad7f2b87db29fb7b5efc3bd01837aa3e04f /sys/oss
parentef5f5ffb3ab771eefa05544034ba218cd5975f59 (diff)
gst/wavenc/gstwavenc.c: Switch to GST_WRITE_UINT32_LE macros (bug #144624)
Original commit message from CVS: * gst/wavenc/gstwavenc.c: (gst_wavenc_setup), (gst_wavenc_stop_file): Switch to GST_WRITE_UINT32_LE macros (bug #144624) * sys/oss/gstosselement.c: (gst_osselement_probe_caps), (gst_osselement_rate_probe_check): Add another workaround for buggy drivers (bug #145336)
Diffstat (limited to 'sys/oss')
-rw-r--r--sys/oss/gstosselement.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/sys/oss/gstosselement.c b/sys/oss/gstosselement.c
index 0e57d47f..5d17dfe2 100644
--- a/sys/oss/gstosselement.c
+++ b/sys/oss/gstosselement.c
@@ -1126,7 +1126,7 @@ gst_osselement_probe_caps (GstOssElement * oss)
if (gst_caps_is_empty (caps)) {
GST_ELEMENT_ERROR (oss, RESOURCE, SETTINGS,
- (_("Your oss device could not be probed correctly")), (NULL));
+ (_("Your OSS device could not be probed correctly")), (NULL));
return;
}
GST_DEBUG ("probed caps: %" GST_PTR_FORMAT, caps);
@@ -1218,6 +1218,14 @@ gst_osselement_rate_probe_check (GstOssProbe * probe)
}
n_checks++;
if (probe->min == -1 || probe->max == -1) {
+ /* This is a workaround for drivers that return -EINVAL (or another
+ * error) for rates outside of [8000,48000]. If this fails, the
+ * driver is seriously buggy, and probably doesn't work with other
+ * media libraries/apps. */
+ probe->min = gst_osselement_rate_check_rate (probe, 8000);
+ probe->max = gst_osselement_rate_check_rate (probe, 48000);
+ }
+ if (probe->min == -1 || probe->max == -1) {
GST_DEBUG ("unexpected check_rate error");
return FALSE;
}