frontends/va: get av1 encoding ref frame infos for L0.
Reference frame list is formed by each of the provided
recon_frame, while the assumption here is to use the API
provided by VAAPI interface, when a frame is marked as
"long term reference" by
av1->picture_flags.bits.long_term_reference
Its recon_frame will be kept in DPB marked by its
recon_frame as signature. When a future input requests
refering to it, it can go this way:
1. set av1->ref_frame_ctrl_l0.field.search_idx2 to indicate
which ref_frame_idx slot will be used.
x = av1->ref_frame_ctrl_l0.field.search_idx2;
2. n = av1->ref_frame_idx[x-1];
av1->reference_frames[n] as the signature to compare with.
if av1->reference_frames[n] is pointing to the
same video buffer (signature) as the one marked as
"long term reference". Then the new input is refering to
it only.
3. in SVC case, long terms are used for temproal_id 0 only,
because using long term means potentially scene change
could happen.
4. the "long term reference" recon_frame should be kept,
instead of being reused until it is no longer needed to
avoid signature duplication.
Reviewed-by: Leo Liu <leo.liu@amd.com>
Signed-off-by: Ruijing Dong <ruijing.dong@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27771>
1 file changed