Closed natalieeatscats closed 4 months ago
Hi, thanks for the PR! Did you happen to have a before/after screenshot? While I definitely want to see more realism, I'm also somewhat worried about the effect this might have on performance.
Hi! I may be able to provide screenshots shortly, but atm I'm struggling with an even less dehardcoded version which has the sun color attenuate dynamically the closer it is to the horizon, and... it has some issues (like half of the game's space turning to black during thuderstorms lol). It would be great if you could take a look at it later and maybe find what the problem is I am entirely new to GLSL and any kind of shader programming really (I'm actually barely a frontend web dev), I simply started tinkering with your shader to make it look closer to what I wanted and it just spiraled into this As for performance, I haven't noticed any difference compared to the original, though I will try to provide some more concrete comparisons later with the screenshots. Also, it isn't really "realistic" per se, more of an artistic interpretation of the real thing. UPD: that thunderstorms related bug? it's also on here, apparently :( UPD2: fixed it in the dehardcoding branch and pr :)
Balmora sunset before:
And after:
A little later:
The values aren't perfect atm and produce a more pinkish look than I'd like (though I'm sure it would be someone's cup of tea), which is why I continued to play around with it after I posted the PR. Also note that the colors of sky, fog, and sun are now extracted directly from OMW and then are messed with to produce the effect, so it will differ depending on the weater settings in the ini. This, btw, eliminates disharmony that could happen with the original version when the hardcoded shader values would clash with the game's colors from the weather settings.
The attenuated color only comes out at sunrise and sunset, so during the day it's not as flashy and vibrant and is more chill, as it should be:
As you can see, the difference during a clear day isn't so pronounced, though the atmosphere is somewhat smoother. Also, as a note: the rayleigh scattering with my changes is quite a bit stronger that the original, as is the fog, so I keep the multipliers somewhat low (scattering at 0.4 and mist density at 0.1 I think).
Performance: I'm sure there's room for improvement (again, I'm in no way versed in shader programming and my changes are quite messy), and right now the performance impact compared to the og shaders is around 3fps. Maybe there could be switch that only turns the more complicated scattering in the ui? Idk how that works
And this is the version I'm playing around with (and trying to fix) atm:
Here they are! Screenshots with Vurt's weather settings:
Also take color values directly from OpenMW instead of hardcoding them