From: Seunghun Lee Date: Tue, 14 May 2019 03:45:35 +0000 (+0900) Subject: video: Changed timing to send 'wl_surface.frame' message for hwc video client. X-Git-Tag: accepted/tizen/unified/20190613.235742~6 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F40%2F207740%2F2;p=platform%2Fupstream%2Fenlightenment.git video: Changed timing to send 'wl_surface.frame' message for hwc video client. This patch gives a video client chance to throttle drawing its framebuffer with framerate under compositor's capable. Change-Id: I97922f6b47cfab25bbbafd0fd72dff48b12ad3eb --- diff --git a/src/bin/e_comp_wl.c b/src/bin/e_comp_wl.c index 2bf1ea7..6213784 100644 --- a/src/bin/e_comp_wl.c +++ b/src/bin/e_comp_wl.c @@ -2576,13 +2576,6 @@ _e_comp_wl_surface_state_commit(E_Client *ec, E_Comp_Wl_Surface_State *state) e_comp_wl_subsurface_check_below_bg_rectangle(ec); - if (((buffer) && - (buffer->type == E_COMP_WL_BUFFER_TYPE_VIDEO)) && - (e_comp->wl_comp_data->available_hw_accel.underlay)) - { - e_pixmap_image_clear(ec->pixmap, 1); - } - state->buffer_viewport.changed = 0; if (buffer && diff --git a/src/bin/video/iface/e_video_hwc.c b/src/bin/video/iface/e_video_hwc.c index 7794339..8dc198a 100644 --- a/src/bin/video/iface/e_video_hwc.c +++ b/src/bin/video/iface/e_video_hwc.c @@ -143,6 +143,10 @@ _e_video_hwc_wait_buffer_commit(E_Video_Hwc *evh) static void _e_video_hwc_buffer_commit(E_Video_Hwc *evh, E_Comp_Wl_Video_Buf *vbuf) { + /* Send a message 'wl_surface.frame', right before commit a buffer to + * tdm driver. */ + e_pixmap_image_clear(evh->ec->pixmap, EINA_TRUE); + evh->committed_list = eina_list_append(evh->committed_list, vbuf); if (!_e_video_hwc_can_commit(evh))