Note: As far as I know, this is currently dead code: For glsl shaders the glsl IR to Mesa gl_program converter adds a mov instruction for all texture fetch coordinates that isn't removed by Mesa's IR code optimizations in case of relative addressing. ARB_fragment_program doesn't support relative addressing. ARB_vertex_program doesn't support texture fetches.
From ababc239f468c3e202bb7ee93c4b8015798c5ca8 Mon Sep 17 00:00:00 2001 From: Fabian Bieler <[email protected]> Date: Wed, 23 Mar 2011 23:27:01 +0100 Subject: [PATCH 3/3] r600g: Handle texture fetch instructions with relative addressing --- src/gallium/drivers/r600/r600_shader.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/src/gallium/drivers/r600/r600_shader.c b/src/gallium/drivers/r600/r600_shader.c index 14620bd..58c0d29 100644 --- a/src/gallium/drivers/r600/r600_shader.c +++ b/src/gallium/drivers/r600/r600_shader.c @@ -1721,6 +1721,7 @@ static int tgsi_tex(struct r600_shader_ctx *ctx) tex.src_sel_y = ctx->src[0].swizzle[1]; tex.src_sel_z = ctx->src[0].swizzle[2]; tex.src_sel_w = ctx->src[0].swizzle[3]; + tex.src_rel = ctx->src[0].rel; } if (inst->Texture.Texture == TGSI_TEXTURE_CUBE) { -- 1.7.4.1
_______________________________________________ mesa-dev mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/mesa-dev
