codecs: h265decoder: Fix a typo of NumPocTotalCurr when process ref pic list.
authorHe Junyan <junyan.he@intel.com>
Fri, 16 Jul 2021 07:24:11 +0000 (15:24 +0800)
committerHe Junyan <junyan.he@intel.com>
Fri, 16 Jul 2021 15:05:18 +0000 (23:05 +0800)
commit4299596d16870b52ae4efc1e49154ec028c1fc7e
tree826c972809b6012ee507a25a1306d79679e62508
parent6a9f84a2dec6755bb9b53a50bec6d9611b8c0541
codecs: h265decoder: Fix a typo of NumPocTotalCurr when process ref pic list.

We should use the NumPocTotalCurr value stored in decoder, which is a calculated
valid value, rather than use the invalid value in the slice header. Most of the
time, the NumPocTotalCurr is 0 and make the tmp_refs a very short length, and
causes the decoder's wrong result.
By the way, the NumPocTotalCurr is not the correct name specified in H265 spec,
its name should be NumPicTotalCurr. We change it to the correct name.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2414>
gst-libs/gst/codecs/gsth265decoder.c
gst-libs/gst/codecs/gsth265decoder.h
sys/nvcodec/gstnvh265dec.c