On 06/09/17 15:27, wm4 wrote:
> On Tue,  5 Sep 2017 23:59:22 +0100
> Mark Thompson <[email protected]> wrote:
> 
>> ---
>>  libavcodec/vaapi_decode.c | 8 ++++++++
>>  1 file changed, 8 insertions(+)
>>
>> diff --git a/libavcodec/vaapi_decode.c b/libavcodec/vaapi_decode.c
>> index a63c4c62e..847db1a42 100644
>> --- a/libavcodec/vaapi_decode.c
>> +++ b/libavcodec/vaapi_decode.c
>> @@ -21,6 +21,7 @@
>>  #include "libavutil/pixdesc.h"
>>  
>>  #include "avcodec.h"
>> +#include "hwaccel.h"
>>  #include "internal.h"
>>  #include "vaapi_decode.h"
>>  
>> @@ -562,6 +563,13 @@ int ff_vaapi_decode_init(AVCodecContext *avctx)
>>          ctx->frames->sw_format         = ctx->surface_format;
>>          ctx->frames->initial_pool_size = ctx->surface_count;
>>  
>> +        err = ff_init_hw_frames(avctx);
>> +        if (err < 0) {
>> +            av_log(avctx, AV_LOG_ERROR, "User initialisation of internal "
>> +                   "frames context failed: %d.\n", err);
>> +            goto fail;
>> +        }
>> +
>>          err = av_hwframe_ctx_init(avctx->hw_frames_ctx);
>>          if (err < 0) {
>>              av_log(avctx, AV_LOG_ERROR, "Failed to initialise internal "
> 
> The dxva2 change doesn't have this error message. Should the shared
> code print it?

It's trying to match the error messages present (or not) in the existing code.  
ff_init_hw_frames() could print it I guess?  If you think that's better then I 
don't mind.
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to