On Sat, Nov 02, 2013 at 05:32:20PM +0200, Jan Ekström wrote:
> --- a/libavcodec/aacdec.c
> +++ b/libavcodec/aacdec.c
> @@ -2772,6 +2774,14 @@ static int aac_decode_frame_int(AVCodecContext *avctx,
> void *data,
> if ((err = frame_configure_elements(avctx)) < 0)
> goto fail;
>
> + if (ac->oc[1].m4ac.object_type == AOT_AAC_MAIN) {
> + ac->avctx->profile = FF_PROFILE_AAC_MAIN;
> + } else if (ac->oc[1].m4ac.object_type == AOT_AAC_LTP) {
> + ac->avctx->profile = FF_PROFILE_AAC_LTP;
> + } else {
> + ac->avctx->profile = FF_PROFILE_AAC_LOW;
> + }
This would IMO be cleaner as a switch/case block.
Diego
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel