summaryrefslogtreecommitdiffstats
path: root/src/glsl/ir_clone.cpp
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2012-03-24 13:33:41 +0000
committerDave Airlie <airlied@redhat.com>2012-04-13 17:19:01 +0100
commit1256a5dcc86014d48bdc6fd10ea5a2fa11241667 (patch)
tree8739552f09debe93734d1b338ac0e2787fc8a80f /src/glsl/ir_clone.cpp
parentf8cf79936b42405a8366613b80e3bde21aadaa02 (diff)
downloadexternal_mesa3d-1256a5dcc86014d48bdc6fd10ea5a2fa11241667.zip
external_mesa3d-1256a5dcc86014d48bdc6fd10ea5a2fa11241667.tar.gz
external_mesa3d-1256a5dcc86014d48bdc6fd10ea5a2fa11241667.tar.bz2
glsl: add support for ARB_blend_func_extended (v3)
This adds index support to the GLSL compiler. I'm not 100% sure of my approach here, esp without how output ordering happens wrt location, index pairs, in the "mark" function. Since current hw doesn't ever have a location > 0 with an index > 0, we don't have to work out if the output ordering the hw requires is location, index, location, index or location, location, index, index. But we have no hw to know, so punt on it for now. v2: index requires layout - catch and error setup explicit index properly. v3: drop idx_offset stuff, assume index follow location Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'src/glsl/ir_clone.cpp')
-rw-r--r--src/glsl/ir_clone.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/glsl/ir_clone.cpp b/src/glsl/ir_clone.cpp
index 26b0d8f..5a7a71c 100644
--- a/src/glsl/ir_clone.cpp
+++ b/src/glsl/ir_clone.cpp
@@ -57,6 +57,7 @@ ir_variable::clone(void *mem_ctx, struct hash_table *ht) const
var->origin_upper_left = this->origin_upper_left;
var->pixel_center_integer = this->pixel_center_integer;
var->explicit_location = this->explicit_location;
+ var->explicit_index = this->explicit_index;
var->has_initializer = this->has_initializer;
var->depth_layout = this->depth_layout;
@@ -74,6 +75,9 @@ ir_variable::clone(void *mem_ctx, struct hash_table *ht) const
if (this->explicit_location)
var->location = this->location;
+ if (this->explicit_index)
+ var->index = this->index;
+
if (this->constant_value)
var->constant_value = this->constant_value->clone(mem_ctx, ht);