weston/libweston
Pekka Paalanen aa6346f274 color: introduce weston_color_profile
Roughly speaking, a color profile describes the color space of content
or an output. Under the hood, the description includes one or more ways
to map colors between the profile space and some standard profile
connecting space (PCS).

This object is not called a color space. A color space has a unique
definition, while a color profile may contain multiple different
mappings depending on render intent. Some of these mappings may be
subjective, with an artistic touch.

When a source color profile and a destination color profile are combined
under a specific render intent, they produce a color transformation.
Color transformations are already preresented by weston_color_transform.

This patch adds the basic API for color profile objects. Everything
worthwhile of these objects is implemented in the color managers:
color-noop never creates these, and in color-lcms they are basically a
container for cmsHPROFILE, the Little CMS object for color profiles.
Color profile objects will not be interpreted outside of the color
managers, unlike color transformations.

For a start, the color manager API has one function to create color
profiles: from ICC profile data. More creation functions for other
sources will be added later.

The API has errmsg return parameter for error messages. These are not
simply weston_log()'d, because CM&HDR protocol will allow clients to
trigger errors and the protocol handles that gracefully. Therefore
instead of flooding the compositor logs, the error messages will
probably need to be relayed back to clients.

Color-lcms is expected to create a cmsHPROFILE for all kinds of color
profiles, not just for those created from ICC profile data. Hence,
color-lcms will fingerprint color profiles by the MD5 hash which Little
CMS computes for us. The fingerprint is used for de-duplication: instead
of creating copies, reference existing color profiles.

This code is very much based on Sebastian Wick's earlier work on Weston
color management, but structured and named differently.

Co-authored-by: Sebastian Wick <sebastian@sebastianwick.net>
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
2021-11-23 09:23:05 +00:00
..
backend-drm Fix TTY switching after failed failed repaint with legacy mode set. 2021-09-29 12:17:58 +00:00
backend-fbdev pixman-renderer: Replace output-create flags with struct 2020-03-20 15:25:24 +00:00
backend-headless backend-headless: Fix pointer vs. int confusion with EGL 2021-08-03 18:42:25 +01:00
backend-rdp backend-rdp: Correctly tear down the RDP back-end 2021-11-03 10:33:21 +02:00
backend-wayland backend-wayland: clean up wayland_input structs 2021-10-20 00:25:43 -04:00
backend-x11 Fix indentation all through the project 2021-07-31 15:28:20 +00:00
color-lcms color: introduce weston_color_profile 2021-11-23 09:23:05 +00:00
renderer-gl gl-renderer: add support for (a|x)bgr16161616f shm formats 2021-11-06 23:52:58 -04:00
animation.c Fix indentation all through the project 2021-07-31 15:28:20 +00:00
backend.h Fix TTY switching after failed failed repaint with legacy mode set. 2021-09-29 12:17:58 +00:00
bindings.c libweston: add missing include 2020-01-29 09:49:41 +00:00
clipboard.c libweston: add missing include 2020-01-29 09:49:41 +00:00
color-noop.c color: introduce weston_color_profile 2021-11-23 09:23:05 +00:00
color.c color: introduce weston_color_profile 2021-11-23 09:23:05 +00:00
color.h color: introduce weston_color_profile 2021-11-23 09:23:05 +00:00
compositor.c Fix TTY switching after failed failed repaint with legacy mode set. 2021-09-29 12:17:58 +00:00
content-protection.c compositor: Prevent an invalid access against content protection 2021-05-12 17:51:49 +03:00
data-device.c libweston/data-device: Don't crash when doing dnd operations w/o a keyboard 2021-07-31 17:19:15 +00:00
dbus.c dbus: Don't return value from void function 2019-06-11 11:31:04 +01:00
dbus.h Rename compositor.h to libweston/libweston.h 2019-04-18 12:31:46 +03:00
drm-formats.c drm-formats: remove create() and destroy() from the API 2021-09-06 12:52:37 +00:00
git-version.h.meson Add Meson build system 2018-12-09 14:50:54 +02:00
input.c libweston: Rename weston_view_activate() to weston_view_activate_input() 2021-11-02 19:04:33 +02:00
launcher-direct.c launcher-direct: handle seat0 without VTs 2021-01-21 09:02:26 +00:00
launcher-impl.h libweston/launcher: libseat backend 2021-04-14 09:22:17 +00:00
launcher-libseat.c libweston/launcher: libseat backend 2021-04-14 09:22:17 +00:00
launcher-logind.c launcher-logind: Try the user's primary session if not in a session 2021-09-29 14:30:50 +00:00
launcher-util.c libweston/launcher: Allow VT switch without get_vt 2021-04-14 09:22:17 +00:00
launcher-util.h Rename compositor.h to libweston/libweston.h 2019-04-18 12:31:46 +03:00
launcher-weston-launch.c launcher: remove unused field 2021-04-12 08:03:42 -06:00
libinput-device.c Fix indentation all through the project 2021-07-31 15:28:20 +00:00
libinput-device.h Rename compositor.h to libweston/libweston.h 2019-04-18 12:31:46 +03:00
libinput-seat.c input: Handle correctly failure to compile XKB keymaps 2021-07-31 13:44:47 +00:00
libinput-seat.h Rename compositor.h to libweston/libweston.h 2019-04-18 12:31:46 +03:00
libweston-internal.h drm-formats: remove create() and destroy() from the API 2021-09-06 12:52:37 +00:00
linux-dmabuf.c gl-renderer: do not expose query_dmabuf_formats and query_dmabuf_modifiers 2021-04-27 19:56:38 +00:00
linux-dmabuf.h drop MOD_INVALID, MOD_LINEAR definitions 2021-02-25 14:35:03 +02:00
linux-explicit-synchronization.c libweston: Advertise minor version 2 of zwp_linux_explicit_synchronization_v1 2019-08-02 15:00:08 +00:00
linux-explicit-synchronization.h libweston: Support zwp_surface_synchronization_v1.set_acquire_fence 2019-02-06 12:21:56 +00:00
linux-sync-file-uapi.h libweston: Introduce an internal linux sync file API 2019-02-06 12:21:56 +00:00
linux-sync-file.c libweston: export weston_linux_sync_file_read_timestamp() 2019-04-18 12:50:55 +03:00
linux-sync-file.h libweston: export weston_linux_sync_file_read_timestamp() 2019-04-18 12:50:55 +03:00
log.c Fix indentation all through the project 2021-07-31 15:28:20 +00:00
meson.build pixel-formats: Add human readable format modifier 2021-07-22 22:19:17 +00:00
noop-renderer.c libweston: add missing include 2020-01-29 09:49:41 +00:00
pixel-formats.c pixman-renderer: track Pixman formats in pixel format table 2021-09-15 15:00:29 +03:00
pixel-formats.h pixman-renderer: track Pixman formats in pixel format table 2021-09-15 15:00:29 +03:00
pixman-renderer.c pixman-renderer: track Pixman formats in pixel format table 2021-09-15 15:00:29 +03:00
pixman-renderer.h pixman-renderer: Replace output-create flags with struct 2020-03-20 15:25:24 +00:00
plugin-registry.c Rename plugin-registry.h to libweston/plugin-registry.h 2019-04-18 12:31:46 +03:00
screenshooter.c libweston: do not damage on screenshot 2021-02-25 12:47:07 +02:00
spring-tool.c Rename compositor.h to libweston/libweston.h 2019-04-18 12:31:46 +03:00
timeline.c libweston: fix typos 2021-02-24 10:01:17 -05:00
timeline.h libweston: move TYPEVERIFY macro into shared 2021-02-17 12:52:33 +00:00
touch-calibration.c libweston: don't clean up surface role 2020-06-12 09:23:11 +00:00
vertex-clipping.c Rename src/ to libweston/ 2016-06-23 17:44:54 +03:00
vertex-clipping.h Rename src/ to libweston/ 2016-06-23 17:44:54 +03:00
weston-direct-display.c libweston: Add weston-direct-display server side implementation 2019-11-18 19:33:09 +02:00
weston-launch.c launcher: fix socket message race condition 2021-04-10 22:29:30 +00:00
weston-launch.h launcher: remove unused enum value 2021-05-15 15:40:24 +00:00
weston-log-file.c weston-log: destroy subscriptions with destruction of subscribers 2020-02-10 10:53:50 +00:00
weston-log-flight-rec.c weston-log: destroy subscriptions with destruction of subscribers 2020-02-10 10:53:50 +00:00
weston-log-internal.h weston-log-wayland: make stream_destroy() use weston_log_subscriber_release() 2020-02-10 10:53:50 +00:00
weston-log-wayland.c Fix indentation all through the project 2021-07-31 15:28:20 +00:00
weston-log.c libweston: fix typos 2021-02-24 10:01:17 -05:00
zoom.c libweston: Add functions to modify disable_planes counter for an output 2019-08-26 16:18:22 +05:30