clutter/stage: Add private getter to sync delay
It will be used by the frame chart to correctly place the red bar. The math is essentially: ms_per_frame = (1 / refresh rate) * 1000 - sync delay https://gitlab.gnome.org/GNOME/mutter/merge_requests/502
This commit is contained in:
parent
f7321d235f
commit
6350efc28e
@ -134,6 +134,8 @@ void _clutter_stage_presented (ClutterStage *stag
|
|||||||
|
|
||||||
GList * _clutter_stage_peek_stage_views (ClutterStage *stage);
|
GList * _clutter_stage_peek_stage_views (ClutterStage *stage);
|
||||||
|
|
||||||
|
int clutter_stage_get_sync_delay (ClutterStage *stage);
|
||||||
|
|
||||||
G_END_DECLS
|
G_END_DECLS
|
||||||
|
|
||||||
#endif /* __CLUTTER_STAGE_PRIVATE_H__ */
|
#endif /* __CLUTTER_STAGE_PRIVATE_H__ */
|
||||||
|
@ -4722,6 +4722,14 @@ clutter_stage_set_sync_delay (ClutterStage *stage,
|
|||||||
stage->priv->sync_delay = sync_delay;
|
stage->priv->sync_delay = sync_delay;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int
|
||||||
|
clutter_stage_get_sync_delay (ClutterStage *stage)
|
||||||
|
{
|
||||||
|
g_return_val_if_fail (CLUTTER_IS_STAGE (stage), -1);
|
||||||
|
|
||||||
|
return stage->priv->sync_delay;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* clutter_stage_skip_sync_delay:
|
* clutter_stage_skip_sync_delay:
|
||||||
* @stage: a #ClutterStage
|
* @stage: a #ClutterStage
|
||||||
|
Loading…
x
Reference in New Issue
Block a user