projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
568b477
)
nv30: Reemit state when changing context
author
Patrice Mandin
<pmandin@caramail.com>
Thu, 3 Jul 2008 20:47:15 +0000
(22:47 +0200)
committer
Patrice Mandin
<pmandin@caramail.com>
Thu, 3 Jul 2008 20:47:15 +0000
(22:47 +0200)
src/gallium/drivers/nv30/nv30_state_emit.c
patch
|
blob
|
history
diff --git
a/src/gallium/drivers/nv30/nv30_state_emit.c
b/src/gallium/drivers/nv30/nv30_state_emit.c
index cb7f1a7c310dd069ccaacdbfe03573186e7e0d73..eca1f0652cc68ed185e81618137d4d8aec10eb72 100644
(file)
--- a/
src/gallium/drivers/nv30/nv30_state_emit.c
+++ b/
src/gallium/drivers/nv30/nv30_state_emit.c
@@
-46,9
+46,19
@@
void
nv30_emit_hw_state(struct nv30_context *nv30)
{
struct nv30_state *state = &nv30->state;
+ struct nv30_screen *screen = nv30->screen;
unsigned i;
uint64 states;
+ if (nv30->pctx_id != screen->cur_pctx) {
+ for (i = 0; i < NV30_STATE_MAX; i++) {
+ if (state->hw[i] && screen->state[i] != state->hw[i])
+ state->dirty |= (1ULL << i);
+ }
+
+ screen->cur_pctx = nv30->pctx_id;
+ }
+
for (i = 0, states = state->dirty; states; i++) {
if (!(states & (1ULL << i)))
continue;