From de81b2cf0a465e2c6c43c7f9f864129728b3a080 Mon Sep 17 00:00:00 2001 From: Michel Dänzer Date: Wed, 7 Oct 2009 16:36:39 +0200 Subject: st/dri: Add missing front buffer case in dri_get_buffers(). This seems to help for compiz at least with some drivers. Also add an assert(0) to catch unhandled cases in the future. --- src/gallium/state_trackers/dri/dri_drawable.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/gallium/state_trackers') diff --git a/src/gallium/state_trackers/dri/dri_drawable.c b/src/gallium/state_trackers/dri/dri_drawable.c index 3f8dc8df75e..c67cc8dacb6 100644 --- a/src/gallium/state_trackers/dri/dri_drawable.c +++ b/src/gallium/state_trackers/dri/dri_drawable.c @@ -213,6 +213,7 @@ dri_get_buffers(__DRIdrawablePrivate * dPriv) dri_drawable->h, buffers[i].pitch); switch (buffers[i].attachment) { + case __DRI_BUFFER_FRONT_LEFT: case __DRI_BUFFER_FAKE_FRONT_LEFT: case __DRI_BUFFER_BACK_LEFT: drawable->color_format = surface->format; @@ -222,6 +223,9 @@ dri_get_buffers(__DRIdrawablePrivate * dPriv) case __DRI_BUFFER_STENCIL: drawable->depth_stencil_format = surface->format; break; + case __DRI_BUFFER_ACCUM: + default: + assert(0); } st_set_framebuffer_surface(drawable->stfb, index, surface); -- cgit v1.2.3