summaryrefslogtreecommitdiff
path: root/libavcodec/dxva2_av1.c
diff options
context:
space:
mode:
authorTong Wu <tong1.wu@intel.com>2021-10-12 16:24:00 +0800
committerJames Almer <jamrial@gmail.com>2021-10-16 19:00:44 -0300
commit4e7a7d75e3c21a6af03c4cd52ffc50270664e58a (patch)
tree0e4fc10296e0eae15df9129ed0db74527eb344c5 /libavcodec/dxva2_av1.c
parent0d0ea70e7bdd85def85d526480d728740a371744 (diff)
downloadffmpeg-4e7a7d75e3c21a6af03c4cd52ffc50270664e58a.tar.gz
avcodec/dxva2_av1: fix global motion params
Defined in spec 5.9.24/5.9.25. Since function void global_motion_params(AV1DecContext *s) already updates gm type/params, the wminvalid parameter only need to get the value from cur_frame.gm_invalid. Signed-off-by: Tong Wu <tong1.wu@intel.com>
Diffstat (limited to 'libavcodec/dxva2_av1.c')
-rw-r--r--libavcodec/dxva2_av1.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/dxva2_av1.c b/libavcodec/dxva2_av1.c
index c30b57799c..8a912bf6c1 100644
--- a/libavcodec/dxva2_av1.c
+++ b/libavcodec/dxva2_av1.c
@@ -139,7 +139,7 @@ static int fill_picture_parameters(const AVCodecContext *avctx, AVDXVAContext *c
pp->frame_refs[i].Index = ref_frame->buf[0] ? ref_idx : 0xFF;
/* Global Motion */
- pp->frame_refs[i].wminvalid = (h->cur_frame.gm_type[AV1_REF_FRAME_LAST + i] == AV1_WARP_MODEL_IDENTITY);
+ pp->frame_refs[i].wminvalid = h->cur_frame.gm_invalid[AV1_REF_FRAME_LAST + i];
pp->frame_refs[i].wmtype = h->cur_frame.gm_type[AV1_REF_FRAME_LAST + i];
for (j = 0; j < 6; ++j) {
pp->frame_refs[i].wmmat[j] = h->cur_frame.gm_params[AV1_REF_FRAME_LAST + i][j];