diff options
author | Brian Paul <[email protected]> | 2016-08-25 18:02:43 -0600 |
---|---|---|
committer | Brian Paul <[email protected]> | 2016-08-26 14:20:19 -0600 |
commit | dcf63339e7f95c206f05d64fa5df27340188ac12 (patch) | |
tree | 35f41ddf766cae7bc507f6bd01ccf1c4f03f9a8a | |
parent | ff500ed5a1287eadc06fc19661f0aad8767b664d (diff) |
svga: use new svga_check_sampler_framebuffer_resource_collision()
Reviewed-by: Neha Bhende <[email protected]>
-rw-r--r-- | src/gallium/drivers/svga/svga_pipe_sampler.c | 21 |
1 files changed, 3 insertions, 18 deletions
diff --git a/src/gallium/drivers/svga/svga_pipe_sampler.c b/src/gallium/drivers/svga/svga_pipe_sampler.c index 59609b84e20..42e4fa5a69f 100644 --- a/src/gallium/drivers/svga/svga_pipe_sampler.c +++ b/src/gallium/drivers/svga/svga_pipe_sampler.c @@ -511,27 +511,12 @@ svga_set_sampler_views(struct pipe_context *pipe, } /* Check if any of the sampler view resources collide with the framebuffer - * color buffers or depth stencil resource. If so, enable the NEW_FRAME_BUFFER + * color buffers or depth stencil resource. If so, set the NEW_FRAME_BUFFER * dirty bit so that emit_framebuffer can be invoked to create backed view * for the conflicted surface view. */ - for (i = 0; i < svga->curr.framebuffer.nr_cbufs; i++) { - if (svga->curr.framebuffer.cbufs[i]) { - struct svga_surface *s = svga_surface(svga->curr.framebuffer.cbufs[i]); - if (svga_check_sampler_view_resource_collision(svga, s->handle, shader)) { - svga->dirty |= SVGA_NEW_FRAME_BUFFER; - break; - } - } - } - - if (svga->curr.framebuffer.zsbuf) { - struct svga_surface *s = svga_surface(svga->curr.framebuffer.zsbuf); - if (s) { - if (svga_check_sampler_view_resource_collision(svga, s->handle, shader)) { - svga->dirty |= SVGA_NEW_FRAME_BUFFER; - } - } + if (svga_check_sampler_framebuffer_resource_collision(svga, shader)) { + svga->dirty |= SVGA_NEW_FRAME_BUFFER; } done: |