Welcome, Guest.
Username: Password: Remember me

TOPIC: AmbientLight.fx (with dither toggle)

AmbientLight.fx (with dither toggle) 11 months 2 weeks ago #1

  • SoZ
  • SoZ's Avatar
  • Offline
  • Posts: 3
  • Thank you received: 6
TL;DR: A version of Ganossa's AmbientLight.fx with a toggle to turn dithering off. Try it if you encounter diagonal lines running through your image.

Download: https://pastebin.com/Pjqg0unK

I am completely new to ReShade and this is my first post here, so apologies in advance if I'm doing anything wrong. I've seen plenty of ReShade/SweetFX screenshots over the years but I hadn't looked into using ReShade before today. I wanted to make my screenshots a little more interesting, so I figured I would download it and give it a go.

After an hour or so of fiddling, I am very happy with the results, but the AmbientLight.fx shader was introducing a pattern of diagonal lines running through the image. Unable to find any mention of the issue on this forum, I traced the source of the pattern back to the "dither" code within the shader. Funnily enough, determining the origin of the problem gave me the keyword I had been missing to search for other posts on the topic on the forum, such as this one where Marty McFly had identified the cause of the problem previously: TOPIC: Shaders Problems

I have modified the version of AmbientLight.fx that was automatically downloaded when I installed ReShade earlier to allow dithering to be turned on and off via the AL_Dither toggle in the UI. It fixes my problem and I figured I would share the modification in case it's of use to anyone else. Hopefully there are no issues with sharing modifications to existing shaders that are already publicly available here; the forum rules weren't clear.

Regarding the dither code itself, not having used ReShade before, I am unsure whether or not it is working as intended. While it is technically a dither, the harsh pattern produced is very distracting. A more subtle pattern or random noise might produce a better result. Perhaps I'll experiment when I have more time.
Last Edit: 11 months 2 weeks ago by SoZ. Reason: Additional thoughts on the existing dither code
The administrator has disabled public write access.
The following user(s) said Thank You: One3rd, andrew, WalterDasTrevas, Marty, Sinclair, Rudy102

AmbientLight.fx (with dither toggle) 7 months 2 weeks ago #2

Thanks for this! That pattern had been bugging me for a while but I wasn't actually sure what was causing it. It had actually stopped me from using the AmbientLight shader in a number of situations due to this. The strange thing was it only showed up in some games and not all and I couldn't pin down why.
The administrator has disabled public write access.