Weirdness with RawTherapee and a colour management. Please help me understand what's going on.

For the longest time, the workflow I’m going to describe here worked just fine until a couple of days ago when for reasons unbeknownst to me it didn’t anymore.

Whenever I would do a fresh install, I would fire up DisplaCAL, calibrate my display and subsequently install the resulting .icc colour profile as system-wide. It would, very predictably, reflect this as correct when checking Gnome settings - the profile was loaded and activated.

I would then only need to check “Use system monitor profile” in both RT and GIMP and that was that - consistent colour across all apps.

However, this stopped being the case a couple of days ago and I don’t know why. Let me describe what is going on now.

Gimp is fine, as is Firefox and gthumb - they are all displaying images in the same maner, as expected.

It’s just RT that seems to behave strangely. Thumbnails in the browser window and the film-strip in the editor view are displayed with very saturated and vivid colours, nothing like they’re supposed to look like. I can, however, make it display correct colors if I switch the working profile from the default ProPhoto to sRGB or if I enable Soft Proofing underneath the main view in the editor. All this is not something that I had to do before and I find it weird.

FWIW, Arch just updated to Gnome 44 and I suspect that might have something to do with it, but who knows?!

System:
  Kernel: 6.3.1-arch1-1 arch: x86_64 bits: 64 compiler: gcc v: 13.1.1
    parameters: BOOT_IMAGE=/vmlinuz-linux
    root=UUID=5e0ebfec-0da3-477c-94b3-25e509fb1aaf rw rootfstype=ext4
    loglevel=3
  Desktop: GNOME v: 44.1 tk: GTK v: 3.24.37 wm: gnome-shell dm: GDM v: 44.1
    Distro: Arch Linux
Machine:
  Type: Laptop System: LENOVO product: 82JM v: Legion 5 17ITH6H
    serial: <superuser required> Chassis: type: 10 v: Legion 5 17ITH6H
    serial: <superuser required>
  Mobo: LENOVO model: LNVNB161216 v: NO DPK serial: <superuser required>
    UEFI: LENOVO v: H1CN49WW date: 08/16/2022
Battery:
  ID-1: BAT0 charge: 46.7 Wh (56.0%) condition: 83.4/80.0 Wh (104.3%)
    volts: 15.4 min: 15.4 model: Celxpert L20C4PC2 type: Li-poly
    serial: <filter> status: not charging cycles: 8
CPU:
  Info: model: 11th Gen Intel Core i7-11800H bits: 64 type: MT MCP
    arch: Tiger Lake gen: core 11 level: v4 note: check built: 2020
    process: Intel 10nm family: 6 model-id: 0x8D (141) stepping: 1
    microcode: 0x42
  Topology: cpus: 1x cores: 8 tpc: 2 threads: 16 smt: enabled cache:
    L1: 640 KiB desc: d-8x48 KiB; i-8x32 KiB L2: 10 MiB desc: 8x1.2 MiB
    L3: 24 MiB desc: 1x24 MiB
  Speed (MHz): avg: 2040 high: 2300 min/max: 800/4600 scaling:
    driver: intel_pstate governor: performance cores: 1: 1072 2: 2154 3: 2300
    4: 2236 5: 2205 6: 2300 7: 2300 8: 2300 9: 2300 10: 2300 11: 1721 12: 801
    13: 1787 14: 2300 15: 2300 16: 2279 bogomips: 73744
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
  Vulnerabilities:
  Type: itlb_multihit status: Not affected
  Type: l1tf status: Not affected
  Type: mds status: Not affected
  Type: meltdown status: Not affected
  Type: mmio_stale_data status: Not affected
  Type: retbleed status: Not affected
  Type: spec_store_bypass mitigation: Speculative Store Bypass disabled via
    prctl
  Type: spectre_v1 mitigation: usercopy/swapgs barriers and __user pointer
    sanitization
  Type: spectre_v2 mitigation: Enhanced / Automatic IBRS, IBPB:
    conditional, RSB filling, PBRSB-eIBRS: SW sequence
  Type: srbds status: Not affected
  Type: tsx_async_abort status: Not affected
Graphics:
  Device-1: Intel TigerLake-H GT1 [UHD Graphics] vendor: Lenovo driver: i915
    v: kernel arch: Gen-12.1 process: Intel 10nm built: 2020-21 ports:
    active: eDP-1 empty: DP-1, DP-2, DP-3, DP-4, DP-5, HDMI-A-1
    bus-ID: 00:02.0 chip-ID: 8086:9a60 class-ID: 0300
  Device-2: NVIDIA GA106M [GeForce RTX 3060 Mobile / Max-Q] vendor: Lenovo
    driver: nvidia v: 530.41.03 alternate: nouveau,nvidia_drm non-free: 530.xx+
    status: current (as of 2023-03) arch: Ampere code: GAxxx
    process: TSMC n7 (7nm) built: 2020-22 pcie: gen: 4 speed: 16 GT/s
    lanes: 16 bus-ID: 01:00.0 chip-ID: 10de:2560 class-ID: 0300
  Device-3: Syntek Integrated Camera type: USB driver: uvcvideo
    bus-ID: 3-6:3 chip-ID: 174f:2459 class-ID: fe01 serial: <filter>
  Display: x11 server: X.Org v: 21.1.8 with: Xwayland v: 23.1.1
    compositor: gnome-shell driver: X: loaded: modesetting,nvidia
    alternate: fbdev,intel,nouveau,nv,vesa dri: iris gpu: i915 display-ID: :1
    screens: 1
  Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 508x285mm (20.00x11.22")
    s-diag: 582mm (22.93")
  Monitor-1: eDP-1 model: AU Optronics 0x449d built: 2018 res: 1920x1080
    hz: 144 dpi: 128 gamma: 1.2 size: 382x215mm (15.04x8.46")
    diag: 438mm (17.3") ratio: 16:9 modes: 1920x1080
  API: OpenGL v: 4.6 Mesa 23.0.3 renderer: Mesa Intel UHD Graphics (TGL GT1)
    direct-render: Yes
Audio:
  Device-1: Intel Tiger Lake-H HD Audio vendor: Lenovo driver: snd_hda_intel
    v: kernel alternate: snd_sof_pci_intel_tgl bus-ID: 00:1f.3
    chip-ID: 8086:43c8 class-ID: 0403
  Device-2: NVIDIA GA106 High Definition Audio driver: snd_hda_intel
    v: kernel pcie: gen: 4 speed: 16 GT/s lanes: 16 bus-ID: 01:00.1
    chip-ID: 10de:228e class-ID: 0403
  API: ALSA v: k6.3.1-arch1-1 status: kernel-api tools: N/A
  Server-1: JACK v: 1.9.22 status: off tools: N/A
  Server-2: PipeWire v: 0.3.70 status: off tools: pw-cli
  Server-3: PulseAudio v: 16.1 status: active tools: pacat,pactl
Network:
  Device-1: Intel Tiger Lake PCH CNVi WiFi driver: iwlwifi v: kernel
    bus-ID: 00:14.3 chip-ID: 8086:43f0 class-ID: 0280
  IF: wlan0 state: up mac: <filter>
  Device-2: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet
    vendor: Lenovo driver: r8169 v: kernel pcie: gen: 1 speed: 2.5 GT/s lanes: 1
    port: 3000 bus-ID: 58:00.0 chip-ID: 10ec:8168 class-ID: 0200
  IF: enp88s0 state: up speed: 1000 Mbps duplex: full mac: <filter>
Bluetooth:
  Device-1: Intel AX201 Bluetooth type: USB driver: btusb v: 0.8
    bus-ID: 3-14:6 chip-ID: 8087:0026 class-ID: e001
  Report: bt-adapter note: tool can't run ID: hci0 rfk-id: 2 state: down
    bt-service: disabled rfk-block: hardware: no software: yes address: N/A
Drives:
  Local Storage: total: 1.16 TiB used: 616.98 GiB (52.0%)
  SMART Message: Unable to run smartctl. Root privileges required.
  ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Samsung
    model: SSD 970 EVO Plus 250GB size: 232.89 GiB block-size: physical: 512 B
    logical: 512 B speed: 31.6 Gb/s lanes: 4 type: SSD serial: <filter>
    rev: 2B2QEXM7 temp: 38.9 C scheme: GPT
  ID-2: /dev/nvme1n1 maj-min: 259:3 vendor: SK Hynix model: HFS001TDE9X084N
    size: 953.87 GiB block-size: physical: 512 B logical: 512 B speed: 31.6 Gb/s
    lanes: 4 type: SSD serial: <filter> rev: 41010C22 temp: 36.9 C scheme: GPT
Partition:
  ID-1: / raw-size: 232.38 GiB size: 227.68 GiB (97.97%)
    used: 22.77 GiB (10.0%) fs: ext4 dev: /dev/nvme0n1p2 maj-min: 259:2
  ID-2: /boot raw-size: 511 MiB size: 510 MiB (99.80%)
    used: 94.8 MiB (18.6%) fs: vfat dev: /dev/nvme0n1p1 maj-min: 259:1
Swap:
  Kernel: swappiness: 60 (default) cache-pressure: 100 (default)
  ID-1: swap-1 type: zram size: 4 GiB used: 0 KiB (0.0%) priority: 100
    dev: /dev/zram0
Sensors:
  System Temperatures: cpu: 33.0 C mobo: N/A
  Fan Speeds (RPM): N/A
Info:
  Processes: 351 Uptime: 33m wakeups: 1 Memory: 31.14 GiB
  used: 9.48 GiB (30.4%) Init: systemd v: 253 default: graphical
  tool: systemctl Compilers: gcc: 13.1.1 clang: 15.0.7 Packages: 1043
  pm: pacman pkgs: 1035 libs: 301 tools: gnome-software,pamac,yay pm: flatpak
  pkgs: 8 Shell: Bash v: 5.1.16 running-in: kgx inxi: 3.3.26

Did Arch switch to Wayland when moving to Gnome 44?

Color management + Wayland = no bueno right now

As per my inxi output, I was using X, not wayland.

However, your output contains:
image

2 Likes

Hmmm, that is right. How do I make sure I am not using Xwayland? Is there anyway to completely remove it? Or block it?

Log out, and at the GDM screen make sure you choose Xorg.

Some time ago there was a color management bug in gnome/x11, don’t know if it was fixed.

I seem to have been confused by @ChasingShadows comment and led into believing I was using Wayland whitout knowit it, but it’s not the case. I am indeed running X.

loginctl session-status
3 - radu (1000)
           Since: Wed 2023-05-10 08:02:13 EEST; 16min ago
          Leader: 1397 (gdm-session-wor)
            Seat: seat0; vc2
             TTY: tty2
         Service: gdm-password; type x11; class user
           State: active
            Unit: session-3.scope
                  ├─1397 "gdm-session-worker [pam/gdm-password]"
                  ├─1455 /usr/lib/gdm-x-session --run-script /usr/bin/gnome-session
                  ├─1461 /usr/lib/Xorg vt2 -displayfd 3 -auth /run/user/1000/gdm/Xauthority -nolisten tcp -background non>
                  ├─1471 xf86-video-intel-backlight-helper intel_backlight
                  └─1502 /usr/lib/gnome-session-binary
loginctl show-session 3 --value --property=Type
x11

Maybe some apps are using the lut in the profile while others are using the matrix? Which should be the same but somehow aren’t?

Morning, @zerosapte!

I would then only need to check “Use system monitor profile”

In order to try to narrow in to the culprit, perform this
swift experiment. In RT, instead of using the system monitor profile,
select “SwappedRedAndGreen”, to see how that reacts…

Have fun!
Claes in Lund, Sweden

Choosing ”SwappedRedAndGreen” makes for some proper radioactive colors. Blues go purple, yellows go flourescent green… what does this tell us?

OK, so I did a bit of an experimentation. I mentioned that if I change the working profile in RT from the defeault ProPhoto to sRGB, things are fine. So I exported an imaged with the ProPhoto working profile selected, (and it looks crazy vivid and saturated in RT, but fine otherwise), and then, I exported the same image again, this time with sRGB selected as a working profile.

I opened both images in GIMP and gthumb, which are both color managed and use the system profile and the images are IDENTICAL. There is no difference at all, whatsoever.

In which case, I guess the question becomes how do I make RT use sRGB as the default working profile?

You are not supposed to use srgb as working color profile. There is no room for calclulations in srgb.
Use some proper desktop environment. Gnome is broken.

Which ones are proper DEs?

Basically every desktop environment or window manager except gnome.

Hah! It’s a pitty. I do love Gnome…

However, I am already on a fresh Arch installation running KDE. I’ve been meaning to give it a proper try for years.

Hm, I think Pascal (and probably many others) runs dt on Gnome w/o issues, so might be something RT specific?

There are two sources for the profile: colord and the X atom. darktable-cmstest says they are set to the same value on my machine (using KDE).
Now, just to be sure, I actually run the following as part of the script that launches darktable – there were times when it was needed to help the atom and colord report the same value:

dispwin -I "/oldhome/shared_data/media/digicam/colour-management-profiles/dispcalGUI/storage/HP ZR22w #1 2022-08-20 18-52 0.3127x 0.329y sRGB S 1xCurve+MTX/HP ZR22w #1 2022-08-20 18-52 0.3127x 0.329y sRGB S 1xCurve+MTX.icc"
dispwin -V "/oldhome/shared_data/media/digicam/colour-management-profiles/dispcalGUI/storage/HP ZR22w #1 2022-08-20 18-52 0.3127x 0.329y sRGB S 1xCurve+MTX/HP ZR22w #1 2022-08-20 18-52 0.3127x 0.329y sRGB S 1xCurve+MTX.cal"

Maybe try something like that, and see if it helps. Sorry if you already tried that and I missed that part, I have been a bit busy and was not able to follow the thread.

Ok it’s a while ago that I tested gnome color management, will have another look at it. But problems with gnome color management quite regularly pop up here. And you might not notice the problem if you have a “normal” srgb screen.
If it was fixed, maybe I’ll even use gnome…

Yes but with GNOME 43. Here it is GNOME 44 + Linux 6.3. Some very recent components on the system, maybe a regression!

1 Like