summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorNeil Roberts <[email protected]>2015-12-18 12:25:53 +0000
committerEmil Velikov <[email protected]>2015-12-18 12:26:25 +0000
commitb6aeef5e433622f55d0069dbb6c57f0263ef6580 (patch)
treead16f3bbfab16533991e5b154cfef899187b95d1 /src
parent3e1e68f2e17b5ff4eb02504a62405a46521d03d0 (diff)
i965: Add B8G8R8X8_SRGB to the alpha format override
brw_init_surface_formats overrides the render format for RGBX formats which aren't supported for rendering so that they internally use RGBA instead. However, B8G8R8X8_SRGB was missing so it wasn't marked as a renderable format. This patch just adds it. Cc: "11.0 11.1" <[email protected]> Cc: Ilia Mirkin <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]> (cherry picked from commit 43f4be5f06b7a96b96a3a7b43f5112139a1f423a)
Diffstat (limited to 'src')
-rw-r--r--src/mesa/drivers/dri/i965/brw_surface_formats.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_surface_formats.c b/src/mesa/drivers/dri/i965/brw_surface_formats.c
index 7333712d0ef..b5e8edf892e 100644
--- a/src/mesa/drivers/dri/i965/brw_surface_formats.c
+++ b/src/mesa/drivers/dri/i965/brw_surface_formats.c
@@ -615,6 +615,10 @@ brw_init_surface_formats(struct brw_context *brw)
*/
render = BRW_SURFACEFORMAT_B8G8R8A8_UNORM;
break;
+ case BRW_SURFACEFORMAT_B8G8R8X8_UNORM_SRGB:
+ if (gen < tinfo->render_target)
+ render = BRW_SURFACEFORMAT_B8G8R8A8_UNORM_SRGB;
+ break;
case BRW_SURFACEFORMAT_R8G8B8X8_UNORM:
render = BRW_SURFACEFORMAT_R8G8B8A8_UNORM;
break;