]> git.baikalelectronics.ru Git - kernel.git/commit
media: hantro: HEVC: Fix output frame chroma offset
authorBenjamin Gaignard <benjamin.gaignard@collabora.com>
Thu, 14 Apr 2022 15:50:59 +0000 (17:50 +0200)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Fri, 13 May 2022 09:02:22 +0000 (11:02 +0200)
commitf2f8c9be45f0839c79d2fffd8b9320e19c52d760
treefb52345873aa2d6837ebf5a603a77350f75bbbc2
parentf497f696d2c9a5a6dc7d2af972af13720bbbdf1d
media: hantro: HEVC: Fix output frame chroma offset

Hantro decoder doesn't take care of the requested and aligned size
of the capture buffer.
Stop using the bitstream width/height and use capture frame size
stored in the context to get the correct values.

hantro_hevc_chroma_offset() and hantro_hevc_motion_vectors_offset()
are only used in hantro_g2_hevc_dec.c so take the opportunity
to move them here.

fluster HEVC score goes up from 77 to 85 successful tests (over 147)
with this patch.

Signed-off-by: Benjamin Gaignard <benjamin.gaignard@collabora.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
drivers/staging/media/hantro/hantro_g2_hevc_dec.c
drivers/staging/media/hantro/hantro_hevc.c
drivers/staging/media/hantro/hantro_hw.h