summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorKristian Høgsberg <[email protected]>2013-09-14 23:28:55 -0700
committerKristian Høgsberg <[email protected]>2013-10-15 22:07:52 -0700
commitf354bcc1770e9df88db51eba5a4543a09ca6d128 (patch)
treec7e2fcea91e90df5b8604f967c58d2dd19f3adc7 /src/mesa
parentafda76cc0d18f7c1bc585c3457a0ad58c13b71ca (diff)
i965: Create ARGB2101010 DRI configs
This commit enables ARGB2101010 system framebuffers (that is, DRI drawables) for the i965 drivers. This is done by generating DRI configs that advertise this color format as well as teaching intelCreateBuffer to pick the right color format when it sees such a DRI config. Signed-off-by: Kristian Høgsberg <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/i965/intel_screen.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/drivers/dri/i965/intel_screen.c
index 5ec2dc4afc1..2912291cfd0 100644
--- a/src/mesa/drivers/dri/i965/intel_screen.c
+++ b/src/mesa/drivers/dri/i965/intel_screen.c
@@ -911,6 +911,8 @@ intelCreateBuffer(__DRIscreen * driScrnPriv,
if (mesaVis->redBits == 5)
rgbFormat = MESA_FORMAT_RGB565;
+ else if (mesaVis->redBits == 10)
+ rgbFormat = MESA_FORMAT_ARGB2101010;
else if (mesaVis->sRGBCapable)
rgbFormat = MESA_FORMAT_SARGB8;
else if (mesaVis->alphaBits == 0)
@@ -1040,7 +1042,8 @@ intel_screen_make_configs(__DRIscreen *dri_screen)
{
static const gl_format formats[] = {
MESA_FORMAT_RGB565,
- MESA_FORMAT_ARGB8888
+ MESA_FORMAT_ARGB8888,
+ MESA_FORMAT_ARGB2101010
};
/* GLX_SWAP_COPY_OML is not supported due to page flipping. */