mirror of https://git.ffmpeg.org/ffmpeg.git
dxva2_hevc: don't use frames as reference if they are not marked as such
Similar to how a frame is considered for referencing for the RefPicList array. This will do the same for RefPicSetStCurrBefore, RefPicSetStCurrAfter and RefPicSetLtCurr. Fixes playback of http://www.gbbsoft.pl/!download/!/Film1.mp4 Ref. VLC issue https://code.videolan.org/videolan/vlc/-/issues/26738 Signed-off-by: Steve Lhomme <robux4@ycbcr.xyz>
This commit is contained in:
parent
8ae15b5655
commit
723065a346
|
@ -184,7 +184,7 @@ static void fill_picture_parameters(const AVCodecContext *avctx, AVDXVAContext *
|
|||
const HEVCFrame *frame = NULL; \
|
||||
while (!frame && j < rpl->nb_refs) \
|
||||
frame = rpl->ref[j++]; \
|
||||
if (frame) \
|
||||
if (frame && frame->flags & (HEVC_FRAME_FLAG_LONG_REF | HEVC_FRAME_FLAG_SHORT_REF)) \
|
||||
pp->ref_list[i] = get_refpic_index(pp, ff_dxva2_get_surface_index(avctx, ctx, frame->frame)); \
|
||||
else \
|
||||
pp->ref_list[i] = 0xff; \
|
||||
|
|
Loading…
Reference in New Issue