mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-11-03 09:01:42 -05:00
shm: Drop non-premul format, use less ambiguous ARGB8888 naming convention
This also matches the new wl_drm format names.
This commit is contained in:
parent
b2e619c740
commit
151ca457b4
2 changed files with 7 additions and 9 deletions
|
|
@ -108,9 +108,8 @@
|
||||||
</enum>
|
</enum>
|
||||||
|
|
||||||
<enum name="format">
|
<enum name="format">
|
||||||
<entry name="argb32" value="0"/>
|
<entry name="argb8888" value="0"/>
|
||||||
<entry name="premultiplied_argb32" value="1"/>
|
<entry name="xrgb8888" value="1"/>
|
||||||
<entry name="xrgb32" value="2"/>
|
|
||||||
</enum>
|
</enum>
|
||||||
|
|
||||||
<!-- Transfer a shm buffer to the server. The allocated buffer
|
<!-- Transfer a shm buffer to the server. The allocated buffer
|
||||||
|
|
|
||||||
|
|
@ -123,9 +123,8 @@ shm_create_buffer(struct wl_client *client, struct wl_resource *resource,
|
||||||
|
|
||||||
|
|
||||||
switch (format) {
|
switch (format) {
|
||||||
case WL_SHM_FORMAT_ARGB32:
|
case WL_SHM_FORMAT_ARGB8888:
|
||||||
case WL_SHM_FORMAT_PREMULTIPLIED_ARGB32:
|
case WL_SHM_FORMAT_XRGB8888:
|
||||||
case WL_SHM_FORMAT_XRGB32:
|
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
wl_resource_post_error(resource,
|
wl_resource_post_error(resource,
|
||||||
|
|
@ -179,10 +178,10 @@ bind_shm(struct wl_client *client,
|
||||||
resource = wl_client_add_object(client, &wl_shm_interface,
|
resource = wl_client_add_object(client, &wl_shm_interface,
|
||||||
&shm_interface, id, data);
|
&shm_interface, id, data);
|
||||||
|
|
||||||
wl_resource_post_event(resource, WL_SHM_FORMAT, WL_SHM_FORMAT_ARGB32);
|
|
||||||
wl_resource_post_event(resource, WL_SHM_FORMAT,
|
wl_resource_post_event(resource, WL_SHM_FORMAT,
|
||||||
WL_SHM_FORMAT_PREMULTIPLIED_ARGB32);
|
WL_SHM_FORMAT_ARGB8888);
|
||||||
wl_resource_post_event(resource, WL_SHM_FORMAT, WL_SHM_FORMAT_XRGB32);
|
wl_resource_post_event(resource, WL_SHM_FORMAT,
|
||||||
|
WL_SHM_FORMAT_XRGB8888);
|
||||||
}
|
}
|
||||||
|
|
||||||
WL_EXPORT struct wl_shm *
|
WL_EXPORT struct wl_shm *
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue