Commit 494bd8df authored by Mark Thompson's avatar Mark Thompson

vaapi_encode: Let the reconstructed frame pool be sized dynamically

No supported encode driver requires the pool to be fixed-size, so just
remove this constraint.
parent 5fdcf85b
...@@ -1867,9 +1867,6 @@ static av_cold int vaapi_encode_create_recon_frames(AVCodecContext *avctx) ...@@ -1867,9 +1867,6 @@ static av_cold int vaapi_encode_create_recon_frames(AVCodecContext *avctx)
ctx->recon_frames->sw_format = recon_format; ctx->recon_frames->sw_format = recon_format;
ctx->recon_frames->width = ctx->surface_width; ctx->recon_frames->width = ctx->surface_width;
ctx->recon_frames->height = ctx->surface_height; ctx->recon_frames->height = ctx->surface_height;
// At most three IDR/I/P frames and two runs of B frames can be in
// flight at any one time.
ctx->recon_frames->initial_pool_size = 3 + 2 * ctx->b_per_p;
err = av_hwframe_ctx_init(ctx->recon_frames_ref); err = av_hwframe_ctx_init(ctx->recon_frames_ref);
if (err < 0) { if (err < 0) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment