mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
pulse: relax mulaw and alaw format checks
The audio library considers them as encoded formats and does not fill in the sample width. The audio ringbuffers identifies the format as alaw/mulaw and that is always 8 bits.
This commit is contained in:
parent
3111161e8a
commit
8248ff8232
1 changed files with 2 additions and 4 deletions
|
@ -146,12 +146,10 @@ gst_pulse_fill_format_info (GstAudioRingBufferSpec * spec, pa_format_info ** f,
|
|||
|
||||
format = pa_format_info_new ();
|
||||
|
||||
if (spec->type == GST_AUDIO_RING_BUFFER_FORMAT_TYPE_MU_LAW
|
||||
&& GST_AUDIO_INFO_WIDTH (ainfo) == 8) {
|
||||
if (spec->type == GST_AUDIO_RING_BUFFER_FORMAT_TYPE_MU_LAW) {
|
||||
format->encoding = PA_ENCODING_PCM;
|
||||
sf = PA_SAMPLE_ULAW;
|
||||
} else if (spec->type == GST_AUDIO_RING_BUFFER_FORMAT_TYPE_A_LAW
|
||||
&& GST_AUDIO_INFO_WIDTH (ainfo) == 8) {
|
||||
} else if (spec->type == GST_AUDIO_RING_BUFFER_FORMAT_TYPE_A_LAW) {
|
||||
format->encoding = PA_ENCODING_PCM;
|
||||
sf = PA_SAMPLE_ALAW;
|
||||
} else if (spec->type == GST_AUDIO_RING_BUFFER_FORMAT_TYPE_RAW) {
|
||||
|
|
Loading…
Reference in a new issue