evas_damage_rectangle_add(root_target_hwc_window->evas, 0, 0, w, h);
}
-static Eina_Bool
-_e_hwc_windows_target_window_buffer_skip(E_Hwc *hwc)
-{
- E_Hwc_Window_Target *target_hwc_window;
- E_Hwc_Window *hwc_window;
- tdm_hwc *thwc;
- tdm_region fb_damage;
-
- target_hwc_window = hwc->target_hwc_window;
- EINA_SAFETY_ON_NULL_RETURN_VAL(target_hwc_window, EINA_FALSE);
-
- hwc_window = (E_Hwc_Window *)target_hwc_window;
-
- thwc = hwc->thwc;
- EINA_SAFETY_ON_NULL_RETURN_VAL(thwc, EINA_FALSE);
-
- CLEAR(fb_damage);
-
- if ((hwc_window->current.buffer.tsurface) &&
- (hwc_window->current.buffer.tsurface != hwc_window->display.buffer.tsurface))
- {
- e_hwc_window_queue_buffer_reference(&hwc_window->current.queue_buffer_ref, hwc_window->display.queue_buffer_ref.buffer);
- e_hwc_window_buffer_set(&hwc_window->current.buffer, hwc_window->display.buffer.tsurface,
- hwc_window->display.buffer.queue, hwc_window->display.buffer.transform);
- tdm_hwc_set_client_target_buffer(thwc, hwc_window->display.buffer.tsurface, fb_damage);
-
- e_hwc_windows_target_window_force_render(target_hwc_window);
- }
-
- if (hwc->root_target_hwc_window)
- {
- hwc_window = (E_Hwc_Window *)hwc->root_target_hwc_window;
-
- if (hwc_window->current.buffer.tsurface)
- e_hwc_windows_presentation_time_feedback_and_callback_take(hwc, hwc_window->current.buffer.tsurface);
-
- e_hwc_window_queue_buffer_reference(&hwc_window->current.queue_buffer_ref, hwc_window->display.queue_buffer_ref.buffer);
- e_hwc_window_buffer_set(&hwc_window->current.buffer, hwc_window->display.buffer.tsurface,
- hwc_window->display.buffer.queue, hwc_window->display.buffer.transform);
- }
-
- return EINA_TRUE;
-}
-
static void
_e_hwc_windows_target_window_queue_clear(E_Hwc_Window_Target *target_hwc_window)
{
static Eina_Bool
_e_hwc_windows_present_sync_check(E_Hwc *hwc)
{
- E_Hwc_Window_Target *target_hwc_window;
E_Hwc_Window_Target *root_target_hwc_window;
+ E_Hwc_Window *hwc_window;
if (!hwc->present_sync) return EINA_FALSE;
- target_hwc_window = hwc->target_hwc_window;
- EINA_SAFETY_ON_NULL_RETURN_VAL(target_hwc_window, EINA_FALSE);
+ hwc_window = (E_Hwc_Window *)hwc->target_hwc_window;
+ EINA_SAFETY_ON_NULL_RETURN_VAL(hwc_window, EINA_FALSE);
if (hwc->hwc_mode != E_HWC_MODE_FULL)
{
- if ((((E_Hwc_Window *)target_hwc_window)->display.buffer.tsurface) ==
- (((E_Hwc_Window *)target_hwc_window)->current.buffer.tsurface))
+ if ((!hwc_window->current.buffer.tsurface) ||
+ (e_hwc_window_display_or_commit_buffer_check(hwc_window,
+ hwc_window->current.buffer.tsurface)))
{
root_target_hwc_window = _e_hwc_windows_root_target_hwc_window_get(hwc);
if (root_target_hwc_window)
{
if (!eina_list_count(root_target_hwc_window->rendering_tsurfaces))
- e_hwc_windows_target_window_force_render(target_hwc_window);
+ e_hwc_windows_target_window_force_render(hwc->target_hwc_window);
}
return EINA_TRUE;
}
_e_hwc_windows_target_window_queue_clear(root_target_hwc_window);
-
- _e_hwc_windows_target_window_buffer_skip(hwc);
-
e_hwc_windows_target_window_force_render(hwc->target_hwc_window);
EHWSINF("Present sync", NULL, hwc);