fdkaac: fix error with AOT_MP2_AAC_LC removed from libfdkaac API

AOT_MP2_AAC_LC is a "pseudo AOT" which got removed after 0.1.4,
and maps to AOT_AAC_LC.

Remove mpegversion 2 from th caps to match.

https://bugzilla.gnome.org/show_bug.cgi?id=772067
This commit is contained in:
Vincent Penquerc'h 2016-09-27 09:08:51 +01:00
parent 80f3bf7ac2
commit a828b12ca8

View file

@ -127,7 +127,7 @@ static GstStaticPadTemplate src_template = GST_STATIC_PAD_TEMPLATE ("src",
GST_PAD_SRC,
GST_PAD_ALWAYS,
GST_STATIC_CAPS ("audio/mpeg, "
"mpegversion = (int) {2, 4}, "
"mpegversion = (int) 4, "
"rate = (int) { " SAMPLE_RATES " }, "
"channels = (int) {1, 2, 3, 4, 5, 6, 8}, "
"stream-format = (string) { adts, adif, raw }, "
@ -296,11 +296,7 @@ gst_fdkaacenc_set_format (GstAudioEncoder * enc, GstAudioInfo * info)
return FALSE;
}
if (mpegversion == 4) {
aot = AOT_AAC_LC;
} else {
aot = AOT_MP2_AAC_LC;
}
aot = AOT_AAC_LC;
if ((err = aacEncoder_SetParam (self->enc, AACENC_AOT, aot)) != AACENC_OK) {
GST_ERROR_OBJECT (self, "Unable to set AOT %d: %d\n", aot, err);