Screen Space Shadows and Reflections Fix

Simple ReShade over-render and crop workaround fix. Slightly scales up rendered image beyond display borders, eliminating or reducing some bad screen space effect artifacts around viewport edges that visible in the vanilla game. Single effect, so absolutely minimal performance impact. Zero change to vanilla style/aesthetics beyond artifact reduction.


TLD
R
The abrupt termination of screen space shadows & reflections around screen edges, due to their origins (the elements that those respective shadows/reflections originate from) falling outside of screen space, is jarringly ugly.

This ReShade preset partially addresses this issue by simply scaling the rendered image up slightly to push those artifacts off screen, or closer to screen edges so they are gone, or at least less noticeable. Essentially this is an imperfect over-render and crop implementation. Help me make it better!

Compatibility
For this not to break the games UI the "safe zone" configured through the in-game display settings must be set to 90% horizontal and vertical. if anyone knows where/how to set "safe zone" lower than 90% through game's config files, please let me know.

Also includes a ReshadeEffectShaderToggler.ini file for use with the mod Walk Speed Control and Auto-Walk, which serves to keep that mod's walk speed ui elements from being pushed off screen, as I consider it an essential mod.

Most non-ReShade mods should work fine. Mods which add on screen UI elements outside of the games vanilla UI framework, and thus don't honor the UI safe zone (mostly only some script mods) could have their UI elements pushed off screen by this mod.

I wish I could get ReShadeEffectShaderToggler to play nicely with the game's shaders, so I could apply effects beneath the UI entirely, but if it's possible, I haven't been able to figure it out. It generally causes the game to crash whenever I select any actually relevant shader, no matter what settings I've configured for the active shader group. I've tried almost every version of the addon, as well as multiple versions of ReShade. If anyone can help with the ReShadeEffectShaderToggler, please do reach out.

The Whole Story

Screen space shadows and screen space reflections can't be produced by off-screen elements, so some shadows/reflections are abruptly cut off around screen edges. Especially noticeable when tilting the camera causing objects to be cut off at angles that don't align with screen edges. This is a well-understood limitation of screen space effects, that are somewhat compensated for in most titles, aside from RDR2.


Industry Standard Fixes
  • Over-render & Crop
    The first standard method of reducing the worst artifacts of screen space effects is to over-render (rendering a larger area than the viewport's size) and crop before outputting image for display. This way elements slightly outside the viewport are still rendered and influence screen space effects. The performance cost of rendering a larger image than will actually be displayed must be balanced against the improvement in image fidelity, by only over-rendering to a limited degree. When over-rendering and cropping, UI elements must be accounted for.
  • Alpha-mask/Fade
    After over-rendering and cropping, it is still likely that some screen space reflection/shadow casting elements will still fall outside the rendered image area causing their visible reflections/shadows to be cut off abruptly. These remaining artifacts should be softened to make them less jarring and noticeable by adding alpha-masking at the edges of screen space reflections/shadows, or otherwise fading the effect out, rather than cutting it off with hard edges.


RDR2 is Kind of Special

This game apparently employs neither of the methods described above in order to compensate for the obvious shortcoming of the screen space shadows and reflections that are used extensively in the title.

Ideally Rockstar would release a patch to fix the often broken appearance of these effects. Of course, screen space effects aren't perfect, and will never appear to be perfect, but they shouldn't look like garbage either, and industry standard approaches to compensating for their shortcoming should be expected from triple A developers.

The next best thing would be for some skilled modders to tackle these issues by devising a way to get RDR2 to over-render and crop internally and alpha-masking/fading the edges of screen space effects. I do believe that RDR2 does have these capabilities under the hood somewhere. I think it even is doing some degree of over-rendering but then it is scaling instead of cropping or something silly like that (even with resolution scale and dlss/fsr disabled). Unfortunately tackling this issue with a proper RDR2 mod is well over my head.

Thus the next next best thing... this ReShade workaround fix before you. Still, this method should really be applied beneath the UI elements, and the ReShade addon ReShadeEffectShaderToggler  by 4lex4nder that this preset makes limited use of for the Walk Speed Control and Auto-Walk compatibility, should be able to handle just that, but I haven't been able to get it to work effectively without crashing the game. So any help trying to work out the issues with that would be greatly appreciated.

Article information

Added on

Written by

linehand

0 comments