From 34dc4d6b67529cd65e744c4ac487d7700cd633da Mon Sep 17 00:00:00 2001 From: Marek Olšák Date: Wed, 13 Feb 2013 18:11:48 +0100 Subject: r600g: add support for red-alpha render targets --- src/gallium/drivers/r600/evergreen_state.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'src/gallium/drivers/r600/evergreen_state.c') diff --git a/src/gallium/drivers/r600/evergreen_state.c b/src/gallium/drivers/r600/evergreen_state.c index 4d34d8ba1dd..ad0a62e968a 100644 --- a/src/gallium/drivers/r600/evergreen_state.c +++ b/src/gallium/drivers/r600/evergreen_state.c @@ -292,6 +292,18 @@ static uint32_t r600_translate_colorswap(enum pipe_format format) case PIPE_FORMAT_L32A32_UINT: case PIPE_FORMAT_L32A32_SINT: case PIPE_FORMAT_L32A32_FLOAT: + case PIPE_FORMAT_R8A8_UNORM: + case PIPE_FORMAT_R8A8_SNORM: + case PIPE_FORMAT_R8A8_UINT: + case PIPE_FORMAT_R8A8_SINT: + case PIPE_FORMAT_R16A16_UNORM: + case PIPE_FORMAT_R16A16_SNORM: + case PIPE_FORMAT_R16A16_UINT: + case PIPE_FORMAT_R16A16_SINT: + case PIPE_FORMAT_R16A16_FLOAT: + case PIPE_FORMAT_R32A32_UINT: + case PIPE_FORMAT_R32A32_SINT: + case PIPE_FORMAT_R32A32_FLOAT: return V_028C70_SWAP_ALT; case PIPE_FORMAT_R8G8_UNORM: case PIPE_FORMAT_R8G8_SNORM: @@ -445,6 +457,10 @@ static uint32_t r600_translate_colorformat(enum pipe_format format) case PIPE_FORMAT_R8G8_SNORM: case PIPE_FORMAT_R8G8_UINT: case PIPE_FORMAT_R8G8_SINT: + case PIPE_FORMAT_R8A8_UNORM: + case PIPE_FORMAT_R8A8_SNORM: + case PIPE_FORMAT_R8A8_UINT: + case PIPE_FORMAT_R8A8_SINT: return V_028C70_COLOR_8_8; case PIPE_FORMAT_R16_UNORM: @@ -531,6 +547,7 @@ static uint32_t r600_translate_colorformat(enum pipe_format format) case PIPE_FORMAT_R16G16_FLOAT: case PIPE_FORMAT_L16A16_FLOAT: + case PIPE_FORMAT_R16A16_FLOAT: return V_028C70_COLOR_16_16_FLOAT; case PIPE_FORMAT_R16G16_UNORM: @@ -541,6 +558,10 @@ static uint32_t r600_translate_colorformat(enum pipe_format format) case PIPE_FORMAT_L16A16_SNORM: case PIPE_FORMAT_L16A16_UINT: case PIPE_FORMAT_L16A16_SINT: + case PIPE_FORMAT_R16A16_UNORM: + case PIPE_FORMAT_R16A16_SNORM: + case PIPE_FORMAT_R16A16_UINT: + case PIPE_FORMAT_R16A16_SINT: return V_028C70_COLOR_16_16; case PIPE_FORMAT_R11G11B10_FLOAT: @@ -563,6 +584,7 @@ static uint32_t r600_translate_colorformat(enum pipe_format format) case PIPE_FORMAT_R32G32_FLOAT: case PIPE_FORMAT_L32A32_FLOAT: + case PIPE_FORMAT_R32A32_FLOAT: return V_028C70_COLOR_32_32_FLOAT; case PIPE_FORMAT_R32G32_SINT: -- cgit v1.2.3