diff options
author | Stéphane Marchesin <[email protected]> | 2012-02-09 20:39:00 -0800 |
---|---|---|
committer | Stéphane Marchesin <[email protected]> | 2012-02-12 16:32:15 -0800 |
commit | a2caf952a150a8da395f4cf1fd30e8c867b0064e (patch) | |
tree | e9ae4bfc29036a8b1d7ac033bf4770126973c5f5 /src/gallium/drivers/i915/i915_state.c | |
parent | 633f21652aacbcd7eebe28597cac1dc556ea2b45 (diff) |
i915g: Remove useless draw calls.
Diffstat (limited to 'src/gallium/drivers/i915/i915_state.c')
-rw-r--r-- | src/gallium/drivers/i915/i915_state.c | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/src/gallium/drivers/i915/i915_state.c b/src/gallium/drivers/i915/i915_state.c index 02cb3eafa94..f7ebfcdb88b 100644 --- a/src/gallium/drivers/i915/i915_state.c +++ b/src/gallium/drivers/i915/i915_state.c @@ -181,8 +181,6 @@ static void i915_bind_blend_state(struct pipe_context *pipe, if (i915->blend == blend) return; - draw_flush(i915->draw); - i915->blend = (struct i915_blend_state*)blend; i915->dirty |= I915_NEW_BLEND; @@ -202,8 +200,6 @@ static void i915_set_blend_color( struct pipe_context *pipe, if (!blend_color) return; - draw_flush(i915->draw); - i915->blend_color = *blend_color; i915->dirty |= I915_NEW_BLEND; @@ -214,8 +210,6 @@ static void i915_set_stencil_ref( struct pipe_context *pipe, { struct i915_context *i915 = i915_context(pipe); - draw_flush(i915->draw); - i915->stencil_ref = *stencil_ref; i915->dirty |= I915_NEW_DEPTH_STENCIL; @@ -323,8 +317,6 @@ i915_bind_vertex_sampler_states(struct pipe_context *pipe, !memcmp(i915->vertex_samplers, samplers, num_samplers * sizeof(void *))) return; - draw_flush(i915->draw); - for (i = 0; i < num_samplers; ++i) i915->vertex_samplers[i] = samplers[i]; for (i = num_samplers; i < PIPE_MAX_VERTEX_SAMPLERS; ++i) @@ -350,8 +342,6 @@ static void i915_bind_fragment_sampler_states(struct pipe_context *pipe, !memcmp(i915->sampler, sampler, num * sizeof(void *))) return; - draw_flush(i915->draw); - for (i = 0; i < num; ++i) i915->sampler[i] = sampler[i]; for (i = num; i < PIPE_MAX_SAMPLERS; ++i) @@ -540,8 +530,6 @@ static void i915_bind_depth_stencil_state(struct pipe_context *pipe, if (i915->depth_stencil == depth_stencil) return; - draw_flush(i915->draw); - i915->depth_stencil = (const struct i915_depth_stencil_state *)depth_stencil; i915->dirty |= I915_NEW_DEPTH_STENCIL; @@ -559,8 +547,6 @@ static void i915_set_scissor_state( struct pipe_context *pipe, { struct i915_context *i915 = i915_context(pipe); - draw_flush(i915->draw); - memcpy( &i915->scissor, scissor, sizeof(*scissor) ); i915->dirty |= I915_NEW_SCISSOR; } @@ -569,9 +555,6 @@ static void i915_set_scissor_state( struct pipe_context *pipe, static void i915_set_polygon_stipple( struct pipe_context *pipe, const struct pipe_poly_stipple *stipple ) { - struct i915_context *i915 = i915_context(pipe); - - draw_flush(i915->draw); } @@ -604,8 +587,6 @@ i915_fixup_bind_fs_state(struct pipe_context *pipe, void *shader) if (i915->saved_fs == shader) return; - draw_flush(i915->draw); - i915->saved_fs = shader; i915->saved_bind_fs_state(pipe, shader); @@ -619,8 +600,6 @@ i915_bind_fs_state(struct pipe_context *pipe, void *shader) if (i915->fs == shader) return; - draw_flush(i915->draw); - i915->fs = (struct i915_fragment_shader*) shader; draw_bind_fragment_shader(i915->draw, (i915->fs ? i915->fs->draw_data : NULL)); @@ -722,12 +701,6 @@ static void i915_set_constant_buffer(struct pipe_context *pipe, diff = i915->current.num_user_constants[shader] != 0; } - /* - * flush before updateing the state. - */ - if (diff && shader == PIPE_SHADER_FRAGMENT) - draw_flush(i915->draw); - pipe_resource_reference(&i915->constants[shader], buf); i915->current.num_user_constants[shader] = new_num; @@ -771,9 +744,6 @@ static void i915_set_fragment_sampler_views(struct pipe_context *pipe, !memcmp(i915->fragment_sampler_views, views, num * sizeof(struct pipe_sampler_view *))) return; - /* Fixes wrong texture in texobj with VBUF */ - draw_flush(i915->draw); - for (i = 0; i < num; i++) pipe_sampler_view_reference(&i915->fragment_sampler_views[i], views[i]); @@ -803,8 +773,6 @@ i915_set_vertex_sampler_views(struct pipe_context *pipe, return; } - draw_flush(i915->draw); - for (i = 0; i < PIPE_MAX_VERTEX_SAMPLERS; i++) { struct pipe_sampler_view *view = i < num ? views[i] : NULL; @@ -853,8 +821,6 @@ static void i915_set_framebuffer_state(struct pipe_context *pipe, struct i915_context *i915 = i915_context(pipe); int i; - draw_flush(i915->draw); - i915->framebuffer.width = fb->width; i915->framebuffer.height = fb->height; i915->framebuffer.nr_cbufs = fb->nr_cbufs; @@ -874,8 +840,6 @@ static void i915_set_clip_state( struct pipe_context *pipe, { struct i915_context *i915 = i915_context(pipe); - draw_flush(i915->draw); - i915->saved_clip = *clip; draw_set_clip_state(i915->draw, clip); |