diff options
author | Luca Barbieri <[email protected]> | 2010-02-23 16:48:22 +0100 |
---|---|---|
committer | Luca Barbieri <[email protected]> | 2010-04-12 12:21:25 +0200 |
commit | 330925d9118120863f5e76e01fdfa1a1f44be2b1 (patch) | |
tree | feb63f5237b7d1cc2cd8ff8a0f3f90774c030cb9 /src/gallium/drivers/nvfx/nvfx_draw.c | |
parent | 26e40448becb07e292d269dc4d8fbc56caebba3c (diff) |
nvfx: rework validation logic to use code and avoid stateobjs
This makes the code faster due to the lack of indirect calls and also
makes it much easier to understand what is actually going on.
Diffstat (limited to 'src/gallium/drivers/nvfx/nvfx_draw.c')
-rw-r--r-- | src/gallium/drivers/nvfx/nvfx_draw.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/src/gallium/drivers/nvfx/nvfx_draw.c b/src/gallium/drivers/nvfx/nvfx_draw.c index 06f5dc39063..2003be10204 100644 --- a/src/gallium/drivers/nvfx/nvfx_draw.c +++ b/src/gallium/drivers/nvfx/nvfx_draw.c @@ -303,8 +303,8 @@ emit_attrib(struct nvfx_context *nvfx, unsigned hw, unsigned emit, nvfx->swtnl.draw[a] = draw_out; } -static boolean -nvfx_state_vtxfmt_validate(struct nvfx_context *nvfx) +void +nvfx_vtxfmt_validate(struct nvfx_context *nvfx) { struct nvfx_fragment_program *fp = nvfx->fragprog; unsigned colour = 0, texcoords = 0, fog = 0, i; @@ -348,14 +348,4 @@ nvfx_state_vtxfmt_validate(struct nvfx_context *nvfx) } emit_attrib(nvfx, 0, 0xff, TGSI_SEMANTIC_POSITION, 0); - - return FALSE; } - -struct nvfx_state_entry nvfx_state_vtxfmt = { - .validate = nvfx_state_vtxfmt_validate, - .dirty = { - .pipe = NVFX_NEW_ARRAYS | NVFX_NEW_FRAGPROG, - .hw = 0 - } -}; |