When iterating the formats table, we can just pass the whole
entry to our helper function, which avoids iterating the table
again to find the entry structure from the passed format id.
Also accept formats that are not natively supported by the
hardware, OSS4 can convert them internally. List the native
formats first in the caps though, to express our preference
for the native formats. We need this in order to support the
case properly where the audio hardware supports only e.g.
little endian PCM, but the host is big endian, since many
audio elements only support native endianness and make the
reasonable assumption that any audiosink will be able to
handle audio in native endianness.
Based on patch by Jerry Tan <jerry.tan@sun.com>
Fixes#614317.
Code cleanups, general improvements, support for the
new mixer flags in latest gst-plugins-base.
Fixes: #584252
Patch By: Brian Cameron <brian.cameron@sun.com>
Patch By: Garrett D'Amore <garrett.damore@sun.com>
Original commit message from CVS:
Patch by: Frederic Crozat <fcrozat@mandriva.org>
* ext/sndfile/gstsf.c: (plugin_init):
* sys/dvb/gstdvbsrc.c: (gst_dvbsrc_plugin_init):
* sys/oss4/oss4-audio.c: (plugin_init):
Make sure gettext returns translations in UTF-8 encoding rather
than in the current locale encoding (#546822).