Bug 495254 - Night color washes out subtle white and gray patterns
Summary: Night color washes out subtle white and gray patterns
Status: RESOLVED UPSTREAM
Alias: None
Product: kwin
Classification: Plasma
Component: night color (other bugs)
Version First Reported In: 6.2.2
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
: 495252 495370 (view as bug list)
Depends on:
Blocks:
 
Reported: 2024-10-23 17:41 UTC by Sauf
Modified: 2025-04-01 17:01 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
I have to record from phone. because not visible from screenshots and screenvideos. (1.98 MB, video/mp4)
2024-10-23 17:41 UTC, Sauf
Details
New video from bug. KDE Neon (2.48 MB, video/mp4)
2024-11-12 10:21 UTC, Sauf
Details
identity ICC profile (696 bytes, application/vnd.iccprofile)
2024-11-22 01:54 UTC, Zamundaaa
Details
drm_info output (25.05 KB, application/zip)
2024-11-22 17:28 UTC, Sauf
Details
2nd drm_info output (25.23 KB, application/zip)
2024-12-04 21:00 UTC, Sauf
Details
patch to disable the degamma lut (1.06 KB, patch)
2024-12-16 17:55 UTC, Zamundaaa
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sauf 2024-10-23 17:41:04 UTC
Created attachment 175154 [details]
I have to record from phone. because not visible from screenshots and screenvideos.

SUMMARY
When you switch to night mode, the pattern of grey and white of files (e.g. Dolphin) disappears. this also effects on shadowing of windows too. refer to attachment. This bug appear with Plasma 6.2.0 update.

STEPS TO REPRODUCE
1. open Dolphin
2. turn on night mode
3. gray-white pattern of files disappear


SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 6.2.2
KDE Frameworks Version: 6.7.0
Qt Version: 6.8.0
Kernel Version: 6.11.5-zen1-1-zen (64-bit)
Graphics Platform: Wayland
Processors: AMD Ryzen 5 5600H with Radeon Graphics
Comment 1 Sauf 2024-10-23 17:46:06 UTC
*** Bug 495252 has been marked as a duplicate of this bug. ***
Comment 2 Sauf 2024-10-25 15:44:47 UTC
UPDATE:
It seems to be Wayland issue. no issue with x11; also shadowing of windows is not smooth.
Comment 3 Sauf 2024-10-30 08:46:35 UTC
UPDATE:
I did fresh install on Virtualbox and no issues, but fresh install on my actual hardware, have the issues.
Comment 4 Sauf 2024-11-12 10:18:57 UTC
UPDATE:
I tested on KDE Neon Live - unstable edition (neon-unstable-20241110-1149.iso). The bug persists on normal boot mode, but in "KDE Neon (safe graphics)", I didn't see the issue.
This bug is even visible from windows screenshot. When you turn on night mode on opened image from Gwenview, the issue is visible. refer to new attachment.
Comment 5 Sauf 2024-11-12 10:21:35 UTC
Created attachment 175754 [details]
New video from bug. KDE Neon
Comment 6 Zamundaaa 2024-11-12 15:18:35 UTC
Can't reproduce, the contrast between the lines is good with the exact same color temperature.
Are you using an ICC profile?
Comment 7 Sauf 2024-11-13 09:36:08 UTC
(In reply to Zamundaaa from comment #6)
> Can't reproduce, the contrast between the lines is good with the exact same
> color temperature.
> Are you using an ICC profile?
Thanks for your reply.
No; Color profile setting is "None".
Even with fresh install and default settings from multiple distributions, the result is same.
Comment 8 Nate Graham 2024-11-15 18:41:16 UTC
*** Bug 495370 has been marked as a duplicate of this bug. ***
Comment 9 Zamundaaa 2024-11-22 01:54:30 UTC
Created attachment 176025 [details]
identity ICC profile

There's one more thing you could test: As this sounds like it's somehow caused by kms offloading, what happens if you set an ICC profile?
The one I attached has the same color information as selecting "none" for the color profile, so it shouldn't change colors in any way except disabling kms offloading.
Comment 10 Sauf 2024-11-22 11:45:12 UTC
(In reply to Zamundaaa from comment #9)
> Created attachment 176025 [details]
> identity ICC profile
> 
> There's one more thing you could test: As this sounds like it's somehow
> caused by kms offloading, what happens if you set an ICC profile?
> The one I attached has the same color information as selecting "none" for
> the color profile, so it shouldn't change colors in any way except disabling
> kms offloading.

Thanks; setting this ICC profile resolves all issues regarding this bug and its duplicate (Bug 495370).
Comment 11 stefanob 2024-11-22 12:09:45 UTC
I'm the user opening one of the duplicate issues, I tested the attached ICC profile too, and can confirm that by using it, the issue seems solved.
Comment 12 Zamundaaa 2024-11-22 14:50:45 UTC
okay, then please attach the output of drm_info, once with the ICC profile, and once with the color profile set to "none" and night light enabled
Comment 13 Sauf 2024-11-22 17:28:46 UTC
Created attachment 176044 [details]
drm_info output

(In reply to Zamundaaa from comment #12)
> okay, then please attach the output of drm_info, once with the ICC profile,
> and once with the color profile set to "none" and night light enabled
I've attached it. The outputs is based on KDE Neon unstable edition (neon-unstable-20241110-1149).

Software
KDE Plasma Version: 6.2.80
KDE Frameworks Version: 6.9.0
Qt Version: 6.8.0
Kernel Version: 6.8.0-48-generic (64-bit)
Graphics Platform: Wayland
Comment 14 Sauf 2024-12-04 21:00:09 UTC
Created attachment 176358 [details]
2nd drm_info output

(In reply to Zamundaaa from comment #12)
> okay, then please attach the output of drm_info, once with the ICC profile,
> and once with the color profile set to "none" and night light enabled

I've made another output, but this time on my main OS. It is little different output than last time. I don't know if this normal. but I've attached it maybe it is worthy.

Operating System: Arch Linux 
KDE Plasma Version: 6.2.4
KDE Frameworks Version: 6.8.0
Qt Version: 6.8.1
Kernel Version: 6.12.1-zen1-1-zen (64-bit)
Graphics Platform: Wayland
Processors: 12 × AMD Ryzen 5 5600H with Radeon Graphics
Graphics Processor: AMD Radeon Graphics
Comment 15 Zamundaaa 2024-12-16 16:27:37 UTC
Okay, I suspect that this is a driver bug, triggered by KWin using the degamma lut instead of the gamma lut like it did before.

Could you test a small patch for KWin, on top of 6.2, to find out if that's correct?
Comment 16 Sauf 2024-12-16 16:34:38 UTC
(In reply to Zamundaaa from comment #15)
> Okay, I suspect that this is a driver bug, triggered by KWin using the
> degamma lut instead of the gamma lut like it did before.
> 
> Could you test a small patch for KWin, on top of 6.2, to find out if that's
> correct?
Sure, thank you.
Comment 17 Zamundaaa 2024-12-16 17:55:10 UTC
Created attachment 176685 [details]
patch to disable the degamma lut

Okay, here you go. Let me know if the issue still happens with that
Comment 18 Sauf 2024-12-17 16:30:31 UTC
(In reply to Zamundaaa from comment #17)
> Created attachment 176685 [details]
> patch to disable the degamma lut
> 
> Okay, here you go. Let me know if the issue still happens with that

Thanks. It resolves the issue.
Comment 19 Zamundaaa 2024-12-17 23:55:57 UTC
Okay, then please report this at https://gitlab.freedesktop.org/drm/amd/-/issues. In the hopefully near future this problem might solve itself by having better kernel APIs that would replace DEGAMMA_LUT, but until then it still needs to work correctly
Comment 20 Sauf 2025-03-17 14:43:09 UTC
(In reply to Zamundaaa from comment #15)
> Okay, I suspect that this is a driver bug, triggered by KWin using the
> degamma lut instead of the gamma lut like it did before.
hello,
I update my system from 6.2.4 to 6.3.3 and custom icc profile doesn't work anymore. I would love to hear any solution.
I changed 'Color accuracy' from 'Prefer efficiency' to 'Prefer color accuracy' and seems to be OK, but it comes with warning that impact on performance. how big deal this is?

> Okay, then please report this at https://gitlab.freedesktop.org/drm/amd/-/issues.
> In the hopefully near future this problem might solve itself 
> by having better kernel APIs that would replace DEGAMMA_LUT, 
> but until then it still needs to work correctly

I checked the issues page but reporting it was too much technical for me.
Comment 21 Zamundaaa 2025-04-01 15:33:21 UTC
> I changed 'Color accuracy' from 'Prefer efficiency' to 'Prefer color accuracy' and seems to be OK, but it comes with warning that impact on performance. how big deal this is?
It has similar performance to just using an ICC profile in 6.2. If that was fine for you, this will be too.

> I checked the issues page but reporting it was too much technical for me.
We still can't do anything about it here. Unless it's fixed in the driver, the issue will just persist until those mentioned APIs are finally merged.
Comment 22 Sauf 2025-04-01 17:01:57 UTC
(In reply to Zamundaaa from comment #21)
> > I changed 'Color accuracy' from 'Prefer efficiency' to 'Prefer color accuracy' and seems to be OK, but it comes with warning that impact on performance. how big deal this is?
> It has similar performance to just using an ICC profile in 6.2. If that was
> fine for you, this will be too.
> 
> > I checked the issues page but reporting it was too much technical for me.
> We still can't do anything about it here. Unless it's fixed in the driver,
> the issue will just persist until those mentioned APIs are finally merged.

Thank you very much