kms-winsys: Mark the framebuffer to be bound when setting a new layout

We need to bind the context to the new EGL surface we just created.

https://bugzilla.gnome.org/show_bug.cgi?id=741881
This commit is contained in:
Rui Matos 2015-01-21 21:43:02 +01:00
parent 665c1d0faf
commit c36e31401d

View File

@ -1177,6 +1177,7 @@ cogl_kms_display_set_layout (CoglDisplay *display,
height != kms_display->height) && height != kms_display->height) &&
kms_display->onscreen) kms_display->onscreen)
{ {
CoglContext *context = COGL_FRAMEBUFFER (kms_display->onscreen)->context;
CoglOnscreenEGL *egl_onscreen = kms_display->onscreen->winsys; CoglOnscreenEGL *egl_onscreen = kms_display->onscreen->winsys;
CoglOnscreenKMS *kms_onscreen = egl_onscreen->platform; CoglOnscreenKMS *kms_onscreen = egl_onscreen->platform;
struct gbm_surface *new_surface; struct gbm_surface *new_surface;
@ -1219,6 +1220,7 @@ cogl_kms_display_set_layout (CoglDisplay *display,
egl_onscreen->egl_surface = new_egl_surface; egl_onscreen->egl_surface = new_egl_surface;
_cogl_framebuffer_winsys_update_size (COGL_FRAMEBUFFER (kms_display->onscreen), width, height); _cogl_framebuffer_winsys_update_size (COGL_FRAMEBUFFER (kms_display->onscreen), width, height);
context->current_draw_buffer_changes |= COGL_FRAMEBUFFER_STATE_BIND;
} }
kms_display->width = width; kms_display->width = width;