mirror of
https://github.com/brl/mutter.git
synced 2024-12-23 19:42:05 +00:00
cogl: Initialize the framebuffer bits on state flush
The place where we actually change the framebuffer is _cogl_framebuffer_flush_state(), so if we changed to a new frame buffer we need to initialize the color bits there. http://bugzilla.openedhand.com/show_bug.cgi?id=2094
This commit is contained in:
parent
7a7dedebd5
commit
2ba6ab6dbc
@ -641,8 +641,6 @@ _cogl_set_framebuffer_real (CoglFramebuffer *framebuffer)
|
||||
_cogl_matrix_stack_dirty (framebuffer->modelview_stack);
|
||||
_cogl_matrix_stack_dirty (framebuffer->projection_stack);
|
||||
_cogl_clip_state_dirty (&framebuffer->clip_state);
|
||||
|
||||
_cogl_framebuffer_init_bits (framebuffer);
|
||||
}
|
||||
|
||||
void
|
||||
@ -785,6 +783,11 @@ _cogl_framebuffer_flush_state (CoglHandle handle,
|
||||
ctx->dirty_gl_viewport = FALSE;
|
||||
}
|
||||
|
||||
/* since we might have changed the framebuffer, we should initialize
|
||||
* the bits; this is a no-op if they have already been initialized
|
||||
*/
|
||||
_cogl_framebuffer_init_bits (framebuffer);
|
||||
|
||||
/* XXX: Flushing clip state may trash the modelview and projection
|
||||
* matrices so we must do it before flushing the matrices...
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user