Mesa (master): r600g: fix warnings with piglit texture-rg test.

Dave Airlie airlied at kemper.freedesktop.org
Tue Apr 19 01:41:33 PDT 2011


Module: Mesa
Branch: master
Commit: c98fa6be4bacea22e0310e7f0e447d4eaa2a78e9
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=c98fa6be4bacea22e0310e7f0e447d4eaa2a78e9

Author: Dave Airlie <airlied at redhat.com>
Date:   Tue Apr 19 18:44:43 2011 +1000

r600g: fix warnings with piglit texture-rg test.

Fill in the swaps for the formats to fix warnings.

Signed-off-by: Dave Airlie <airlied at redhat.com>

---

 src/gallium/drivers/r600/eg_state_inlines.h   |    3 +++
 src/gallium/drivers/r600/r600_state_inlines.h |    3 +++
 2 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/src/gallium/drivers/r600/eg_state_inlines.h b/src/gallium/drivers/r600/eg_state_inlines.h
index cae3888..627dcb8 100644
--- a/src/gallium/drivers/r600/eg_state_inlines.h
+++ b/src/gallium/drivers/r600/eg_state_inlines.h
@@ -367,10 +367,13 @@ static inline uint32_t r600_translate_colorswap(enum pipe_format format)
 	case PIPE_FORMAT_B10G10R10A2_UNORM:
 		return V_028C70_SWAP_ALT;
 
+	case PIPE_FORMAT_R32_FLOAT:
+	case PIPE_FORMAT_R16G16_FLOAT:
 	case PIPE_FORMAT_R16G16_UNORM:
 		return V_028C70_SWAP_STD;
 
 		/* 64-bit buffers. */
+	case PIPE_FORMAT_R32G32_FLOAT:
 	case PIPE_FORMAT_R16G16B16A16_UNORM:
 	case PIPE_FORMAT_R16G16B16A16_SNORM:
 	case PIPE_FORMAT_R16G16B16A16_FLOAT:
diff --git a/src/gallium/drivers/r600/r600_state_inlines.h b/src/gallium/drivers/r600/r600_state_inlines.h
index 3d03604..ebb372b 100644
--- a/src/gallium/drivers/r600/r600_state_inlines.h
+++ b/src/gallium/drivers/r600/r600_state_inlines.h
@@ -362,9 +362,12 @@ static inline uint32_t r600_translate_colorswap(enum pipe_format format)
 		return V_0280A0_SWAP_ALT;
 
 	case PIPE_FORMAT_R16G16_UNORM:
+	case PIPE_FORMAT_R16G16_FLOAT:
+	case PIPE_FORMAT_R32_FLOAT:
 		return V_0280A0_SWAP_STD;
 
 		/* 64-bit buffers. */
+	case PIPE_FORMAT_R32G32_FLOAT:
 	case PIPE_FORMAT_R16G16B16A16_UNORM:
 	case PIPE_FORMAT_R16G16B16A16_SNORM:
 	case PIPE_FORMAT_R16G16B16A16_FLOAT:



More information about the mesa-commit mailing list