[FFmpeg-devel] [PATCH 12/17] vaapi_decode: Ignore the profile when not useful

Philip Langdale philipl at overt.org
Fri Nov 24 18:50:33 EET 2017


On Fri, 24 Nov 2017 00:51:29 +0000
Mark Thompson <sw at jkqxz.net> wrote:

> Enables VP8 decoding - the decoder places the the bitstream version
> in the profile field, which we want to ignore.
> ---
>  libavcodec/vaapi_decode.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/libavcodec/vaapi_decode.c b/libavcodec/vaapi_decode.c
> index d36ef906a2..572b3a40ac 100644
> --- a/libavcodec/vaapi_decode.c
> +++ b/libavcodec/vaapi_decode.c
> @@ -324,7 +324,8 @@ static int
> vaapi_decode_make_config(AVCodecContext *avctx, int profile_match = 0;
>          if (avctx->codec_id != vaapi_profile_map[i].codec_id)
>              continue;
> -        if (avctx->profile == vaapi_profile_map[i].codec_profile)
> +        if (avctx->profile == vaapi_profile_map[i].codec_profile ||
> +            vaapi_profile_map[i].codec_profile == FF_PROFILE_UNKNOWN)
>              profile_match = 1;
>          for (j = 0; j < profile_count; j++) {
>              if (vaapi_profile_map[i].va_profile == profile_list[j]) {

First 12 parts look good.

--phil


More information about the ffmpeg-devel mailing list