compositor: Let renderers create and destroy surface state on their own

Graphics / Wayland / Weston - Ander Conselvan de Oliveira [intel.com] - 25 October 2013 14:21 EDT

Remove create_surface() and destroy_surface() from the renderer interface and change the renderers to create surface state on demand and destroy it using the weston_surface's destroy signal.

Also make sure the surfaces' renderer state is reset to NULL on destruction.

This is a step towards runtime switchable renderers.

(rpi-renderer changes are only compile-tested)

aa398ae compositor: Let renderers create and destroy surface state on their own
src/compositor.c | 8 -------
src/compositor.h | 2 --
src/gl-renderer.c | 61 ++++++++++++++++++++++++++++++++++---------------
src/noop-renderer.c | 13 -----------
src/pixman-renderer.c | 50 ++++++++++++++++++++++++++++------------
src/rpi-renderer.c | 54 ++++++++++++++++++++++++++++---------------
6 files changed, 112 insertions(+), 76 deletions(-)

Upstream: cgit.freedesktop.org


  • Share