ValveSoftware / SteamVR-for-Linux

Issue tracker for the Linux port of SteamVR
917 stars 45 forks source link

[BUG] Night mode only works in legacy reprojection mode #462

Open guysoft opened 3 years ago

guysoft commented 3 years ago

The Night Mode setting under setting under general does not work.

To Reproduce Steps to reproduce the behavior:

  1. Go to SteamVR Settings
  2. General
  3. Top option of night mode set to On
  4. VR stays not in night mode

Expected behavior Night mode should work

System Information (please complete the following information):

Screenshots Not applicable

Additional context Add any other context about the problem here.

Note: Commenters who are also experiencing this issue are encouraged to include the "System Information" section in their replies.

guysoft commented 2 years ago

Still playing with this, It seems like the hmdDisplayColorGainB R/G/B values settings don't work neither.

okawo80085 commented 2 years ago

Bummer, idr if this setting works on Windows, if it doesn't its probably just an echo from the past at this point :/

guysoft commented 2 years ago

So I booted to test.

  1. It works on windows
  2. Both LuxVR and OpenVR-Advanced-Settings use this to set the rgb values (related https://github.com/egemenertugrul/LuxVR/issues/1)

So this is not an old setting, its used by fairly recent applications. I think what ever isn't working on the night mode, is also not working on the RGB settings - so it would be helpful to determine why this not working.

okawo80085 commented 2 years ago

Huh, really weird, i'll try to check if its a driver side thing or not.

okawo80085 commented 2 years ago

OVR Advanced settings color and brightness settings work, although on Linux you need to enable "Use Overlay For Color" (an option at the bottom right of the video tab) for it to work and toggle it on near the brightness slider

image

guysoft commented 2 years ago

Ok, I managed to get the steam version working by following this issue, extracting the appimage and removing some files: https://github.com/OpenVR-Advanced-Settings/OpenVR-AdvancedSettings/issues/569#issuecomment-890587084

It seems that putting Use Overlay for color actually changes the behavior, it makes it add color rather than subtract it, which would not be what you want for night mode :-/ So now it adds more colors and does not remove the existing blue, which is what you get in windows without the color overlay option checked

okawo80085 commented 2 years ago

OHHHHHHHHHHHH, it adding color sorta makes sense though, because the way they do it with an overlay is using a texture alpha applied over the eye view textures before displaying them to the user :/

Also is there no way to mix it with the brightness values to achieve the desired effect?

guysoft commented 2 years ago

I played around with it and doesn't seem to help much. I tried values from here: https://academo.org/demos/colour-temperature-relationship/ (Converting 0-255 to 0-100).

Does not seem to give the effect, it only makes stuff brighter.

okawo80085 commented 2 years ago

Well shucks. I still have a bit of hope left tho. I need to check how the texture overlay math is done, if we're luck and it allows negative values for pixels or alpha we can pull it off, if not we'll need to look for a new solution :/

guysoft commented 2 years ago

Ok I found a workaround. Which might indicate where the problem is. It works per application is set to "legacy reprojection mode", night mode starts working. As soon as you leave the app that uses the setting night mode stops. Its not a good workaround because it halfs the framerate.

okawo80085 commented 2 years ago

They changed the default reprojection mode not for nothing after all, the new one gives you more fps, the old one allows you to use night light. Ups and down, the usual. Good that there is a work around for this though.