summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/softpipe/sp_state.h
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2010-09-17 18:41:30 -0600
committerBrian Paul <[email protected]>2010-09-17 18:45:13 -0600
commite22e3927b056806e9bbb089734132ad0bcb98df1 (patch)
tree54e1a8fcdec93e315f9c04afefadedd43cc7877d /src/gallium/drivers/softpipe/sp_state.h
parent49cb978aa46af0d86ab609013d7883c8105a6d1d (diff)
gallium: rework handling of sprite_coord_enable state
Implement the pipe_rasterizer_state::sprite_coord_enable field in the draw module (and softpipe) according to what's specified in the documentation. The draw module can now add any number of extra vertex attributes to a post-transformed vertex and generate texcoords for those attributes per sprite_coord_enable. Auto-generated texcoords for sprites only worked for one texcoord unit before. The frag shader gl_PointCoord input is now implemented like any other generic/texcoord attribute. The draw module now needs to be informed about fragment shaders since we need to look at the fragment shader's inputs to know which ones need auto-generated texcoords. Only softpipe has been updated so far.
Diffstat (limited to 'src/gallium/drivers/softpipe/sp_state.h')
-rw-r--r--src/gallium/drivers/softpipe/sp_state.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gallium/drivers/softpipe/sp_state.h b/src/gallium/drivers/softpipe/sp_state.h
index 39d204de8a9..c5d61f840f2 100644
--- a/src/gallium/drivers/softpipe/sp_state.h
+++ b/src/gallium/drivers/softpipe/sp_state.h
@@ -70,6 +70,8 @@ struct sp_fragment_shader {
struct tgsi_shader_info info;
+ struct draw_fragment_shader *draw_shader;
+
boolean origin_lower_left; /**< fragment shader uses lower left position origin? */
boolean pixel_center_integer; /**< fragment shader uses integer pixel center? */