[PATCH weston 1/2] clients: Allow simple-egl to use wl_surface_damage_buffer

Derek Foreman derekf at osg.samsung.com
Fri May 19 15:46:53 UTC 2017


Oops, will repost these with a proper version test.

On 19/05/17 10:43 AM, Derek Foreman wrote:
> wl_surface_damage_buffer landed ages ago, but in order for GL to
> use it the client must bind a wl_compositor version >= 4 (the
> version where damage_buffer was introduced).
>
> This patch updates the bind version and allows
> eglSwapBuffersWithDamage to actually use the provided damage
> rectangles instead of performing full surface damage.
>
> This log is much longer than the patch.
>
> Signed-off-by: Derek Foreman <derekf at osg.samsung.com>
> ---
>  clients/simple-egl.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/clients/simple-egl.c b/clients/simple-egl.c
> index c4f72a44..b7dbaa40 100644
> --- a/clients/simple-egl.c
> +++ b/clients/simple-egl.c
> @@ -797,7 +797,7 @@ registry_handle_global(void *data, struct wl_registry *registry,
>  	if (strcmp(interface, "wl_compositor") == 0) {
>  		d->compositor =
>  			wl_registry_bind(registry, name,
> -					 &wl_compositor_interface, 1);
> +					 &wl_compositor_interface, 4);
>  	} else if (strcmp(interface, "zxdg_shell_v6") == 0) {
>  		d->shell = wl_registry_bind(registry, name,
>  					    &zxdg_shell_v6_interface, 1);
>



More information about the wayland-devel mailing list