[Mesa-dev] [PATCH 1/2] i965: use _mesa_tex_target_is_array instead of _mesa_is_array_texture

Alejandro PiƱeiro apinheiro at igalia.com
Sat Dec 5 10:47:23 PST 2015


Both methods provide the same functionality, so one would be
removed. _mesa_tex_target_is_array is the older one.
---
 src/mesa/drivers/dri/i965/gen7_wm_surface_state.c | 2 +-
 src/mesa/drivers/dri/i965/gen8_surface_state.c    | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/gen7_wm_surface_state.c b/src/mesa/drivers/dri/i965/gen7_wm_surface_state.c
index 2aa395b..dc2e90b 100644
--- a/src/mesa/drivers/dri/i965/gen7_wm_surface_state.c
+++ b/src/mesa/drivers/dri/i965/gen7_wm_surface_state.c
@@ -294,7 +294,7 @@ gen7_emit_texture_surface_state(struct brw_context *brw,
    if (mt->halign == 8)
       surf[0] |= GEN7_SURFACE_HALIGN_8;
 
-   if (_mesa_is_array_texture(target) || target == GL_TEXTURE_CUBE_MAP)
+   if (_mesa_tex_target_is_array(target) || target == GL_TEXTURE_CUBE_MAP)
       surf[0] |= GEN7_SURFACE_IS_ARRAY;
 
    if (mt->array_layout == ALL_SLICES_AT_EACH_LOD)
diff --git a/src/mesa/drivers/dri/i965/gen8_surface_state.c b/src/mesa/drivers/dri/i965/gen8_surface_state.c
index 80252a5..86f7b02 100644
--- a/src/mesa/drivers/dri/i965/gen8_surface_state.c
+++ b/src/mesa/drivers/dri/i965/gen8_surface_state.c
@@ -273,7 +273,7 @@ gen8_emit_texture_surface_state(struct brw_context *brw,
         format == BRW_SURFACEFORMAT_BC7_UNORM))
       surf[0] |= GEN8_SURFACE_SAMPLER_L2_BYPASS_DISABLE;
 
-   if (_mesa_is_array_texture(target) || target == GL_TEXTURE_CUBE_MAP)
+   if (_mesa_tex_target_is_array(target) || target == GL_TEXTURE_CUBE_MAP)
       surf[0] |= GEN8_SURFACE_IS_ARRAY;
 
    surf[1] = SET_FIELD(mocs_wb, GEN8_SURFACE_MOCS) | mt->qpitch >> 2;
-- 
2.1.4



More information about the mesa-dev mailing list