mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 00:38:48 +02:00
st/dri: flush drawable textures before unreferencing
This fixes piglit/fbo-sys-blit with fast clear on radeonsi. Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
This commit is contained in:
parent
a38e1fd78b
commit
8bd7a6f48c
1 changed files with 8 additions and 0 deletions
|
|
@ -237,6 +237,14 @@ dri2_drawable_process_buffers(struct dri_context *ctx,
|
|||
if (i == ST_ATTACHMENT_DEPTH_STENCIL && alloc_depthstencil)
|
||||
continue;
|
||||
|
||||
/* Flush the texture before unreferencing, so that other clients can
|
||||
* see what the driver has rendered.
|
||||
*/
|
||||
if (i != ST_ATTACHMENT_DEPTH_STENCIL && drawable->textures[i]) {
|
||||
struct pipe_context *pipe = ctx->st->pipe;
|
||||
pipe->flush_resource(pipe, drawable->textures[i]);
|
||||
}
|
||||
|
||||
pipe_resource_reference(&drawable->textures[i], NULL);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue