vaapi_encode: Remove common priv_data and options fields

The codec-specific context now contains both the common context and the
codec-specific options directly.
This commit is contained in:
Mark Thompson
2018-08-23 00:44:40 +01:00
parent 1616106f11
commit c5b4ad247b
8 changed files with 0 additions and 33 deletions

View File

@@ -1372,17 +1372,9 @@ av_cold int ff_vaapi_encode_init(AVCodecContext *avctx)
return AVERROR(EINVAL);
}
ctx->codec_options = ctx->codec_options_data;
ctx->va_config = VA_INVALID_ID;
ctx->va_context = VA_INVALID_ID;
ctx->priv_data = av_mallocz(ctx->codec->priv_data_size);
if (!ctx->priv_data) {
err = AVERROR(ENOMEM);
goto fail;
}
ctx->input_frames_ref = av_buffer_ref(avctx->hw_frames_ctx);
if (!ctx->input_frames_ref) {
err = AVERROR(ENOMEM);
@@ -1583,7 +1575,5 @@ av_cold int ff_vaapi_encode_close(AVCodecContext *avctx)
av_buffer_unref(&ctx->input_frames_ref);
av_buffer_unref(&ctx->device_ref);
av_freep(&ctx->priv_data);
return 0;
}