[Mesa-dev] [PATCH 04/10] i965/gen4: Use tex object format instead of the miptree format

Topi Pohjolainen topi.pohjolainen at intel.com
Wed Jul 1 04:46:34 PDT 2015


Equivalent logic for newer generations (>= 7) use the tex object
format instead. This patch prepares for merging the decision
making for all generations.

Signed-off-by: Topi Pohjolainen <topi.pohjolainen at intel.com>
---
 src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/drivers/dri/i965/brw_wm_surface_state.c b/src/mesa/drivers/dri/i965/brw_wm_surface_state.c
index dca67e8..26e9122 100644
--- a/src/mesa/drivers/dri/i965/brw_wm_surface_state.c
+++ b/src/mesa/drivers/dri/i965/brw_wm_surface_state.c
@@ -322,7 +322,7 @@ brw_update_texture_surface(struct gl_context *ctx,
    surf = brw_state_batch(brw, AUB_TRACE_SURFACE_STATE,
 			  6 * 4, 32, surf_offset);
 
-   uint32_t tex_format = translate_tex_format(brw, mt->format,
+   uint32_t tex_format = translate_tex_format(brw, intelObj->_Format,
                                               sampler->sRGBDecode);
 
    if (for_gather) {
-- 
1.9.3



More information about the mesa-dev mailing list