summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers
diff options
context:
space:
mode:
authorTapani Pälli <[email protected]>2012-10-29 11:56:28 -0700
committerChad Versace <[email protected]>2012-10-29 11:58:47 -0700
commite4e3b071814d14e56ca3feca8df4974646bc332d (patch)
tree443b7d855660d45800b8f45c5fd7c1eb8a0b3789 /src/mesa/drivers
parente8f2bec25ea9bbaedac7abfa7eabb62e1aaf3163 (diff)
intel: support for 16 bit config with 24 depth and 8 stencil
Patch adds additional singlesample config with 565 color buffer, 24 bit depth and 8 bit stencil buffer. This makes Quadrant benchmark work on Android. Tested with Sandybridge and Ivybridge machines. Signed-off-by: Tapani Pälli <[email protected]> Reviewed-by: Chad Versace <[email protected]>
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r--src/mesa/drivers/dri/intel/intel_screen.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/drivers/dri/intel/intel_screen.c
index f4ed64cc363..0194804db25 100644
--- a/src/mesa/drivers/dri/intel/intel_screen.c
+++ b/src/mesa/drivers/dri/intel/intel_screen.c
@@ -935,11 +935,11 @@ intel_screen_make_configs(__DRIscreen *dri_screen)
/* Generate singlesample configs without accumulation buffer. */
for (int i = 0; i < ARRAY_SIZE(formats); i++) {
__DRIconfig **new_configs;
- const int num_depth_stencil_bits = 2;
+ int num_depth_stencil_bits = 2;
/* Starting with DRI2 protocol version 1.1 we can request a depth/stencil
* buffer that has a different number of bits per pixel than the color
- * buffer. This isn't yet supported here.
+ * buffer, gen >= 6 supports this.
*/
depth_bits[0] = 0;
stencil_bits[0] = 0;
@@ -947,6 +947,11 @@ intel_screen_make_configs(__DRIscreen *dri_screen)
if (formats[i] == MESA_FORMAT_RGB565) {
depth_bits[1] = 16;
stencil_bits[1] = 0;
+ if (screen->gen >= 6) {
+ depth_bits[2] = 24;
+ stencil_bits[2] = 8;
+ num_depth_stencil_bits = 3;
+ }
} else {
depth_bits[1] = 24;
stencil_bits[1] = 8;