How can I simply adjust monitor color temperture in X?

18,068

Okay, so, the answer is that the redshift program, pointed out by Stéphane Gimenez in a comment above, can do this pretty simply. It's meant to do a clever adjust-white-point-over-the-day thing, but it can also be made to do one-time adjustments with the -o flag.

The desired color temperature in Kelvin must be given twice because of the time-based features, which is a bit weird but unimportant. And the other stuff is just there to suppress unhelpful-in-this-case informational messages — it's not important.

 redshift -o -l 0:0 -m randr -t 6000:6000

It's also important to note that the code assumes that neutral is 6500. (And experimentally, -t 6500:6500 appears to me to be identical to using -x to remove the effects completely.) On my system, where I think the native whitepoint is 9300K or so, I'm not sure what the actual numbers end up meaning, but the effect of choosing something lower than 6500 is certainly exactly what I want.

I was curious, so I looked at the code. Redshift is doing something a bit more complicated than running xgamma — it has a whole color-ramp table, with data sourced from http://www.vendian.org/mncharity/dir3/blackbody/. I'd look into it even further, but I think the next step is going for full-on proper color calibration.

Share:
18,068

Related videos on Youtube

mattdm
Author by

mattdm

I've been using Linux and Unix professionally since 1995, mostly in Linux-related sysadmin/systems architect jobs supporting academia. I generally know my stuff, but am very happy to learn something new and to be corrected when I'm wrong. Currently, I am the Fedora Project Leader.

Updated on September 18, 2022

Comments

  • mattdm
    mattdm over 1 year

    I have a new 27" iMac, on which I run Fedora 15 (with no Apple OS) — just boot straight to Linux.

    The colors are basically accurate to my eye, but the white point is much higher than I'd like (that is, everything is quite blue). I suppose it's 9300K, and may be due to fancy LED backlighting or some such. I don't know; I'm a software guy.

    I'd like to adjust it to a more comfortable 6500K. In the olden days (including my old LCD monitor), one would just push a button on the monitor and select that from the menu. On an iMac, of course, that's not really an option. Can I do this in software instead?

    I know that full-on profiling and calibration software runs on Linux, and I may get to that eventually, but for now I'd just like a simple option. What should I do?

    • jasonwryan
      jasonwryan almost 13 years
      If you can source an appropriate ICC profile (or hack one that is close to what you need), you can use xcalib to run it from your .xinitrc xcalib.sourceforge.net
    • jasonwryan
      jasonwryan almost 13 years
      I have only found this tftcentral.co.uk/articles/icc_profiles.htm#the_database You might find something to work from there... (I'd be surprised if you found anything official - it's not exactly the Apple Way)
    • Stéphane Gimenez
      Stéphane Gimenez almost 13 years
      Related interesting software redshift.
    • mattdm
      mattdm almost 13 years
      @jasonwryan: unfortunately, that's one of the ones I found that isn't right at all. (It appears to be for a 2009 iMac model with a different screen.)
    • mattdm
      mattdm almost 13 years
      @Stéphane Gimenez — hey! That's it! One can run redshift -o -t 6000:6000 to get exactly what I'm looking for. (-o for "oneshot", rather than the continuous adjustment.) The only drawback is that the software assumes that 6500K is the neutral white point, whereas my monitor is clearly "hotter" than that. So, when I say 6000K, I'm not really getting 6000K. But until I get around to doing the real calibration that's good enough for me.
    • mattdm
      mattdm almost 13 years
      I think, by the way, that redshift's time-based white point changes are kinda silly, since it can't really know your local lighting conditions. (Fluorescent lighting? Overcast day?) It really ought to read from your computer's camera and adjust appropriately. :)
  • user1686
    user1686 over 11 years
    Latest version allows a simple redshift -O 6000.
  • Evi1M4chine
    Evi1M4chine about 7 years
    This looks like it would be better solved by having the right ICC profile for your monitor, as clearly, the OS is confused about what colors are displayed, resulting in crassly wrong colors.
  • Hritik Arora
    Hritik Arora about 4 years
    I love this solution a lot! Helps me to wake up at the morning because I wasn't looking at the blue screen at night.
  • A. Donda
    A. Donda over 3 years
    @user1686, the effect of that command is cumulative, better reset before: redshift -P -O 6000