This is Gentoo's testing wiki. It is a non-operational environment and its textual content is outdated.

Please visit our production wiki at https://wiki.gentoo.org

Color management

From Gentoo Wiki (test)
Jump to:navigation Jump to:search
Note
This article has been postponed for at least 2 years, because author does not feel competent enough on this complicated topic but alas no one else seems intending to write one, so better something than nothing. Hence readers are recommended to take everything with two pinches of salt and some pepper. And please help improve it if you actually know this stuff.

Color management at its most simple definition is computer technique for ensuring colors stay the same or at least as close as possible between devices. The reason for why colors may differ is due to different physical characteristics between devices and even imperfections between displays of the same model and ageing of display.

Basic theory behind computer color

Despite the title of the section basic grasp of RGB is assumed until someone writes about basics of the basics here as well.

Shortcomings of RGB

More fundamentally RGB is a relative scale that most commonly has mere 256 states per channel which is largely insufficient to represent the vividness of the real world. For better or worse our eyes see the world in a logarithmic fashion with greater distinction between darker tones. This can be exploited to avoid encoding many bright tones that seem roughly the same to humans. Nevertheless color management and using the correct gamma function are not the same thing although both are required for correct end results.

Another issue is the aforementioned relativity where the color space is defined by the display characteristics meaning that #FF0000, #00FF00, #0000FF and by extension #FFFFFF are in fact different tones from device to device.

sRGB

sRGB is Microsoft's attempt at fixing shortcomings of RGB, chiefly lack of absolute reference points and clarifies which gamma curve to use, on the downside that curve itself is non-linea adding complexity to proper sRGB support. Despite this sRGB is the de facto standard for RGB24/32 images and if it lacks a color profile then sRGB is the safest bet for files produced in the past 15 or so years.

Color management systems (CMS)

On Linux the two main solutions for display color management are Oyranos and colord.

KDE

Install kde-misc/kolor-manager which provides Oyranos integration with KDE and do not forget to also check "Enable color correction" in KWin compositor settings.

Warning
Kolor Manager currently does not seem to be working with Plasma 5 even with Git version but colord-kde-9999 ebuild does work at least somewhat.

GNOME

Enable colord USE flag and rebuild your world. For at least non-lite version of GNOME that should be all that's required.

Application support

GIMP

In theory has had color management for a bit longer than most applications but if someone actually understand how to configure it to work properly with a CMS, go ahead, till then consider it broken.

Firefox

Go to about:config and set gfx.color_management.mode to 1 from the default value of 2. This will make Firefox treat untagged images as sRGB which generally is what you want. For best results also install a color management system or alternatively set the gfx.color_management.display_profile to the correct file, naturally this will not work with two displays.

mpv

When using mpv's OpenGL presentation driver (not the legacy one inherited from MPlayer!) it's possible to configure it to always output sRGB which usually is already the case but could not be the case for nowadays more exotic or old content. Alternatively when built with LittleCMS support the same OpenGL presentation driver can also do full color management including with profile set in window properties but currently it will not tag the surface appropriately so care should be taken that the display color manager does not apply the display color profile again.

For detailed description see the article on mpv.

External resources

TODO

  • Color calibration section or even an outright article as it's probably complicated enough on its own on Linux.
  • More applications such as Inkscape, Blender and other graphics processing tools.