summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/r600/r600_state.c
diff options
context:
space:
mode:
authorChristian König <[email protected]>2011-08-30 15:43:03 +0200
committerChristian König <[email protected]>2011-09-01 19:20:46 +0200
commit0d0285ba916d9e25871354441c09b0a8c7c9b844 (patch)
tree15f534a5cbf7673c717d93056d59527b01b1ea59 /src/gallium/drivers/r600/r600_state.c
parentcf49c49d0e193143ae497cebd5c91df37ba17c8e (diff)
r600g: add support for R4A4 and A4R4 textures.
Sampling worked out of the box, but this make them work as surface as well. Signed-off-by: Christian König <[email protected]>
Diffstat (limited to 'src/gallium/drivers/r600/r600_state.c')
-rw-r--r--src/gallium/drivers/r600/r600_state.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/r600/r600_state.c b/src/gallium/drivers/r600/r600_state.c
index 326bbff7fa4..1df85fa12e8 100644
--- a/src/gallium/drivers/r600/r600_state.c
+++ b/src/gallium/drivers/r600/r600_state.c
@@ -277,6 +277,7 @@ static uint32_t r600_translate_colorswap(enum pipe_format format)
switch (format) {
/* 8-bit buffers. */
case PIPE_FORMAT_A8_UNORM:
+ case PIPE_FORMAT_R4A4_UNORM:
return V_0280A0_SWAP_ALT_REV;
case PIPE_FORMAT_I8_UNORM:
case PIPE_FORMAT_L8_UNORM:
@@ -286,6 +287,7 @@ static uint32_t r600_translate_colorswap(enum pipe_format format)
return V_0280A0_SWAP_STD;
case PIPE_FORMAT_L4A4_UNORM:
+ case PIPE_FORMAT_A4R4_UNORM:
return V_0280A0_SWAP_ALT;
/* 16-bit buffers. */
@@ -383,6 +385,8 @@ static uint32_t r600_translate_colorformat(enum pipe_format format)
{
switch (format) {
case PIPE_FORMAT_L4A4_UNORM:
+ case PIPE_FORMAT_R4A4_UNORM:
+ case PIPE_FORMAT_A4R4_UNORM:
return V_0280A0_COLOR_4_4;
/* 8-bit buffers. */