for (i = 0; i < r300->sampler_count; i++) {
if (r300->dirty_state & (R300_NEW_SAMPLER << i)) {
r300_emit_sampler(r300, r300->sampler_states[i], i);
- r300->dirty_state &= ~(R300_NEW_SAMPLER << i);
dirty_tex++;
}
}
+ r300->dirty_state &= ~R300_ANY_NEW_SAMPLERS;
}
if (r300->dirty_state & R300_NEW_SCISSOR) {
for (i = 0; i < r300->texture_count; i++) {
if (r300->dirty_state & (R300_NEW_TEXTURE << i)) {
r300_emit_texture(r300, r300->textures[i], i);
- r300->dirty_state &= ~(R300_NEW_TEXTURE << i);
dirty_tex++;
}
}
+ r300->dirty_state &= ~R300_ANY_NEW_TEXTURES;
}
if (r300->dirty_state & R300_NEW_VIEWPORT) {
r300->dirty_state &= ~R300_NEW_VERTEX_SHADER;
}
+ assert(r300->dirty_state == 0);
+
/* Finally, emit the VBO. */
r300_emit_vertex_buffer(r300);