From b90b075c959e9a3a4a7b9f52b2fc07b74a0968f0 Mon Sep 17 00:00:00 2001 From: "shihong.zheng" Date: Sat, 4 Jul 2020 21:40:12 +0800 Subject: [PATCH] av1: add buffers for q mainline. [1/1] PD#SWPL-28916 Problem: SWPL-28916 some av1 play freeze SWPL-28911 duration error caused frames output too fast. Solution: android q need 2 more buffers for display. set calc dur wide range limit. Verify: sc2 Change-Id: I34b4371c1271e1f49e720d1bd370965fa6a430bb Signed-off-by: shihong.zheng (cherry picked from commit 9885d98f727777e4f6f8966fd0690d7ae76d875c) --- drivers/frame_provider/decoder/vav1/vav1.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/frame_provider/decoder/vav1/vav1.c b/drivers/frame_provider/decoder/vav1/vav1.c index faeaa9b..3209565 100644 --- a/drivers/frame_provider/decoder/vav1/vav1.c +++ b/drivers/frame_provider/decoder/vav1/vav1.c @@ -1481,9 +1481,9 @@ static u32 max_decoding_time; static u32 error_handle_policy; /*static u32 parser_sei_enable = 1;*/ -#define MAX_BUF_NUM_NORMAL 16 +#define MAX_BUF_NUM_NORMAL 18 /*less bufs num 12 caused frame drop, nts failed*/ -#define MAX_BUF_NUM_LESS 13 +#define MAX_BUF_NUM_LESS 15 static u32 max_buf_num = MAX_BUF_NUM_NORMAL; #define MAX_BUF_NUM_SAVE_BUF 8 @@ -8975,7 +8975,7 @@ static void av1_frame_mode_pts_save(struct AV1HW_s *hw) } calc_dur = PTS2DUR(pts_diff_sum / valid_pts_diff_cnt); if ((!close_to(calc_dur, hw->frame_dur, 10)) && - (calc_dur < 4800) && (calc_dur > 800)) { + (calc_dur < 9601) && (calc_dur > 800)) { av1_print(hw, 0, "change to calc dur %d, old dur %d\n", calc_dur, hw->frame_dur); hw->frame_dur = calc_dur; hw->get_frame_dur = true; -- 2.20.1