mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
amcaudiodec: Set "is-adts" to 1 for ADTS AAC
Otherwise it fails to decode. https://bugzilla.gnome.org/show_bug.cgi?id=740101
This commit is contained in:
parent
5e3157098a
commit
3357ddb0e1
1 changed files with 15 additions and 0 deletions
|
@ -882,6 +882,21 @@ gst_amc_audio_dec_set_format (GstAudioDecoder * decoder, GstCaps * caps)
|
|||
return FALSE;
|
||||
}
|
||||
|
||||
if (gst_structure_has_name (s, "audio/mpeg")) {
|
||||
gint mpegversion;
|
||||
const gchar *stream_format;
|
||||
|
||||
if (!gst_structure_get_int (s, "mpegversion", &mpegversion))
|
||||
mpegversion = -1;
|
||||
stream_format = gst_structure_get_string (s, "stream-format");
|
||||
|
||||
if (mpegversion == 4 && g_strcmp0 (stream_format, "adts") == 0) {
|
||||
gst_amc_format_set_int (format, "is-adts", 1, &err);
|
||||
if (err)
|
||||
GST_ELEMENT_WARNING_FROM_ERROR (self, err);
|
||||
}
|
||||
}
|
||||
|
||||
/* FIXME: These buffers needs to be valid until the codec is stopped again */
|
||||
g_list_foreach (self->codec_datas, (GFunc) gst_buffer_unref, NULL);
|
||||
g_list_free (self->codec_datas);
|
||||
|
|
Loading…
Reference in a new issue