shaped-texture: Start using MetaMultiTexture

To be able to later support more complex YUV formats, we need to make
sure that MetaShapedTexture (the one who will actually render the
texture) can use the MetaMultiTexture class.
This commit is contained in:
Niels De Graef
2019-10-22 12:25:37 +02:00
parent 65a3b13b2f
commit c2e191fe3f
12 changed files with 282 additions and 204 deletions

View File

@@ -29,6 +29,7 @@
#include <wayland-server.h>
#include "cogl/cogl.h"
#include "meta/meta-multi-texture.h"
#include "wayland/meta-wayland-types.h"
#include "wayland/meta-wayland-egl-stream.h"
#include "wayland/meta-wayland-dma-buf.h"
@@ -56,19 +57,19 @@ struct _MetaWaylandBuffer
MetaWaylandBufferType type;
struct {
CoglTexture *texture;
MetaMultiTexture *texture;
} egl_image;
#ifdef HAVE_WAYLAND_EGLSTREAM
struct {
MetaWaylandEglStream *stream;
CoglTexture *texture;
MetaMultiTexture *texture;
} egl_stream;
#endif
struct {
MetaWaylandDmaBufBuffer *dma_buf;
CoglTexture *texture;
MetaMultiTexture *texture;
} dma_buf;
};
@@ -81,12 +82,12 @@ struct wl_resource * meta_wayland_buffer_get_resource (MetaWaylandBuff
gboolean meta_wayland_buffer_is_realized (MetaWaylandBuffer *buffer);
gboolean meta_wayland_buffer_realize (MetaWaylandBuffer *buffer);
gboolean meta_wayland_buffer_attach (MetaWaylandBuffer *buffer,
CoglTexture **texture,
MetaMultiTexture **texture,
GError **error);
CoglSnippet * meta_wayland_buffer_create_snippet (MetaWaylandBuffer *buffer);
gboolean meta_wayland_buffer_is_y_inverted (MetaWaylandBuffer *buffer);
void meta_wayland_buffer_process_damage (MetaWaylandBuffer *buffer,
CoglTexture *texture,
MetaMultiTexture *texture,
cairo_region_t *region);
#endif /* META_WAYLAND_BUFFER_H */