diff options
author | Marek Olšák <[email protected]> | 2010-02-05 08:12:01 +0100 |
---|---|---|
committer | Corbin Simpson <[email protected]> | 2010-02-06 23:25:29 -0800 |
commit | 2f5fcce933dd9beb66d2da4c1ca979ccde57483e (patch) | |
tree | a372981ed9454549cb0614123a58762e1542c469 /src/gallium/drivers/r300/r300_context.c | |
parent | c8b34616b345d7a64d39e0ea3d4f4006af0b9740 (diff) |
r300g: make a local copy of framebuffer state
The previous more direct approach was simply incorrect.
piglit/levelclamp passes again.
Diffstat (limited to 'src/gallium/drivers/r300/r300_context.c')
-rw-r--r-- | src/gallium/drivers/r300/r300_context.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/r300/r300_context.c b/src/gallium/drivers/r300/r300_context.c index 9837530a7ac..2df2dcfcad9 100644 --- a/src/gallium/drivers/r300/r300_context.c +++ b/src/gallium/drivers/r300/r300_context.c @@ -55,6 +55,7 @@ static void r300_destroy_context(struct pipe_context* context) FREE(r300->blend_color_state.state); FREE(r300->clip_state.state); + FREE(r300->fb_state.state); FREE(r300->rs_block_state.state); FREE(r300->scissor_state.state); FREE(r300->vertex_format_state.state); @@ -124,6 +125,9 @@ static void r300_setup_atoms(struct r300_context* r300) R300_INIT_ATOM(viewport, 9); R300_INIT_ATOM(rs_block, 21); R300_INIT_ATOM(vertex_format, 26); + + /* Some non-CSO atoms need explicit space to store the state locally. */ + r300->fb_state.state = CALLOC_STRUCT(pipe_framebuffer_state); } struct pipe_context* r300_create_context(struct pipe_screen* screen, |