OSDN Git Service

llvmpipe: Ensure outdated framebuffer state is not reused in lp_setup_bind_framebuffer().
authorJosé Fonseca <jfonseca@vmware.com>
Mon, 28 Jun 2010 15:28:55 +0000 (16:28 +0100)
committerJosé Fonseca <jfonseca@vmware.com>
Mon, 28 Jun 2010 15:33:05 +0000 (16:33 +0100)
commit8be645d53a0d5d0ca50e4e9597043225e2231b6d
treed82cc87218c897005c966f8e181f65114c36e21b
parentce7a70b8b48a4dded9b1e29590b5101dacd56e0b
llvmpipe: Ensure outdated framebuffer state is not reused in lp_setup_bind_framebuffer().

We were starting a scene whenever lp_setup_get_vertex_info() was called by
the draw module. So when when all primitives were culled/clipped, not only
did we create a new scene for nothing, but we end up using the old scene
with the old framebuffer state instead of a new one.

Fix consists in:
- don't call lp_setup_update_state() in lp_setup_get_vertex_info() -- no
  longer necessary
- always setting the scene state before binning a command -- query
  commands were bypassing it
- assert no old scene is reused in lp_setup_bind_framebuffer()
src/gallium/drivers/llvmpipe/lp_setup.c
src/gallium/drivers/llvmpipe/lp_setup_vbuf.c