[Mesa-dev] [PATCH 1/2] radeonsi: Don't advertise PIPE_FORMAT_L8A8_SRGB support.
Michel Dänzer
michel at daenzer.net
Tue Feb 5 09:01:44 PST 2013
From: Michel Dänzer <michel.daenzer at amd.com>
The hardware can't do it.
Signed-off-by: Michel Dänzer <michel.daenzer at amd.com>
---
src/gallium/drivers/radeonsi/si_state.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/gallium/drivers/radeonsi/si_state.c b/src/gallium/drivers/radeonsi/si_state.c
index 6e50832..a58a347 100644
--- a/src/gallium/drivers/radeonsi/si_state.c
+++ b/src/gallium/drivers/radeonsi/si_state.c
@@ -720,7 +720,6 @@ static uint32_t si_translate_colorformat(enum pipe_format format)
case PIPE_FORMAT_L8A8_SNORM:
case PIPE_FORMAT_L8A8_UINT:
case PIPE_FORMAT_L8A8_SINT:
- case PIPE_FORMAT_L8A8_SRGB:
case PIPE_FORMAT_R8G8_SNORM:
case PIPE_FORMAT_R8G8_UNORM:
case PIPE_FORMAT_R8G8_UINT:
@@ -895,7 +894,6 @@ static uint32_t si_translate_colorswap(enum pipe_format format)
case PIPE_FORMAT_L8A8_SNORM:
case PIPE_FORMAT_L8A8_UINT:
case PIPE_FORMAT_L8A8_SINT:
- case PIPE_FORMAT_L8A8_SRGB:
return V_028C70_SWAP_ALT;
case PIPE_FORMAT_R8G8_SNORM:
case PIPE_FORMAT_R8G8_UNORM:
@@ -1169,6 +1167,8 @@ static uint32_t si_translate_texformat(struct pipe_screen *screen,
goto out_unknown; /* TODO */
case UTIL_FORMAT_COLORSPACE_SRGB:
+ if (desc->nr_channels != 4 && desc->nr_channels != 1)
+ goto out_unknown;
break;
default:
--
1.7.10.4
More information about the mesa-dev
mailing list