diff options
| author | Sebastian Wick <sebastian.wick@redhat.com> | 2023-05-09 13:55:53 +0200 |
|---|---|---|
| committer | Sebastian Wick <sebastian.wick@redhat.com> | 2023-05-09 14:52:58 +0200 |
| commit | f3026c916ef91d78040913298170d5e538dd6618 (patch) | |
| tree | c96f9ffbb76e7d1f8e1f38099d0e5b9f50c13e9d /protocol | |
| parent | build: override wayland-scanner dep (diff) | |
| download | wayland-f3026c916ef91d78040913298170d5e538dd6618.tar wayland-f3026c916ef91d78040913298170d5e538dd6618.tar.gz wayland-f3026c916ef91d78040913298170d5e538dd6618.tar.bz2 wayland-f3026c916ef91d78040913298170d5e538dd6618.tar.lz wayland-f3026c916ef91d78040913298170d5e538dd6618.tar.xz wayland-f3026c916ef91d78040913298170d5e538dd6618.tar.zst wayland-f3026c916ef91d78040913298170d5e538dd6618.zip | |
protocol: specify the exact form of premultiplication
There are two ways to do pre-multiplication of the alpha channel into
the color channels: on optical values or on electrical values. While
pre-multiplication with optical values is arguably more correct, because
operations like blending or scaling require pre-multiplied, optical
color channels, wayland and compositors by default work with
pre-multiplied electrical values. This is most likely a convention that
Wayland took from Cairo.
This commit makes sure that the expectation of pre-multiplied electrical
values is properly documented.
Signed-off-by: Sebastian Wick <sebastian.wick@redhat.com>
Diffstat (limited to 'protocol')
| -rw-r--r-- | protocol/wayland.xml | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/protocol/wayland.xml b/protocol/wayland.xml index a2a969b..4e9f768 100644 --- a/protocol/wayland.xml +++ b/protocol/wayland.xml @@ -469,8 +469,8 @@ interface. If the buffer uses a format that has an alpha channel, the alpha channel - is assumed to be premultiplied in the color channels unless otherwise - specified. + is assumed to be premultiplied in the electrical color channel values + (after transfer function encoding) unless otherwise specified. Note, because wl_buffer objects are created from multiple independent factory interfaces, the wl_buffer interface is frozen at version 1. |
