summaryrefslogtreecommitdiffstats
path: root/src/wayland-server.h
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@bitplanet.net>2011-08-30 21:26:19 -0400
committerKristian Høgsberg <krh@bitplanet.net>2011-08-31 18:34:21 -0400
commitc640571c00b0c1ffafb05b1ad5cd02cd511cb06a (patch)
treea18333b8cdb062e68f373f0ffd9e07e4c493deef /src/wayland-server.h
parentUpdate TODO (diff)
downloadwayland-c640571c00b0c1ffafb05b1ad5cd02cd511cb06a.tar
wayland-c640571c00b0c1ffafb05b1ad5cd02cd511cb06a.tar.gz
wayland-c640571c00b0c1ffafb05b1ad5cd02cd511cb06a.tar.bz2
wayland-c640571c00b0c1ffafb05b1ad5cd02cd511cb06a.tar.lz
wayland-c640571c00b0c1ffafb05b1ad5cd02cd511cb06a.tar.xz
wayland-c640571c00b0c1ffafb05b1ad5cd02cd511cb06a.tar.zst
wayland-c640571c00b0c1ffafb05b1ad5cd02cd511cb06a.zip
Remove the wl_visual interface
The visual interface was meant to be a generic mechanism for specifying the content of a buffer. It goes back to before we had the buffer factory interfaces (like wl_drm and wl_shm) and we wanted to keep it open-ended enough that yuv, png or even svg buffer or so would be possible. Now that we have the buffer abstraction, we can add different buffer types by introducing new interfaces that create buffers. It only makes sense to leave it to those interfaces to specify the contents of the buffers. For wl_shm, this means that we now just specify the pixel format using an enum. For EGL buffers, the exact pixel formats are controlled by the implementation (part of wl_drm and similar), and from the client point of view, everything is controlled using EGLConfigs.
Diffstat (limited to 'src/wayland-server.h')
-rw-r--r--src/wayland-server.h15
1 files changed, 4 insertions, 11 deletions
diff --git a/src/wayland-server.h b/src/wayland-server.h
index 71bb5bf..95b44c1 100644
--- a/src/wayland-server.h
+++ b/src/wayland-server.h
@@ -117,11 +117,6 @@ struct wl_resource {
void *data;
};
-struct wl_visual {
- struct wl_object object;
- uint32_t name;
-};
-
struct wl_shm_callbacks {
void (*buffer_created)(struct wl_buffer *buffer);
@@ -134,14 +129,10 @@ struct wl_shm_callbacks {
struct wl_compositor {
const struct wl_compositor_interface *interface;
- struct wl_visual argb_visual;
- struct wl_visual premultiplied_argb_visual;
- struct wl_visual rgb_visual;
};
struct wl_buffer {
struct wl_resource resource;
- struct wl_visual *visual;
int32_t width, height;
uint32_t busy_count;
void *user_data;
@@ -285,10 +276,12 @@ wl_shm_buffer_get_data(struct wl_buffer *buffer);
int32_t
wl_shm_buffer_get_stride(struct wl_buffer *buffer);
+uint32_t
+wl_shm_buffer_get_format(struct wl_buffer *buffer);
+
struct wl_buffer *
wl_shm_buffer_create(struct wl_shm *shm, int width, int height,
- int stride, struct wl_visual *visual,
- void *data);
+ int stride, uint32_t visual, void *data);
int
wl_buffer_is_shm(struct wl_buffer *buffer);