summaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2019-08-01 09:16:47 +0100
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2019-08-02 16:41:12 +0100
commitd9dbd2fbea47d3d6ffdcee1bca84f06c989367cf (patch)
tree54dd6d3fefb2301bdb06a33a5fad7e38d86dab4b /src/modules
parentd13c59fb8953764a4042aa481e5b88f7a1eb56b6 (diff)
ecore evas x and e sync rendering - disable as it's unused
this has been optional and unused by e for a very long time ot try sync front-buffered software rendering with the wm/compositor. we may as well remove the bloat that is here that is unused... it's been inactive for many years anyway.
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/ecore_evas/engines/x/ecore_evas_x.c173
1 files changed, 2 insertions, 171 deletions
diff --git a/src/modules/ecore_evas/engines/x/ecore_evas_x.c b/src/modules/ecore_evas/engines/x/ecore_evas_x.c
index 8c12aa44a3..590831760e 100644
--- a/src/modules/ecore_evas/engines/x/ecore_evas_x.c
+++ b/src/modules/ecore_evas/engines/x/ecore_evas_x.c
@@ -80,20 +80,16 @@ struct _Ecore_Evas_Engine_Data_X11 {
80 Ecore_X_XRegion *damages; 80 Ecore_X_XRegion *damages;
81 Ecore_Timer *outdelay; 81 Ecore_Timer *outdelay;
82 Ecore_X_Event_Mouse_Out out_ev; 82 Ecore_X_Event_Mouse_Out out_ev;
83 Ecore_X_Sync_Counter sync_counter;
84 Ecore_X_Window leader; 83 Ecore_X_Window leader;
85 Ecore_X_Sync_Counter netwm_sync_counter; 84 Ecore_X_Sync_Counter netwm_sync_counter;
86 int configure_reqs; 85 int configure_reqs;
87 int netwm_sync_val_hi; 86 int netwm_sync_val_hi;
88 unsigned int netwm_sync_val_lo; 87 unsigned int netwm_sync_val_lo;
89 int sync_val; // bigger! this will screw up at 2 billion fram~
90 int screen_num; 88 int screen_num;
91 int px, py, pw, ph; 89 int px, py, pw, ph;
92 unsigned char direct_resize : 1; 90 unsigned char direct_resize : 1;
93 unsigned char using_bg_pixmap : 1; 91 unsigned char using_bg_pixmap : 1;
94 unsigned char managed : 1; 92 unsigned char managed : 1;
95 unsigned char sync_began : 1;
96 unsigned char sync_cancel : 1;
97 unsigned char netwm_sync_set : 1; 93 unsigned char netwm_sync_set : 1;
98 unsigned char configure_coming : 1; 94 unsigned char configure_coming : 1;
99 struct { 95 struct {
@@ -252,44 +248,6 @@ _ecore_evas_x_protocols_set(Ecore_Evas *ee)
252} 248}
253 249
254static void 250static void
255_ecore_evas_x_sync_set(Ecore_Evas *ee)
256{
257 Ecore_Evas_Engine_Data_X11 *edata = ee->engine.data;
258 Ecore_X_Sync_Counter sync_counter = edata->sync_counter;
259
260 if (ee->deleted) return;
261 if (((ee->should_be_visible) || (ee->visible)) &&
262 ((ecore_x_e_comp_sync_supported_get(edata->win_root)) &&
263 (!ee->no_comp_sync) && (_ecore_evas_app_comp_sync)))
264 {
265 if (!edata->sync_counter)
266 edata->sync_counter = ecore_x_sync_counter_new(0);
267 }
268 else
269 {
270 if (edata->sync_counter)
271 {
272 ecore_x_sync_counter_free(edata->sync_counter);
273 edata->sync_val = 0;
274 }
275 edata->sync_counter = 0;
276 }
277 if ((!edata->destroyed) && (sync_counter != edata->sync_counter))
278 ecore_x_e_comp_sync_counter_set(ee->prop.window, edata->sync_counter);
279}
280
281static void
282_ecore_evas_x_sync_clear(Ecore_Evas *ee)
283{
284 Ecore_Evas_Engine_Data_X11 *edata = ee->engine.data;
285
286 if (!edata->sync_counter) return;
287 ecore_x_sync_counter_free(edata->sync_counter);
288 edata->sync_val = 0;
289 edata->sync_counter = 0;
290}
291
292static void
293_ecore_evas_x_wm_rotation_protocol_set(Ecore_Evas *ee) 251_ecore_evas_x_wm_rotation_protocol_set(Ecore_Evas *ee)
294{ 252{
295 Ecore_Evas_Engine_Data_X11 *edata = ee->engine.data; 253 Ecore_Evas_Engine_Data_X11 *edata = ee->engine.data;
@@ -766,12 +724,6 @@ static int
766_ecore_evas_x_render(Ecore_Evas *ee) 724_ecore_evas_x_render(Ecore_Evas *ee)
767{ 725{
768 int rend = 0; 726 int rend = 0;
769 Ecore_Evas_Engine_Data_X11 *edata = ee->engine.data;
770
771 if ((!ee->no_comp_sync) && (_ecore_evas_app_comp_sync) &&
772 (edata->sync_counter) && (!edata->sync_began) &&
773 (!edata->sync_cancel))
774 return 0;
775 727
776 if (ee->in_async_render) 728 if (ee->in_async_render)
777 { 729 {
@@ -1090,43 +1042,8 @@ _ecore_evas_x_event_client_message(void *data EINA_UNUSED, int type EINA_UNUSED,
1090 1042
1091 e = event; 1043 e = event;
1092 if (e->format != 32) return ECORE_CALLBACK_PASS_ON; 1044 if (e->format != 32) return ECORE_CALLBACK_PASS_ON;
1093 if (e->message_type == ECORE_X_ATOM_E_COMP_SYNC_BEGIN) 1045 if ((e->message_type == ECORE_X_ATOM_WM_PROTOCOLS) &&
1094 { 1046 (e->data.l[0] == (int)ECORE_X_ATOM_NET_WM_SYNC_REQUEST))
1095 ee = ecore_event_window_match(e->data.l[0]);
1096 if (!ee) return ECORE_CALLBACK_PASS_ON; /* pass on event */
1097 edata = ee->engine.data;
1098 if (e->data.l[0] != (long)ee->prop.window)
1099 return ECORE_CALLBACK_PASS_ON;
1100 if (!edata->sync_began)
1101 {
1102 // qeue a damage + draw. work around an event re-ordering thing.
1103 evas_damage_rectangle_add(ee->evas, 0, 0, ee->w, ee->h);
1104 }
1105 edata->sync_began = 1;
1106 edata->sync_cancel = 0;
1107 }
1108 else if (e->message_type == ECORE_X_ATOM_E_COMP_SYNC_END)
1109 {
1110 ee = ecore_event_window_match(e->data.l[0]);
1111 if (!ee) return ECORE_CALLBACK_PASS_ON; /* pass on event */
1112 edata = ee->engine.data;
1113 if (e->data.l[0] != (long)ee->prop.window)
1114 return ECORE_CALLBACK_PASS_ON;
1115 edata->sync_began = 0;
1116 edata->sync_cancel = 0;
1117 }
1118 else if (e->message_type == ECORE_X_ATOM_E_COMP_SYNC_CANCEL)
1119 {
1120 ee = ecore_event_window_match(e->data.l[0]);
1121 if (!ee) return ECORE_CALLBACK_PASS_ON; /* pass on event */
1122 edata = ee->engine.data;
1123 if (e->data.l[0] != (long)ee->prop.window)
1124 return ECORE_CALLBACK_PASS_ON;
1125 edata->sync_began = 0;
1126 edata->sync_cancel = 1;
1127 }
1128 else if ((e->message_type == ECORE_X_ATOM_WM_PROTOCOLS) &&
1129 (e->data.l[0] == (int)ECORE_X_ATOM_NET_WM_SYNC_REQUEST))
1130 { 1047 {
1131 ee = ecore_event_window_match(e->win); 1048 ee = ecore_event_window_match(e->win);
1132 if (!ee) return ECORE_CALLBACK_PASS_ON; /* pass on event */ 1049 if (!ee) return ECORE_CALLBACK_PASS_ON; /* pass on event */
@@ -1594,7 +1511,6 @@ _ecore_evas_x_event_window_destroy(void *data EINA_UNUSED, int type EINA_UNUSED,
1594 edata = ee->engine.data; 1511 edata = ee->engine.data;
1595 if (ee->func.fn_destroy) ee->func.fn_destroy(ee); 1512 if (ee->func.fn_destroy) ee->func.fn_destroy(ee);
1596 edata->destroyed = 1; 1513 edata->destroyed = 1;
1597 _ecore_evas_x_sync_clear(ee);
1598 ecore_evas_free(ee); 1514 ecore_evas_free(ee);
1599 return ECORE_CALLBACK_PASS_ON; 1515 return ECORE_CALLBACK_PASS_ON;
1600} 1516}
@@ -1779,15 +1695,6 @@ _ecore_evas_x_event_window_show(void *data EINA_UNUSED, int type EINA_UNUSED, vo
1779 if (!ee) return ECORE_CALLBACK_PASS_ON; /* pass on event */ 1695 if (!ee) return ECORE_CALLBACK_PASS_ON; /* pass on event */
1780 if (e->win != ee->prop.window) return ECORE_CALLBACK_PASS_ON; 1696 if (e->win != ee->prop.window) return ECORE_CALLBACK_PASS_ON;
1781 1697
1782 if (ee->gl_sync_draw_done < 0)
1783 {
1784 char *sync = getenv("ECORE_EVAS_GL_SYNC_DRAW_DONE");
1785 if (sync && (atoi(sync) == 1))
1786 ee->gl_sync_draw_done = 1;
1787 else
1788 ee->gl_sync_draw_done = 0;
1789 }
1790
1791 if (first_map_bug < 0) 1698 if (first_map_bug < 0)
1792 { 1699 {
1793 char *bug = NULL; 1700 char *bug = NULL;
@@ -2081,8 +1988,6 @@ _ecore_evas_x_free(Ecore_Evas *ee)
2081 } 1988 }
2082 1989
2083 _ecore_evas_x_group_leader_unset(ee); 1990 _ecore_evas_x_group_leader_unset(ee);
2084 if (edata->sync_counter)
2085 ecore_x_sync_counter_free(edata->sync_counter);
2086 if (edata->netwm_sync_counter) 1991 if (edata->netwm_sync_counter)
2087 ecore_x_sync_counter_free(edata->netwm_sync_counter); 1992 ecore_x_sync_counter_free(edata->netwm_sync_counter);
2088 if (edata->win_shaped_input) 1993 if (edata->win_shaped_input)
@@ -2123,7 +2028,6 @@ _ecore_evas_x_callback_delete_request_set(Ecore_Evas *ee, Ecore_Evas_Event_Cb fu
2123{ 2028{
2124 ee->func.fn_delete_request = func; 2029 ee->func.fn_delete_request = func;
2125 _ecore_evas_x_protocols_set(ee); 2030 _ecore_evas_x_protocols_set(ee);
2126 _ecore_evas_x_sync_set(ee);
2127} 2031}
2128 2032
2129static void 2033static void
@@ -2702,7 +2606,6 @@ _alpha_do(Ecore_Evas *ee, int alpha)
2702 2606
2703 ee->shaped = 0; 2607 ee->shaped = 0;
2704 ee->alpha = alpha; 2608 ee->alpha = alpha;
2705 _ecore_evas_x_sync_clear(ee);
2706 ecore_x_window_free(ee->prop.window); 2609 ecore_x_window_free(ee->prop.window);
2707 ecore_event_window_unregister(ee->prop.window); 2610 ecore_event_window_unregister(ee->prop.window);
2708 if (ee->alpha) 2611 if (ee->alpha)
@@ -2772,7 +2675,6 @@ _alpha_do(Ecore_Evas *ee, int alpha)
2772 _ecore_evas_x_wm_rotation_protocol_set(ee); 2675 _ecore_evas_x_wm_rotation_protocol_set(ee);
2773 _ecore_evas_x_aux_hints_supported_update(ee); 2676 _ecore_evas_x_aux_hints_supported_update(ee);
2774 _ecore_evas_x_aux_hints_update(ee); 2677 _ecore_evas_x_aux_hints_update(ee);
2775 _ecore_evas_x_sync_set(ee);
2776 _ecore_evas_x_size_pos_hints_update(ee); 2678 _ecore_evas_x_size_pos_hints_update(ee);
2777#endif /* BUILD_ECORE_EVAS_SOFTWARE_X11 */ 2679#endif /* BUILD_ECORE_EVAS_SOFTWARE_X11 */
2778 if ((id = getenv("DESKTOP_STARTUP_ID"))) 2680 if ((id = getenv("DESKTOP_STARTUP_ID")))
@@ -2822,7 +2724,6 @@ _ecore_evas_x_alpha_set(Ecore_Evas *ee, int alpha)
2822 2724
2823 ee->shaped = 0; 2725 ee->shaped = 0;
2824 ee->alpha = alpha; 2726 ee->alpha = alpha;
2825 _ecore_evas_x_sync_clear(ee);
2826 prev_win = ee->prop.window; 2727 prev_win = ee->prop.window;
2827 ee->prop.window = 0; 2728 ee->prop.window = 0;
2828 2729
@@ -2928,7 +2829,6 @@ _ecore_evas_x_alpha_set(Ecore_Evas *ee, int alpha)
2928 _ecore_evas_x_wm_rotation_protocol_set(ee); 2829 _ecore_evas_x_wm_rotation_protocol_set(ee);
2929 _ecore_evas_x_aux_hints_supported_update(ee); 2830 _ecore_evas_x_aux_hints_supported_update(ee);
2930 _ecore_evas_x_aux_hints_update(ee); 2831 _ecore_evas_x_aux_hints_update(ee);
2931 _ecore_evas_x_sync_set(ee);
2932 _ecore_evas_x_size_pos_hints_update(ee); 2832 _ecore_evas_x_size_pos_hints_update(ee);
2933#endif /* BUILD_ECORE_EVAS_OPENGL_X11 */ 2833#endif /* BUILD_ECORE_EVAS_OPENGL_X11 */
2934 if ((id = getenv("DESKTOP_STARTUP_ID"))) 2834 if ((id = getenv("DESKTOP_STARTUP_ID")))
@@ -3074,7 +2974,6 @@ _ecore_evas_x_show(Ecore_Evas *ee)
3074 ee->should_be_visible = 1; 2974 ee->should_be_visible = 1;
3075 if (ee->prop.avoid_damage) 2975 if (ee->prop.avoid_damage)
3076 _ecore_evas_x_render(ee); 2976 _ecore_evas_x_render(ee);
3077 _ecore_evas_x_sync_set(ee);
3078 _ecore_evas_x_window_profile_set(ee); 2977 _ecore_evas_x_window_profile_set(ee);
3079 if (!ee->prop.withdrawn) _ecore_evas_x_hints_update(ee); 2978 if (!ee->prop.withdrawn) _ecore_evas_x_hints_update(ee);
3080 else 2979 else
@@ -3092,7 +2991,6 @@ _ecore_evas_x_hide(Ecore_Evas *ee)
3092{ 2991{
3093 ecore_x_window_hide(ee->prop.window); 2992 ecore_x_window_hide(ee->prop.window);
3094 ee->should_be_visible = 0; 2993 ee->should_be_visible = 0;
3095 _ecore_evas_x_sync_set(ee);
3096} 2994}
3097 2995
3098static void 2996static void
@@ -3913,26 +3811,6 @@ _ecore_evas_x_render_pre(void *data, Evas *e EINA_UNUSED, void *event_info EINA_
3913} 3811}
3914 3812
3915static void 3813static void
3916_ecore_evas_x_flush_pre(void *data, Evas *e EINA_UNUSED, void *event_info EINA_UNUSED)
3917{
3918 Ecore_Evas *ee = data;
3919 Ecore_Evas_Engine_Data_X11 *edata = ee->engine.data;
3920
3921 if (ee->no_comp_sync) return;
3922 if (!_ecore_evas_app_comp_sync) return;
3923 if (!edata->sync_counter) return;
3924 if (!edata->sync_began) return;
3925
3926 edata->sync_val++;
3927 if (!edata->sync_cancel)
3928 {
3929 if (!ee->semi_sync)
3930 ecore_x_sync_counter_val_wait(edata->sync_counter,
3931 edata->sync_val);
3932 }
3933}
3934
3935static void
3936_ecore_evas_x_flush_post(void *data, Evas *e EINA_UNUSED, void *event_info EINA_UNUSED) 3814_ecore_evas_x_flush_post(void *data, Evas *e EINA_UNUSED, void *event_info EINA_UNUSED)
3937{ 3815{
3938 Ecore_Evas *ee = data; 3816 Ecore_Evas *ee = data;
@@ -3998,24 +3876,6 @@ _ecore_evas_x_flush_post(void *data, Evas *e EINA_UNUSED, void *event_info EINA_
3998 } 3876 }
3999 } 3877 }
4000 3878
4001 if ((!ee->no_comp_sync) && (_ecore_evas_app_comp_sync) &&
4002 (ee->gl_sync_draw_done != 1))
4003 {
4004 if (edata->sync_counter)
4005 {
4006 if (edata->sync_began)
4007 {
4008 if (!edata->sync_cancel)
4009 {
4010 if (ee->prop.window)
4011 {
4012 ecore_x_e_comp_sync_draw_size_done_send
4013 (edata->win_root, ee->prop.window, ee->w, ee->h);
4014 }
4015 }
4016 }
4017 }
4018 }
4019 if (edata->netwm_sync_set) 3879 if (edata->netwm_sync_set)
4020 { 3880 {
4021 ecore_x_sync_counter_2_set(edata->netwm_sync_counter, 3881 ecore_x_sync_counter_2_set(edata->netwm_sync_counter,
@@ -4119,8 +3979,6 @@ ecore_evas_software_x11_new_internal(const char *disp_name, Ecore_X_Window paren
4119 return NULL; 3979 return NULL;
4120 } 3980 }
4121 3981
4122 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_PRE,
4123 _ecore_evas_x_flush_pre, ee);
4124 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_POST, 3982 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_POST,
4125 _ecore_evas_x_flush_post, ee); 3983 _ecore_evas_x_flush_post, ee);
4126 if (ee->can_async_render) 3984 if (ee->can_async_render)
@@ -4239,7 +4097,6 @@ ecore_evas_software_x11_new_internal(const char *disp_name, Ecore_X_Window paren
4239 _ecore_evas_x_wm_rotation_protocol_set(ee); 4097 _ecore_evas_x_wm_rotation_protocol_set(ee);
4240 _ecore_evas_x_aux_hints_supported_update(ee); 4098 _ecore_evas_x_aux_hints_supported_update(ee);
4241 _ecore_evas_x_aux_hints_update(ee); 4099 _ecore_evas_x_aux_hints_update(ee);
4242 _ecore_evas_x_sync_set(ee);
4243 4100
4244 ee->engine.func->fn_render = _ecore_evas_x_render; 4101 ee->engine.func->fn_render = _ecore_evas_x_render;
4245 ee->draw_block = EINA_TRUE; 4102 ee->draw_block = EINA_TRUE;
@@ -4321,8 +4178,6 @@ ecore_evas_software_x11_pixmap_new_internal(const char *disp_name, Ecore_X_Windo
4321 return NULL; 4178 return NULL;
4322 } 4179 }
4323 4180
4324 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_PRE,
4325 _ecore_evas_x_flush_pre, ee);
4326 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_POST, 4181 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_POST,
4327 _ecore_evas_x_flush_post, ee); 4182 _ecore_evas_x_flush_post, ee);
4328 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_PRE, 4183 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_PRE,
@@ -4454,7 +4309,6 @@ ecore_evas_software_x11_pixmap_new_internal(const char *disp_name, Ecore_X_Windo
4454 /* ecore_x_window_defaults_set(ee->prop.window); */ 4309 /* ecore_x_window_defaults_set(ee->prop.window); */
4455 /* _ecore_evas_x_protocols_set(ee); */ 4310 /* _ecore_evas_x_protocols_set(ee); */
4456 /* _ecore_evas_x_window_profile_protocol_set(ee); */ 4311 /* _ecore_evas_x_window_profile_protocol_set(ee); */
4457 /* _ecore_evas_x_sync_set(ee); */
4458 4312
4459 ee->engine.func->fn_render = _ecore_evas_x_render; 4313 ee->engine.func->fn_render = _ecore_evas_x_render;
4460 _ecore_evas_register(ee); 4314 _ecore_evas_register(ee);
@@ -4599,20 +4453,11 @@ ecore_evas_gl_x11_options_new_internal(const char *disp_name, Ecore_X_Window par
4599 4453
4600 ECORE_MAGIC_SET(ee, ECORE_MAGIC_EVAS); 4454 ECORE_MAGIC_SET(ee, ECORE_MAGIC_EVAS);
4601 4455
4602 ee->gl_sync_draw_done = -1;
4603
4604 _ecore_evas_x_init(); 4456 _ecore_evas_x_init();
4605 4457
4606 ee->engine.func = (Ecore_Evas_Engine_Func *)&_ecore_x_engine_func; 4458 ee->engine.func = (Ecore_Evas_Engine_Func *)&_ecore_x_engine_func;
4607 4459
4608 ee->driver = "opengl_x11"; 4460 ee->driver = "opengl_x11";
4609#if 1
4610 ee->semi_sync = 0; // gl engine doesn't need to sync - its whole swaps
4611#else
4612 if (!getenv("ECORE_EVAS_COMP_NOSEMISYNC"))
4613 ee->semi_sync = 1; // gl engine doesn't need to sync - its whole swaps
4614// ee->no_comp_sync = 1; // gl engine doesn't need to sync - its whole swaps
4615#endif
4616 if (disp_name) ee->name = strdup(disp_name); 4461 if (disp_name) ee->name = strdup(disp_name);
4617 4462
4618 if (w < 1) w = 1; 4463 if (w < 1) w = 1;
@@ -4641,7 +4486,6 @@ ecore_evas_gl_x11_options_new_internal(const char *disp_name, Ecore_X_Window par
4641 ecore_evas_free(ee); 4486 ecore_evas_free(ee);
4642 return NULL; 4487 return NULL;
4643 } 4488 }
4644 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_PRE, _ecore_evas_x_flush_pre, ee);
4645 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_POST, _ecore_evas_x_flush_post, ee); 4489 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_POST, _ecore_evas_x_flush_post, ee);
4646 evas_output_method_set(ee->evas, rmethod); 4490 evas_output_method_set(ee->evas, rmethod);
4647 4491
@@ -4687,7 +4531,6 @@ ecore_evas_gl_x11_options_new_internal(const char *disp_name, Ecore_X_Window par
4687 _ecore_evas_x_wm_rotation_protocol_set(ee); 4531 _ecore_evas_x_wm_rotation_protocol_set(ee);
4688 _ecore_evas_x_aux_hints_supported_update(ee); 4532 _ecore_evas_x_aux_hints_supported_update(ee);
4689 _ecore_evas_x_aux_hints_update(ee); 4533 _ecore_evas_x_aux_hints_update(ee);
4690 _ecore_evas_x_sync_set(ee);
4691 4534
4692 ee->draw_block = 1; 4535 ee->draw_block = 1;
4693 4536
@@ -4740,20 +4583,11 @@ ecore_evas_gl_x11_pixmap_new_internal(const char *disp_name, Ecore_X_Window pare
4740 4583
4741 ECORE_MAGIC_SET(ee, ECORE_MAGIC_EVAS); 4584 ECORE_MAGIC_SET(ee, ECORE_MAGIC_EVAS);
4742 4585
4743 ee->gl_sync_draw_done = -1;
4744
4745 _ecore_evas_x_init(); 4586 _ecore_evas_x_init();
4746 4587
4747 ee->engine.func = (Ecore_Evas_Engine_Func *)&_ecore_x_engine_func; 4588 ee->engine.func = (Ecore_Evas_Engine_Func *)&_ecore_x_engine_func;
4748 4589
4749 ee->driver = "opengl_x11"; 4590 ee->driver = "opengl_x11";
4750#if 1
4751 ee->semi_sync = 0; // gl engine doesn't need to sync - its whole swaps
4752#else
4753 if (!getenv("ECORE_EVAS_COMP_NOSEMISYNC"))
4754 ee->semi_sync = 1; // gl engine doesn't need to sync - its whole swaps
4755// ee->no_comp_sync = 1; // gl engine doesn't need to sync - its whole swaps
4756#endif
4757 if (disp_name) ee->name = strdup(disp_name); 4591 if (disp_name) ee->name = strdup(disp_name);
4758 4592
4759 if (w < 1) w = 1; 4593 if (w < 1) w = 1;
@@ -4781,8 +4615,6 @@ ecore_evas_gl_x11_pixmap_new_internal(const char *disp_name, Ecore_X_Window pare
4781 ecore_evas_free(ee); 4615 ecore_evas_free(ee);
4782 return NULL; 4616 return NULL;
4783 } 4617 }
4784 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_PRE,
4785 _ecore_evas_x_flush_pre, ee);
4786 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_POST, 4618 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_FLUSH_POST,
4787 _ecore_evas_x_flush_post, ee); 4619 _ecore_evas_x_flush_post, ee);
4788 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_PRE, 4620 evas_event_callback_add(ee->evas, EVAS_CALLBACK_RENDER_PRE,
@@ -4884,7 +4716,6 @@ ecore_evas_gl_x11_pixmap_new_internal(const char *disp_name, Ecore_X_Window pare
4884 /* ecore_x_window_defaults_set(ee->prop.window); */ 4716 /* ecore_x_window_defaults_set(ee->prop.window); */
4885 /* _ecore_evas_x_protocols_set(ee); */ 4717 /* _ecore_evas_x_protocols_set(ee); */
4886 /* _ecore_evas_x_window_profile_protocol_set(ee); */ 4718 /* _ecore_evas_x_window_profile_protocol_set(ee); */
4887 /* _ecore_evas_x_sync_set(ee); */
4888 4719
4889 ee->engine.func->fn_render = _ecore_evas_x_render; 4720 ee->engine.func->fn_render = _ecore_evas_x_render;
4890 _ecore_evas_register(ee); 4721 _ecore_evas_register(ee);