Commit Graph

4 Commits

Author SHA1 Message Date
Kenneth Graunke
1e3bcbdf31 glsl: Add a new ir_txs (textureSize) opcode to ir_texture.
One unique aspect of TXS is that it doesn't have a coordinate.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
2011-08-23 11:16:30 -07:00
Kenneth Graunke
c5a27b5939 glsl: Change texel offsets to a single vector rvalue.
Having these as actual integer values makes it difficult to implement
the texture*Offset built-in functions, since the offset is actually a
function parameter (which doesn't have a constant value).

The original rationale was that some hardware needs these offset baked
into the instruction opcode.  However, at least i965 should be able to
support non-constant offsets.  Others should be able to rely on inlining
and constant propagation.
2011-01-31 11:10:59 -08:00
Ian Romanick
c8ee8e07f7 glsl2: Set a flag when visiting the assignee of an assignment 2010-09-03 11:55:21 -07:00
Eric Anholt
b3b0cf6a4c glsl2: Add a generic visitor class to call back with pointers to each rvalue.
I keep copy and pasting this code all over, so consolidate it in one
place.
2010-08-13 17:54:46 -07:00