Bug 383515 - Invert effect: invert luminosity instead of color
Summary: Invert effect: invert luminosity instead of color
Status: RESOLVED INTENTIONAL
Alias: None
Product: kwin
Classification: Plasma
Component: effects-various (show other bugs)
Version: unspecified
Platform: Other Linux
: NOR wishlist
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-08-14 20:28 UTC by Carli Samuele
Modified: 2017-08-15 04:25 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Carli Samuele 2017-08-14 20:28:57 UTC
I'm an avid user of the invert effect. 
It's really invaluable when you have to switch between bright and dark environments very often!

It would be great though if it would be possible to invert brightness instead of color: the overall effect would be similar, but most of the UIs would stay intelligible (white would become black, but light blue would become dark blue instead of orange and so on: everything that relies on color would pretty much keep it's meaning. Pictures would still look bad but probably still easier to figure out compared to the inverted ones). 

As far as I uderstand, this effect could be implemented in a very similar way to the current one: instead of doing the RGB complement, it should convert to HSL, invert the luminosity and convert back to RGB. 

From a quick glance to http://www.niwa.nu/2013/05/math-behind-colorspace-conversions-rgb-hsl ,  the convertion shouldn't be too difficult to carry on. 

This could have it's independent life as an additional effect, or could be a configuration option in the current invert effect (I personally believe the latter option actualy makes more sense though.)


I think I could be able to work out the math and come up with a c++ code snippet myself, but I got quite confused by the whole KDE development process with which I have no experience. If someone knows how to properly compile and test kwin, thinks that implementing this would be a good idea and is willing to share some of his experience, it would be great to work on it together!
Comment 1 Martin Flöser 2017-08-15 04:25:41 UTC
I don't expect any of the core developers to work on this, we have too many tasks already. Due to that I set to won't fix as I don't want to give false expectations.