From: Rafaël Carré Date: Fri, 29 Jan 2010 13:34:30 +0000 (+0100) Subject: avcodec decoder: export profile/level at open X-Git-Tag: 1.1.0-ff~707 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;ds=sidebyside;h=3dd2478ce13bb16c5f3f55518b057f21d354ef32;p=vlc avcodec decoder: export profile/level at open --- diff --git a/modules/codec/avcodec/avcodec.c b/modules/codec/avcodec/avcodec.c index 147d09dd7a..afd173e1df 100644 --- a/modules/codec/avcodec/avcodec.c +++ b/modules/codec/avcodec/avcodec.c @@ -321,7 +321,14 @@ static int OpenDecoder( vlc_object_t *p_this ) i_result = VLC_EGENERIC; } - if( i_result == VLC_SUCCESS ) p_dec->p_sys->i_cat = i_cat; + if( i_result == VLC_SUCCESS ) + { + p_dec->p_sys->i_cat = i_cat; + if( p_context->profile != FF_PROFILE_UNKNOWN) + p_dec->fmt_in.i_profile = p_context->profile; + if( p_context->level != FF_LEVEL_UNKNOWN) + p_dec->fmt_in.i_level = p_context->level; + } return i_result; }