diff options
author | Chris Forbes <chrisf@ijw.co.nz> | 2013-09-25 16:56:36 +1200 |
---|---|---|
committer | Chris Forbes <chrisf@ijw.co.nz> | 2013-10-03 07:56:02 +1300 |
commit | 36e25ccd29056d965612523f82d973b43b85313e (patch) | |
tree | 31a6e24ddd3236132e7a505ccd474e4e518d3b8f /src/glsl | |
parent | 4ed3930f9741721f4ace2d008678c0c88fdcc501 (diff) | |
download | external_mesa3d-36e25ccd29056d965612523f82d973b43b85313e.zip external_mesa3d-36e25ccd29056d965612523f82d973b43b85313e.tar.gz external_mesa3d-36e25ccd29056d965612523f82d973b43b85313e.tar.bz2 |
glsl: flag shaders which use gather4 at all
Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Diffstat (limited to 'src/glsl')
-rw-r--r-- | src/glsl/ir_set_program_inouts.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/glsl/ir_set_program_inouts.cpp b/src/glsl/ir_set_program_inouts.cpp index 1267d6d..ab23538 100644 --- a/src/glsl/ir_set_program_inouts.cpp +++ b/src/glsl/ir_set_program_inouts.cpp @@ -59,6 +59,7 @@ public: virtual ir_visitor_status visit_enter(ir_function_signature *); virtual ir_visitor_status visit_enter(ir_expression *); virtual ir_visitor_status visit_enter(ir_discard *); + virtual ir_visitor_status visit_enter(ir_texture *); virtual ir_visitor_status visit(ir_dereference_variable *); private: @@ -319,6 +320,14 @@ ir_set_program_inouts_visitor::visit_enter(ir_discard *) return visit_continue; } +ir_visitor_status +ir_set_program_inouts_visitor::visit_enter(ir_texture *ir) +{ + if (ir->op == ir_tg4) + prog->UsesGather = true; + return visit_continue; +} + void do_set_program_inouts(exec_list *instructions, struct gl_program *prog, GLenum shader_type) |