[Mesa-dev] [PATCH 06/11] i965: Sync brw_format_for_mesa_format() table with new Mesa formats.

Eric Anholt eric at anholt.net
Tue Apr 16 17:21:18 PDT 2013


I'm not filling them all in, to prevent any breakage in this commit.
---
 src/mesa/drivers/dri/i965/brw_wm_surface_state.c |   32 +++++++++++++++++++++-
 1 file changed, 31 insertions(+), 1 deletion(-)

diff --git a/src/mesa/drivers/dri/i965/brw_wm_surface_state.c b/src/mesa/drivers/dri/i965/brw_wm_surface_state.c
index 7abe587..b711cbb 100644
--- a/src/mesa/drivers/dri/i965/brw_wm_surface_state.c
+++ b/src/mesa/drivers/dri/i965/brw_wm_surface_state.c
@@ -405,7 +405,6 @@ brw_format_for_mesa_format(gl_format mesa_format)
       [MESA_FORMAT_GR1616] = BRW_SURFACEFORMAT_R16G16_UNORM,
       [MESA_FORMAT_RG1616] = 0,
       [MESA_FORMAT_ARGB2101010] = BRW_SURFACEFORMAT_B10G10R10A2_UNORM,
-      [MESA_FORMAT_ABGR2101010_UINT] = BRW_SURFACEFORMAT_R10G10B10A2_UINT,
       [MESA_FORMAT_Z24_S8] = 0,
       [MESA_FORMAT_S8_Z24] = 0,
       [MESA_FORMAT_Z16] = 0,
@@ -524,6 +523,18 @@ brw_format_for_mesa_format(gl_format mesa_format)
       [MESA_FORMAT_LA_LATC2] = 0,
       [MESA_FORMAT_SIGNED_LA_LATC2] = 0,
 
+      [MESA_FORMAT_ETC1_RGB8] = 0,
+      [MESA_FORMAT_ETC2_RGB8] = 0,
+      [MESA_FORMAT_ETC2_SRGB8] = 0,
+      [MESA_FORMAT_ETC2_RGBA8_EAC] = 0,
+      [MESA_FORMAT_ETC2_SRGB8_ALPHA8_EAC] = 0,
+      [MESA_FORMAT_ETC2_R11_EAC] = 0,
+      [MESA_FORMAT_ETC2_RG11_EAC] = 0,
+      [MESA_FORMAT_ETC2_SIGNED_R11_EAC] = 0,
+      [MESA_FORMAT_ETC2_SIGNED_RG11_EAC] = 0,
+      [MESA_FORMAT_ETC2_RGB8_PUNCHTHROUGH_ALPHA1] = 0,
+      [MESA_FORMAT_ETC2_SRGB8_PUNCHTHROUGH_ALPHA1] = 0,
+
       [MESA_FORMAT_SIGNED_A8] = 0,
       [MESA_FORMAT_SIGNED_L8] = 0,
       [MESA_FORMAT_SIGNED_AL88] = 0,
@@ -538,6 +549,25 @@ brw_format_for_mesa_format(gl_format mesa_format)
 
       [MESA_FORMAT_Z32_FLOAT] = 0,
       [MESA_FORMAT_Z32_FLOAT_X24S8] = 0,
+
+      [MESA_FORMAT_ARGB2101010_UINT] = 0,
+      [MESA_FORMAT_ABGR2101010_UINT] = BRW_SURFACEFORMAT_R10G10B10A2_UINT,
+
+      [MESA_FORMAT_XRGB4444_UNORM] = 0,
+      [MESA_FORMAT_XRGB1555_UNORM] = 0,
+      [MESA_FORMAT_XBGR8888_SNORM] = 0,
+      [MESA_FORMAT_XBGR8888_SRGB] = 0,
+      [MESA_FORMAT_XBGR8888_UINT] = 0,
+      [MESA_FORMAT_XBGR8888_SINT] = 0,
+      [MESA_FORMAT_XRGB2101010_UNORM] = 0,
+      [MESA_FORMAT_XBGR16161616_UNORM] = 0,
+      [MESA_FORMAT_XBGR16161616_SNORM] = 0,
+      [MESA_FORMAT_XBGR16161616_FLOAT] = 0,
+      [MESA_FORMAT_XBGR16161616_UINT] = 0,
+      [MESA_FORMAT_XBGR16161616_SINT] = 0,
+      [MESA_FORMAT_XBGR32323232_FLOAT] = 0,
+      [MESA_FORMAT_XBGR32323232_UINT] = 0,
+      [MESA_FORMAT_XBGR32323232_SINT] = 0,
    };
    assert(mesa_format < MESA_FORMAT_COUNT);
    return table[mesa_format];
-- 
1.7.10.4



More information about the mesa-dev mailing list