alsa: Allow to use 8 bit samples with ALSA
authorThomas Roos <thomas.roos@industronic.de>
Wed, 21 Jan 2015 07:33:57 +0000 (08:33 +0100)
committerSebastian Dröge <sebastian@centricular.com>
Wed, 21 Jan 2015 08:42:35 +0000 (09:42 +0100)
8 bit samples have no (0) as endianness, not the native endianness.

https://bugzilla.gnome.org/show_bug.cgi?id=739446

ext/alsa/gstalsa.c

index d702a23..1c6d1e7 100644 (file)
@@ -149,7 +149,8 @@ format_supported (const GValue * format_val, snd_pcm_format_mask_t * mask,
 
   finfo = gst_audio_format_get_info (format);
 
-  if (GST_AUDIO_FORMAT_INFO_ENDIANNESS (finfo) != endianness)
+  if (GST_AUDIO_FORMAT_INFO_ENDIANNESS (finfo) != endianness
+      && GST_AUDIO_FORMAT_INFO_ENDIANNESS (finfo) != 0)
     return FALSE;
 
   pcm_format = gst_alsa_get_pcm_format (format);