Commit 7b026e4b authored by Thibault Saunier's avatar Thibault Saunier 🌵

matroskademux: Always set the channel mask for PCM streams

Just use the gst_audio_channel_get_fallback_mask function for now as
the specification is too complicated and nobody implements it.
parent 51f94288
...@@ -5517,7 +5517,9 @@ gst_matroska_demux_audio_caps (GstMatroskaTrackAudioContext * ...@@ -5517,7 +5517,9 @@ gst_matroska_demux_audio_caps (GstMatroskaTrackAudioContext *
/* FIXME: Channel mask and reordering */ /* FIXME: Channel mask and reordering */
caps = gst_caps_new_simple ("audio/x-raw", caps = gst_caps_new_simple ("audio/x-raw",
"format", G_TYPE_STRING, gst_audio_format_to_string (format), "format", G_TYPE_STRING, gst_audio_format_to_string (format),
"layout", G_TYPE_STRING, "interleaved", NULL); "layout", G_TYPE_STRING, "interleaved",
"channel-mask", GST_TYPE_BITMASK,
gst_audio_channel_get_fallback_mask (audiocontext->channels), NULL);
*codec_name = g_strdup_printf ("Raw %d-bit PCM audio", *codec_name = g_strdup_printf ("Raw %d-bit PCM audio",
audiocontext->bitdepth); audiocontext->bitdepth);
...@@ -5532,7 +5534,9 @@ gst_matroska_demux_audio_caps (GstMatroskaTrackAudioContext * ...@@ -5532,7 +5534,9 @@ gst_matroska_demux_audio_caps (GstMatroskaTrackAudioContext *
/* FIXME: Channel mask and reordering */ /* FIXME: Channel mask and reordering */
caps = gst_caps_new_simple ("audio/x-raw", caps = gst_caps_new_simple ("audio/x-raw",
"format", G_TYPE_STRING, format, "format", G_TYPE_STRING, format,
"layout", G_TYPE_STRING, "interleaved", NULL); "layout", G_TYPE_STRING, "interleaved",
"channel-mask", GST_TYPE_BITMASK,
gst_audio_channel_get_fallback_mask (audiocontext->channels), NULL);
*codec_name = g_strdup_printf ("Raw %d-bit floating-point audio", *codec_name = g_strdup_printf ("Raw %d-bit floating-point audio",
audiocontext->bitdepth); audiocontext->bitdepth);
context->alignment = audiocontext->bitdepth / 8; context->alignment = audiocontext->bitdepth / 8;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment