Nvidia Brightness/Gamma Setting Persistence

By default the gamma setting of 1 makes the blacks on my display device way too dark. They are dark to the point where all detail is lost. My display only allows brightness manipulation which does nothing for those lost details. No problem though because the nvidia-settings has a gamma setting and works as intended. However, anytime I log out, restart or the display goes to sleep, the gamma goes back to 1.0.

Things I’ve tried:

  • I opened nvidia-settings from terminal using sudo nvidia-settings, which didn’t work.
  • I followed the manjaro wiki Configure NVIDIA (non-free) settings and load them on Startup, just in case the gamma portion did work on Cinnamon. It didn’t.
  • I tried to change the setting with xgamma. It changed it just fine, just didn’t keep the setting after reboot.
  • I added # gamma 1.3 (also tried without #) to /etc/X11/mhwd.d/nvidia.conf with the same results
  • I added # gamma 1.3 (also tried without #) to /etc/X11/xorg.conf.d/90-mhwd.conf just in case even though it links to nvidia.conf. Didn’t work.
  • Switched over to the 5.4 kernel. That didn’t work either.

Things I haven’t tried yet

  • Redshift. Apparently you can set it up for gamma on a timer. I’ve read other posts saying it worked for KDE Plasma, but not gnome. Given Cinnamon is GTK, I’m guessing it would go the way of Gnome.
  • Kernel 5.9. Im not a fan of experimental kernels… but I’m getting to that point.

Anyway, anyone have experience with this? Am I just missing something simple?

Hello,

Please take heed to this:

  • if you open Nvidia X Settings with sudo then saving the .nvidia-settings-rc will render it unreadable for your user, fix that first.
  • make sure if is about nvidia or xgamma to add the proper entry in your ~/.xinitrc
    Example:
    nvidia-settings --load-config-only
    or
    xgamma -rgamma x.xxx -ggamma x.xxx -bgamma x.xxx
    replace x with the proper numbers.
  • Kernel 5.9 will not help you at all at it still doesn’t have any nvidia modules build for it.

Thanks for the reply.

I checked the preferences of .nvidia-settings-rc and my username has ownership and read-write privilege.

As to ~/.xinitrc, I followed the wiki, did a nano ~/.xinitrc and added nvidia-settings --load-config-only. So it now looks like

nvidia-settings --load-config-only
exec $(get_session “$1”)

I also tried, via terminal, xgamma -rgamma 1.30 -ggamma 1.25 -bgamma 1.30. It reset like everything else. Should I try

xgamma -rgamma 1.30 -ggamma 1.25 -bgamma 1.30
exec $(get_session “$!”)

a little new info. Now when I boot up or login the gamma is still 1.0 but when I launch nvidia-settings it automatically sets the gamma to 1.3. So I guess I can just auto start nvidia-settings. Not exactly convenient, but not the worst.

Thanks again for the help. I appreciate it

1 Like

Your new additional information reminds me of this:

I wonder if there is a bug somewhere. If all is set on your side. Now i’m in an install where i don’t use ~/.xinitrc but it also happens that i don’t need to touch the gama settings. Later i might do a test with another install and see if i can trace the issue, if any.

Oh man… I forgot to mention I’m on 390xx drivers. I’m not sure how applicable that other post is.

Other information that may help you

  • I was using Manjaro KDE for the last few months and didn’t have gamma problems, but I did have problems with my graphics resetting each time I logged out or suspended. Looking back, I could just turn off that notification and be just fine.
  • I’m sporting an nvidia gtx 460 so it may not be worth your time to really look into this since I doubt there are many 460 owners out there.
  • My next graphics card is going to be a Radeon haha

Another bit of an oddity, which hopefully helps you out, when coming back from a suspend, gamma is at 1.0. A xgamma in terminal shows
cinnjaro ~> xgamma
-> Red 1.300, Green 1.250, Blue 1.300
But thats not what it is because now I can definitely tell the difference between 1 and 1.3. Anyway I do
cinnjaro ~> xgamma -rgamma 1.3 -ggamma 1.25 -bgamma 1.3
-> Red 1.300, Green 1.250, Blue 1.300
<- Red 1.300, Green 1.250, Blue 1.300
and gamma is as listed. Go figure. I’m starting to wonder if I shouldn’t just uninstall the nvidia drivers or even cinnamon and reinstall. I wonder if there is any difference in 390.132 that are in the repository and 390.138 that are in other distros repositories and the nvidia website. Probably nothing of consequence…

I’m also now getting a warning from nvidia-settings “warning: The color settings have been changed outside of nvidia-settings so current slider values may be incorrect.”
Maybe thats me screwing with xgamma?

update
For those of you have are having the same problem, or something similar. I’ve found a work around. I installed redshift (that alone didn’t seem to work) and added the qredshift applet. I put in my gamma values and amazingly enough, they persisted through both a log out and restart. So, not the cleanest solution, but a solution all the same.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.