autolume / autolux

auto luminence for nix
MIT License
44 stars 1 forks source link

Upper / lower brightness threshold? #17

Closed bryango closed 6 years ago

bryango commented 6 years ago

The change in brightness feels too dramatic for me. I would like to tune it down a bit. It seems to me that tweaking--upper-threshold & --lower-threshold should do the job, but I don't quite understand the help info: what does upper brightness threshold before setting screen to lowest brightness mean? Could you elaborate? Thank you very much!

https://github.com/autolume/autolux/blob/d00ebe21b7e06c1f033ad2d567ae9f0dae794f97/autolux/opts.py#L71-L74

P.S. I believe that the help lines above are a bit mixed up, should be:

  parser.add_option("--lower", "--lower-threshold", dest="min_bright", type="int", default=MIN_BRIGHT,
    help="lower brightness threshold before setting screen to highest brightness (1K to 15K, default is %s)" % MIN_BRIGHT)
  parser.add_option("--upper", "--upper-threshold", dest="max_bright", type="int", default=MAX_BRIGHT,
    help="upper brightness threshold before setting screen to lowest brightness (45K to 65K, default is %s)" % MAX_BRIGHT)
okayzed commented 6 years ago

thanks for opening this issue and noticing the typos.

re: brightness: there is the --min and --max settings which should adjust the minimum and maximum output brightness. i think these are likely what you want. autolux also learns over time, so as you adjust brightness it will build a model that relates time of day + screen content = output brightness

the --lower and --upper are for calibrating the lower and upper values of screen content to the min and max brightness values. --upper 45K means that when autolux sees a screen content luma (the average "whiteness") above 45K it will set the output brightness to the minimum value.

to get an idea of the current screen's luma value, you can use import -silent -colorspace gray -screen -w root -quality 20 -format "%[mean]\n" info:. a low number means low screen content whiteness which means higher output brightness.

bryango commented 6 years ago

Now I get it! Thank you so much! I believe that "whiteness" is the better term, compared to "brightness" which leads to a bit confusion in the help info.