[Mesa-dev] [PATCH 2/2] loader/dri3: Invalidate the drawable after copySubBuffer
Michel Dänzer
michel at daenzer.net
Tue Sep 5 04:02:40 UTC 2017
On 04/09/17 09:27 PM, Thomas Hellstrom wrote:
> Anyone using copySubBuffer as a replacement for swapBuffers would probably
> want window resizing to update the viewport.
>
> Signed-off-by: Thomas Hellstrom <thellstrom at vmware.com>
> ---
> src/loader/loader_dri3_helper.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/src/loader/loader_dri3_helper.c b/src/loader/loader_dri3_helper.c
> index c0a6e0d..9549b18 100644
> --- a/src/loader/loader_dri3_helper.c
> +++ b/src/loader/loader_dri3_helper.c
> @@ -664,6 +664,8 @@ loader_dri3_copy_sub_buffer(struct loader_dri3_drawable *draw,
> dri3_fence_trigger(draw->conn, dri3_fake_front_buffer(draw));
> dri3_fence_await(draw->conn, dri3_fake_front_buffer(draw));
> }
> +
> + draw->ext->flush->invalidate(draw->dri_drawable);
> dri3_fence_await(draw->conn, back);
> }
Your rationale makes some sense to me, but I notice that
dri2CopySubBuffer doesn't seem to do this. Do you have a test case where
this makes a difference?
--
Earthling Michel Dänzer | http://www.amd.com
Libre software enthusiast | Mesa and X developer
More information about the mesa-dev
mailing list