summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/r600/r600_pipe.h
diff options
context:
space:
mode:
authorVadim Girlin <[email protected]>2011-11-04 21:24:03 +0400
committerAlex Deucher <[email protected]>2011-11-05 17:23:29 -0400
commite532c710c60f0895e32af6562ac2855aa7d5eb63 (patch)
tree3356f91b417695a4da1a84d8348df1b923e28fd4 /src/gallium/drivers/r600/r600_pipe.h
parent5b27b63de64167a84a03d820550e56c4b7bbc69d (diff)
r600g: move SPI setup to PS setup
SPI semantic indices for PS/VS are now static, so we don't need to update spi config for every shaders combination. We can move the functionality of r600_spi_update to r600(evergreen)_pipe_shader_ps. Flatshade state is now controlled by the global FLAT_SHADE_ENA flag instead of updating FLAT_SHADE for all inputs. Sprite coord still requires the update of spi setup when sprite_coord_enable is first changed from zero (enabled), and then only when it's changed to other non-zero value (enabled for other input). Change to zero (disabling) and back to the same value is handled via global SPRITE_COORD_ENA. New field "sprite_coord_enable" added to "struct r600_pipe_shader" to track current state for the pixel shader. It's checked in the r600_update_derived_state. Signed-off-by: Vadim Girlin <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'src/gallium/drivers/r600/r600_pipe.h')
-rw-r--r--src/gallium/drivers/r600/r600_pipe.h4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/gallium/drivers/r600/r600_pipe.h b/src/gallium/drivers/r600/r600_pipe.h
index 330e3202bab..92cb34dacad 100644
--- a/src/gallium/drivers/r600/r600_pipe.h
+++ b/src/gallium/drivers/r600/r600_pipe.h
@@ -68,7 +68,6 @@ enum r600_pipe_state_id {
R600_PIPE_STATE_RESOURCE,
R600_PIPE_STATE_POLYGON_OFFSET,
R600_PIPE_STATE_FETCH_SHADER,
- R600_PIPE_STATE_SPI,
R600_PIPE_NSTATES
};
@@ -133,6 +132,7 @@ struct r600_pipe_shader {
struct r600_resource *bo_fetch;
struct r600_vertex_element vertex_elements;
struct tgsi_token *tokens;
+ unsigned sprite_coord_enable;
};
struct r600_pipe_sampler_state {
@@ -215,9 +215,7 @@ struct r600_pipe_context {
/* shader information */
boolean clamp_vertex_color;
boolean clamp_fragment_color;
- boolean spi_dirty;
unsigned sprite_coord_enable;
- boolean flatshade;
boolean export_16bpc;
unsigned alpha_ref;
boolean alpha_ref_dirty;