[PATCH 1/2] XWAYLAND Present support

Axel Davy axel.davy at ens.fr
Sat Jan 25 09:04:11 PST 2014


Hi,

These patches are to enable Present support with XWayland.

While Present has a fallback mode for DDX not implementing
the helper functions for Present, and that this callback
can be used with XWayland, this new implementation (for 
XWayland) is more adapted to Wayland, and is able
to avoid copies if the gl content fills the window (like
standart Present support when the window is fullscreen).

Something that can be improved with this implementation
is the behaviour at swap_interval=0 (no vsync). Right now
it copies the content of the presented pixmap to the window
pixmap, which means tearings. (but with vsync,
you can have flips and avoid tearings).
Something clever can be done, which would remove the tearings
in this situation, but since it's more complicated, I wanted
first to release this implementation.

A difficult thing was to handle correctly the Window destruction
while a flip had been done, and it needed a change to the 
XWayland API change I proposed, that's why I post a new one
that is more adapted.

Don't hesitate to give comments.

Axel Davy (3):
  Add XWayland API with Present support in mind.
  Initial Present Wayland support
  Update configure and Makefile to support Present XWayland

 configure.ac                           |  11 +-
 hw/xfree86/xwayland/Makefile.am        |   3 +-
 hw/xfree86/xwayland/xwayland-events.c  | 220 ++++++++++++++++++++++++++++++
 hw/xfree86/xwayland/xwayland-private.h |   9 ++
 hw/xfree86/xwayland/xwayland-window.c  |   6 +
 hw/xfree86/xwayland/xwayland.h         |  15 +++
 present/Makefile.am                    |  24 +++-
 present/present.c                      |  77 ++++++++---
 present/present_priv.h                 |  37 +++++
 present/present_wayland.c              | 240 +++++++++++++++++++++++++++++++++
 10 files changed, 617 insertions(+), 25 deletions(-)
 create mode 100644 hw/xfree86/xwayland/xwayland-events.c
 create mode 100644 present/present_wayland.c

-- 
1.8.3.2



More information about the wayland-devel mailing list