From a5d50f45e052b2c52980d6c0b30fba46b5251a87 Mon Sep 17 00:00:00 2001 From: Seunghun Lee Date: Sat, 30 Jan 2021 10:33:10 +0900 Subject: [PATCH] video: Fix double cropping source/output region of tdm Cropping an already cropped source/output region is an error. So, this change makes updating tdm config happen once during render job. So far this has been no problem since wl_client didn't try to set its output region beyond the screen. However, once wl_client tried to do that, the problem came out because of the double cropping. More specifically, source region was a problem. source region was cropped and updated once during applying viewport, but it was cropped and updated again with already cropped source region during applying map. Change-Id: Ia8efb27a3af66eda5564f166a9ea734d21a93cf1 --- src/bin/video/iface/e_video_hwc.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/bin/video/iface/e_video_hwc.c b/src/bin/video/iface/e_video_hwc.c index 78d53fd..8864ccf 100644 --- a/src/bin/video/iface/e_video_hwc.c +++ b/src/bin/video/iface/e_video_hwc.c @@ -1158,8 +1158,6 @@ _e_video_hwc_geometry_map_apply(E_Client *ec, E_Video_Hwc_Geometry *out) out->output_r = output_r; out->transform = transform; - _e_video_hwc_geometry_tdm_config_update(ec, out); - return EINA_TRUE; } @@ -1467,8 +1465,6 @@ _e_video_hwc_geometry_viewport_apply(E_Client *ec, E_Video_Hwc_Geometry *out) _e_video_hwc_geometry_output_rect_get(ec, &out->output_r); out->transform = vp->buffer.transform; - _e_video_hwc_geometry_tdm_config_update(ec, out); - VDB("geometry(%d,%d %dx%d %d,%d %dx%d %d)", ec, EINA_RECTANGLE_ARGS(&out->input_r),EINA_RECTANGLE_ARGS(&out->output_r), out->transform); @@ -1487,6 +1483,8 @@ _e_video_hwc_geometry_get(E_Client *ec, E_Video_Hwc_Geometry *out) _e_video_hwc_geometry_map_apply(ec, out); + _e_video_hwc_geometry_tdm_config_update(ec, out); + e_comp_wl_video_buffer_size_get(ec, &input_r.w, &input_r.h); // when topmost is not mapped, input size can be abnormal. // in this case, it will be render by topmost showing. -- 2.7.4