Fake Volumetric lighting/Light Shafts
- SandyCheeks
- Topic Author
In games that have post process light shafts, the shafts can give a pretty decent impression of fake volumetric lighting. However this is only the case when the light source (sun, in this instance) is on the screen, and the light shafts are coming right at you.
As you gradually pan the screen away from the sun, the light shafts even start to cast horizontally across the screen, which looks really nice imo, and somewhat resembles the appearance of genuine volumetric lighting...(This is the aspect that i'm ultimately going to ask about emulating)
When the light source is completely off the screen however, there are literally no light shafts at all, and this leaves the game world looking much more lifeless and sterile than when the light shafts were cast.
Is there any way that you guys can think of to fake volumetric light shafts by making them cast across the screen at very wide angles? (even when the light source is not technically visible to the players)
I remember reading a post by MartyMcFly saying that his MXAO shader could take samples from the environment from outside the screen border (when the sample radius is set too high)... is that type of thing exploitable with reshade, in a way that we can take information from outside of the visual buffer? I might've misinterpreted what he meant...If so. any other ideas?
Edit: I'm really sorry about the wall of text, i tried to consolidate as best i could
Edit 2: This might be a far-fetched idea too but, would it theoretically be possible to use your mouse (or some other method) to click on the sun, and then that point is temporarily saved and used as a reference to dictate what direction light shafts/lighting effects should come from? I'm not aware of how/if reshade would be able to store and utilize that type of locational information, but that would allow for so many advanced rendering tricks it'm excited just thinking about the possibilities
Please Log in or Create an account to join the conversation.
- luluco250
Also it'd be very easy for the shader to fall out of sync with the tracked position. All in all it seems it'd be a horribly problematic effect to do. You could, of course, use a statically-positioned sun rays effect. That could work very well for screenshots, even with fixed positions through the mouse.
Please Log in or Create an account to join the conversation.
- SandyCheeks
- Topic Author
I wasn't even sure if some type of coordinate-based marker was possible, but yeah, keeping track of that point (and utilizing that point as a tool) does seem like it wold introduce a bunch of additional complications.
Even as i was originally typing out the op, i was pretty sure it was borderline impossible, or an unrealistic fantasy. As someone whose not familiar with coding, and only moderately aware of the limitations of the reshade framework, It's tempting to want to ask the Pros here about pushing the boundaries of what can be done with it. Sometimes that can go too far though, and end up with unrealistically advanced feature requests like some of mine
the only way to really learn about what can and can't be done is to ask though, so i hope you guys don't get annoyed by the questions. Anyway, thanks again for the response.
Please Log in or Create an account to join the conversation.
- moriz1
luluco250 wrote: You'd have to use mouse movement to do it and unfortunately ReShade only offers a literal mouse point, not a "movement", so it actually stops at screen edges. It's possible to extend ReShade to have a "mouse delta" but I had a lot of headaches doing so, but it does work.
i thought ReShade does have a mouse delta uniform:
uniform float2 mousedelta < source = "mousedelta"; >;
it's part of the ReShade shaders reference file. does this not work?
Please Log in or Create an account to join the conversation.
- Marty McFly
And what I mentioned about MXAO sampling outside screen: well, that happens. ReShade doesn't have any data outside screen so if you try to read data outside screen, you get false information (based on how texture coordinates are managed, repeating border pixel, mirror texture etc) so I actively have to prevent this from happening.
Please Log in or Create an account to join the conversation.
- luluco250
I tried to make a velocity map based on mouse direction (track objects across different frames and mark objects based on how fast they moved) and failed poorly.
Same, all my attempts to generate a velocity map have only ended up in temporal normal maps.
Please Log in or Create an account to join the conversation.
- Scorpio82CO
thank for your shaders. .. (Scurve, Magic bloom 3 really improved)
Please Log in or Create an account to join the conversation.