i915g: Rename sampler to fragment_sampler

Otherwise it is fairly confusing.
This commit is contained in:
Stéphane Marchesin
2013-10-07 20:49:35 -07:00
parent 8c6594074e
commit 20bf508a42
4 changed files with 9 additions and 9 deletions
+2 -2
View File
@@ -227,8 +227,8 @@ struct i915_context {
/* The most recent drawing state as set by the driver:
*/
const struct i915_blend_state *blend;
const struct i915_sampler_state *sampler[PIPE_MAX_SAMPLERS];
struct pipe_sampler_state *vertex_samplers[PIPE_MAX_SAMPLERS];
const struct i915_sampler_state *fragment_sampler[PIPE_MAX_SAMPLERS];
struct pipe_sampler_state *vertex_samplers[PIPE_MAX_SAMPLERS];
const struct i915_depth_stencil_state *depth_stencil;
const struct i915_rasterizer_state *rasterizer;
+3 -3
View File
@@ -337,17 +337,17 @@ static void i915_bind_fragment_sampler_states(struct pipe_context *pipe,
/* Check for no-op */
if (num == i915->num_samplers &&
!memcmp(i915->sampler + start, samplers,
!memcmp(i915->fragment_sampler + start, samplers,
num * sizeof(void *)))
return;
for (i = 0; i < num; ++i)
i915->sampler[i + start] = samplers[i];
i915->fragment_sampler[i + start] = samplers[i];
/* find highest non-null samplers[] entry */
{
unsigned j = MAX2(i915->num_samplers, start + num);
while (j > 0 && i915->sampler[j - 1] == NULL)
while (j > 0 && i915->fragment_sampler[j - 1] == NULL)
j--;
i915->num_samplers = j;
}
@@ -161,13 +161,13 @@ static void update_samplers(struct i915_context *i915)
update_sampler(i915,
unit,
i915->sampler[unit], /* sampler state */
i915->fragment_sampler[unit], /* sampler state */
texture, /* texture */
i915->current.sampler[unit]); /* the result */
update_map(i915,
unit,
texture, /* texture */
i915->sampler[unit], /* sampler state */
i915->fragment_sampler[unit], /* sampler state */
i915->fragment_sampler_views[unit], /* sampler view */
i915->current.texbuffer[unit]); /* the result */
@@ -357,7 +357,7 @@ static void update_maps(struct i915_context *i915)
update_map(i915,
unit,
texture, /* texture */
i915->sampler[unit], /* sampler state */
i915->fragment_sampler[unit], /* sampler state */
i915->fragment_sampler_views[unit], /* sampler view */
i915->current.texbuffer[unit]);
}
+1 -1
View File
@@ -62,7 +62,7 @@ i915_util_blitter_save_states(struct i915_context *i915)
util_blitter_save_fragment_sampler_states(i915->blitter,
i915->num_samplers,
(void**)i915->sampler);
(void**)i915->fragment_sampler);
util_blitter_save_fragment_sampler_views(i915->blitter,
i915->num_fragment_sampler_views,
i915->fragment_sampler_views);