[FFmpeg-devel] [PATCH v3 5/6] lavc/vaapi_encode: Separate reference frame into previous/future list

Mark Thompson sw at jkqxz.net
Mon Aug 7 23:28:14 EEST 2023


On 03/08/2023 07:01, fei.w.wang-at-intel.com at ffmpeg.org wrote:
> From: Fei Wang <fei.w.wang at intel.com>
> 
> To support more reference frames from different directions.
> 
> Signed-off-by: Fei Wang <fei.w.wang at intel.com>
> ---
>   libavcodec/vaapi_encode.c       | 112 +++++++++++++++++++++++++-------
>   libavcodec/vaapi_encode.h       |  15 +++--
>   libavcodec/vaapi_encode_h264.c  |  94 +++++++++++++--------------
>   libavcodec/vaapi_encode_h265.c  |  76 +++++++++++++---------
>   libavcodec/vaapi_encode_mpeg2.c |   6 +-
>   libavcodec/vaapi_encode_vp8.c   |   6 +-
>   libavcodec/vaapi_encode_vp9.c   |  26 ++++----
>   7 files changed, 208 insertions(+), 127 deletions(-)

But why?

VAAPI at the top level doesn't care which direction the reference is in, it only cares about the set of reference pictures in the DPB and used as reference.

It's up to the per-codec code to decide how it needs to structure that, like how it builds L0/L1 for H.264 but for VP9 it's just a flat set.

Thanks,

- Mark


More information about the ffmpeg-devel mailing list