mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 11:18:08 +02:00
r600: Cleanup constant buffers on context destruction
CC: <mesa-stable@lists.freedesktop.org> Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu> Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
parent
b6648798cf
commit
a1e8fcce3e
1 changed files with 5 additions and 1 deletions
|
|
@ -65,7 +65,7 @@ static const struct debug_named_value r600_debug_options[] = {
|
||||||
static void r600_destroy_context(struct pipe_context *context)
|
static void r600_destroy_context(struct pipe_context *context)
|
||||||
{
|
{
|
||||||
struct r600_context *rctx = (struct r600_context *)context;
|
struct r600_context *rctx = (struct r600_context *)context;
|
||||||
unsigned sh;
|
unsigned sh, i;
|
||||||
|
|
||||||
r600_isa_destroy(rctx->isa);
|
r600_isa_destroy(rctx->isa);
|
||||||
|
|
||||||
|
|
@ -104,6 +104,10 @@ static void r600_destroy_context(struct pipe_context *context)
|
||||||
}
|
}
|
||||||
util_unreference_framebuffer_state(&rctx->framebuffer.state);
|
util_unreference_framebuffer_state(&rctx->framebuffer.state);
|
||||||
|
|
||||||
|
for (sh = 0; sh < PIPE_SHADER_TYPES; ++sh)
|
||||||
|
for (i = 0; i < PIPE_MAX_CONSTANT_BUFFERS; ++i)
|
||||||
|
rctx->b.b.set_constant_buffer(context, sh, i, NULL);
|
||||||
|
|
||||||
if (rctx->blitter) {
|
if (rctx->blitter) {
|
||||||
util_blitter_destroy(rctx->blitter);
|
util_blitter_destroy(rctx->blitter);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue