ecore evas - wl - use loop time for anim tick not compositor timestamp
This commit is contained in:
parent
878f4436f7
commit
f86791d4c3
|
@ -37,29 +37,30 @@ static void _ecore_evas_wl_selection_init(Ecore_Evas *ee);
|
||||||
|
|
||||||
/* local functions */
|
/* local functions */
|
||||||
static void
|
static void
|
||||||
_anim_cb_tick(Ecore_Wl2_Window *win EINA_UNUSED, uint32_t timestamp, void *data)
|
_anim_cb_tick(Ecore_Wl2_Window *win EINA_UNUSED, uint32_t timestamp EINA_UNUSED, void *data)
|
||||||
{
|
{
|
||||||
Ecore_Evas *ee = data;
|
Ecore_Evas *ee = data;
|
||||||
Ecore_Evas_Engine_Wl_Data *edata;
|
Ecore_Evas_Engine_Wl_Data *edata;
|
||||||
double t;//, rt;
|
// double t;//, rt;
|
||||||
double tnow = ecore_time_get();
|
// double tnow = ecore_time_get();
|
||||||
/* static double pt = 0.0, prt = 0.0; */
|
/* static double pt = 0.0, prt = 0.0; */
|
||||||
|
|
||||||
edata = ee->engine.data;
|
edata = ee->engine.data;
|
||||||
|
|
||||||
if (!edata->ticking) return;
|
if (!edata->ticking) return;
|
||||||
t = ((double)timestamp / 1000.0);
|
// t = ((double)timestamp / 1000.0);
|
||||||
if ((t - tnow) < -0.1)
|
// if ((t - tnow) < -0.1)
|
||||||
{
|
// {
|
||||||
fprintf(stderr,
|
// fprintf(stderr,
|
||||||
"ecore_evas: _anim_cb_tick() -> tick too far in past - %1.5f sec behind\n",
|
// "ecore_evas: _anim_cb_tick() -> tick too far in past - %1.5f sec behind\n",
|
||||||
tnow - t);
|
// tnow - t);
|
||||||
t = tnow;
|
// t = tnow;
|
||||||
}
|
// }
|
||||||
ecore_loop_time_set(t);
|
// ecore_loop_time_set(t);
|
||||||
/* rt = ecore_time_get(); */
|
/* rt = ecore_time_get(); */
|
||||||
/* printf("ECORE_EVAS: wl client anim tick %p | %p - %1.5f @ %1.5f delt=%1.5f | %1.5f\n", ee, edata, t, ecore_time_get(), t - pt, rt - prt); */
|
/* printf("ECORE_EVAS: wl client anim tick %p | %p - %1.5f @ %1.5f delt=%1.5f | %1.5f\n", ee, edata, t, ecore_time_get(), t - pt, rt - prt); */
|
||||||
ecore_evas_animator_tick(ee, NULL, t);
|
// ecore_evas_animator_tick(ee, NULL, t);
|
||||||
|
ecore_evas_animator_tick(ee, NULL, ecore_loop_time_get());
|
||||||
/* pt = t; */
|
/* pt = t; */
|
||||||
/* prt = rt; */
|
/* prt = rt; */
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue