Mesa (master): i915g: Enable mirror repeat wrap mode

Jakob Bornecrantz wallbraker at kemper.freedesktop.org
Thu Feb 24 00:31:23 UTC 2011


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

Author: Jakob Bornecrantz <wallbraker at gmail.com>
Date:   Wed Feb 23 00:11:09 2011 +0000

i915g: Enable mirror repeat wrap mode

---

 src/gallium/drivers/i915/TODO          |    4 ++--
 src/gallium/drivers/i915/i915_screen.c |    2 +-
 src/gallium/drivers/i915/i915_state.c  |    4 +---
 3 files changed, 4 insertions(+), 6 deletions(-)

diff --git a/src/gallium/drivers/i915/TODO b/src/gallium/drivers/i915/TODO
index eda5838..fc644fe 100644
--- a/src/gallium/drivers/i915/TODO
+++ b/src/gallium/drivers/i915/TODO
@@ -1,7 +1,7 @@
 Random list of problems with i915g:
 
-- Check if PIPE_CAP_BLEND_EQUATION_SEPARATE and PIPE_CAP_TEXTURE_MIRROR_REPEAT
-  work, the code is there. If not fix it! A simple task, good for beginners.
+- Check if PIPE_CAP_BLEND_EQUATION_SEPARATE work, the code is there.
+  If not fix it! A simple task, good for beginners.
 
 - Add support for PIPE_CAP_POINT_SPRITE either via the draw module or directly
   via the hardware, look at the classic driver, more advanced.
diff --git a/src/gallium/drivers/i915/i915_screen.c b/src/gallium/drivers/i915/i915_screen.c
index d929eb2..77febbf 100644
--- a/src/gallium/drivers/i915/i915_screen.c
+++ b/src/gallium/drivers/i915/i915_screen.c
@@ -107,6 +107,7 @@ i915_get_param(struct pipe_screen *screen, enum pipe_cap cap)
    case PIPE_CAP_ANISOTROPIC_FILTER:
    case PIPE_CAP_NPOT_TEXTURES:
    case PIPE_CAP_PRIMITIVE_RESTART: /* draw module */
+   case PIPE_CAP_TEXTURE_MIRROR_REPEAT:
    case PIPE_CAP_TEXTURE_SHADOW_MAP:
    case PIPE_CAP_TWO_SIDED_STENCIL:
       return 1;
@@ -114,7 +115,6 @@ i915_get_param(struct pipe_screen *screen, enum pipe_cap cap)
    /* Features that should be supported (boolean caps). */
    /* XXX: Just test the code */
    case PIPE_CAP_BLEND_EQUATION_SEPARATE:
-   case PIPE_CAP_TEXTURE_MIRROR_REPEAT:
       return 0;
 
    /* Unsupported features (boolean caps). */
diff --git a/src/gallium/drivers/i915/i915_state.c b/src/gallium/drivers/i915/i915_state.c
index f380708..58bbbd1 100644
--- a/src/gallium/drivers/i915/i915_state.c
+++ b/src/gallium/drivers/i915/i915_state.c
@@ -58,10 +58,8 @@ translate_wrap_mode(unsigned wrap)
       return TEXCOORDMODE_CLAMP_EDGE;
    case PIPE_TEX_WRAP_CLAMP_TO_BORDER:
       return TEXCOORDMODE_CLAMP_BORDER;
-   /*         
-   case PIPE_TEX_WRAP_MIRRORED_REPEAT:
+   case PIPE_TEX_WRAP_MIRROR_REPEAT:
       return TEXCOORDMODE_MIRROR;
-    */
    default:
       return TEXCOORDMODE_WRAP;
    }




More information about the mesa-commit mailing list