From fed45cdaa42aa5e7e365adf9f259630f6e9350d2 Mon Sep 17 00:00:00 2001 From: Yong Qin Date: Fri, 19 Apr 2019 10:15:51 +0800 Subject: [PATCH] di: small window bottom of the screen is blank [1/1] PD#TV-4708 Problem: small window, bottom of the screen is covered by blank on the online video Solution: vline is odd, mif out is not right Verify: verify on TL1 Change-Id: I39eb0cdfd2f4b200a09a9c8b779f509caf6dea37 Signed-off-by: Yong Qin --- drivers/amlogic/media/deinterlace/deinterlace.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/drivers/amlogic/media/deinterlace/deinterlace.c b/drivers/amlogic/media/deinterlace/deinterlace.c index 67a4ec5..c532ec8 100644 --- a/drivers/amlogic/media/deinterlace/deinterlace.c +++ b/drivers/amlogic/media/deinterlace/deinterlace.c @@ -129,7 +129,7 @@ static di_dev_t *de_devp; static dev_t di_devno; static struct class *di_clsp; -static const char version_s[] = "2019-0401:TM2 bring up"; +static const char version_s[] = "2019-0419a:vscale_skip v is odd"; static int bypass_state = 1; static int bypass_all; @@ -4807,9 +4807,16 @@ de_post_process(void *arg, unsigned int zoom_start_x_lines, di_end_y = zoom_end_y_lines; di_height = di_end_y - di_start_y + 1; di_height = di_height / (di_vscale_skip_count_real + 1); + /* make sure the height is even number */ - if (di_height%2) - di_height++; + if (di_height%2) { + /*for skip mode,post only half line-1*/ + if (((di_height > 150) && (di_height < 500)) && + di_vscale_skip_count_real) + di_height = di_height - 3; + else + di_height++; + } if (Rd(DI_POST_SIZE) != ((di_width - 1) | ((di_height - 1) << 16)) || di_post_stru.buf_type != di_buf->di_buf_dup_p[0]->type || -- 2.7.4