From 0c1ff82bc89c8973d8cb83ab79ac2f1668f7c67c Mon Sep 17 00:00:00 2001 From: Sil Vilerino Date: Sun, 19 Nov 2023 10:59:53 -0500 Subject: [PATCH] frontend/va: Add h264 encode ip_period param Reviewed-by: Boyuan Zhang Reviewed-by: Ruijing Dong Reviewed-by: Jesse Natalie Part-of: --- src/gallium/frontends/va/picture_h264_enc.c | 1 + src/gallium/include/pipe/p_video_state.h | 1 + 2 files changed, 2 insertions(+) diff --git a/src/gallium/frontends/va/picture_h264_enc.c b/src/gallium/frontends/va/picture_h264_enc.c index 94a651f8b48..70769281d26 100644 --- a/src/gallium/frontends/va/picture_h264_enc.c +++ b/src/gallium/frontends/va/picture_h264_enc.c @@ -207,6 +207,7 @@ vlVaHandleVAEncSequenceParameterBufferTypeH264(vlVaDriver *drv, vlVaContext *con context->desc.h264enc.intra_refresh.need_sequence_header = 0; } + context->desc.h264enc.ip_period = h264->ip_period; context->desc.h264enc.intra_idr_period = h264->intra_idr_period != 0 ? h264->intra_idr_period : PIPE_DEFAULT_INTRA_IDR_PERIOD; context->gop_coeff = ((1024 + context->desc.h264enc.intra_idr_period - 1) / diff --git a/src/gallium/include/pipe/p_video_state.h b/src/gallium/include/pipe/p_video_state.h index 82752bb23e6..67f41c0a3df 100644 --- a/src/gallium/include/pipe/p_video_state.h +++ b/src/gallium/include/pipe/p_video_state.h @@ -602,6 +602,7 @@ struct pipe_h264_enc_picture_desc struct pipe_h264_enc_dbk_param dbk; unsigned intra_idr_period; + unsigned ip_period; unsigned quant_i_frames; unsigned quant_p_frames;