From bb229c02a35f1f01e00fadd8b1af08d6f16dc7ab Mon Sep 17 00:00:00 2001 From: Hui Zhang Date: Wed, 6 May 2020 19:57:30 +0800 Subject: [PATCH] vmh264: video playback stutter issue [1/1] PD#SWPL-25348 Problem: this stream has wrong duration info inside vui. it cause video display not smooth Solution: add a limit when variable frame rate and duraion is adnormal. force set duration to a normal Verify: U215 Signed-off-by: Hui Zhang Change-Id: I164e6d59f622f0cc5247c2d929f7e2693a16f6bd --- drivers/frame_provider/decoder/h264_multi/vmh264.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/frame_provider/decoder/h264_multi/vmh264.c b/drivers/frame_provider/decoder/h264_multi/vmh264.c index 99e51cb..459bd48 100644 --- a/drivers/frame_provider/decoder/h264_multi/vmh264.c +++ b/drivers/frame_provider/decoder/h264_multi/vmh264.c @@ -5086,6 +5086,10 @@ static void vui_config(struct vdec_h264_hw_s *hw) FIX_FRAME_RATE_OFF; hw->pts_duration = 0; hw->frame_dur = frame_dur_es; + if (!hw->fixed_frame_rate_flag && (p_H264_Dpb->mSPS.profile_idc != BASELINE)) { + if (frame_dur_es == 7680) + hw->frame_dur = frame_dur_es /2; + } vdec_schedule_work(&hw->notify_work); dpb_print(DECODE_ID(hw), PRINT_FLAG_DEC_DETAIL, -- 2.20.1