mirror of
https://github.com/X11Libre/xserver.git
synced 2026-09-26 21:12:25 +00:00
glamor: Replace glamor_get/put_context() with just glamor_make_current().
Now that we have the DIX global state for the current context, we
don't need to track nesting to try to reduce MakeCurrent overhead.
v2: Fix a mistaken replacement of a put_context with make_current in
glamor_fill_spans_gl() (caught by keithp).
Signed-off-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com> (v1)
Reviewed-by: Adam Jackson <ajax@redhat.com> (v1)
This commit is contained in:
parent
11ff12d4e7
commit
fab0a4a4c9
24 changed files with 81 additions and 223 deletions
|
|
@ -248,11 +248,10 @@ glamor_block_handler(ScreenPtr screen)
|
|||
{
|
||||
glamor_screen_private *glamor_priv = glamor_get_screen_private(screen);
|
||||
|
||||
glamor_get_context(glamor_priv);
|
||||
glamor_make_current(glamor_priv);
|
||||
glamor_priv->tick++;
|
||||
glFlush();
|
||||
glamor_fbo_expire(glamor_priv);
|
||||
glamor_put_context(glamor_priv);
|
||||
if (glamor_priv->state == RENDER_STATE
|
||||
&& glamor_priv->render_idle_cnt++ > RENDER_IDEL_MAX) {
|
||||
glamor_priv->state = IDLE_STATE;
|
||||
|
|
@ -265,9 +264,8 @@ _glamor_block_handler(void *data, OSTimePtr timeout, void *last_select_mask)
|
|||
{
|
||||
glamor_screen_private *glamor_priv = data;
|
||||
|
||||
glamor_get_context(glamor_priv);
|
||||
glamor_make_current(glamor_priv);
|
||||
glFlush();
|
||||
glamor_put_context(glamor_priv);
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
Loading…
Reference in a new issue