Welcome, Guest.
Username: Password: Remember me

TOPIC: ColorCorrection.h: Typo, variable undefined

ColorCorrection.h: Typo, variable undefined 1 year 5 months ago #1

There seems to be a typo in the newest Reshade 0.19 code, specifically in the File ColorCorrection.h at line 327.

This is the line:
if ( Use_COLORSAT == 0 )   colorSat = 1.0f;

I tried installing a Witcher 3 preset, and got a undefined variable exception leading me to this point in the file.

I changed it to this to work:
if ( USE_COLORSAT == 0 )   colorSat = 1.0f;

The mistake is located in \ReShade 0.19.0 Public Beta with Framework\ReShade\CustomFX\ColorCorrection.h at line 327.

Next time maybe a bit more care when working with case sensitive variables ;)
Last Edit: 1 year 5 months ago by LordBelakor.
The administrator has disabled public write access.

ColorCorrection.h: Typo, variable undefined 1 year 5 months ago #2

  • crosire
  • crosire's Avatar
  • Offline
  • Posts: 2453
  • Thank you received: 1393
ReShade 0.19 (injector) != ReShade Framework (shaders) ;)
I'll pass this along to Lucifer, who's managing those shaders. Thanks for reporting! =)
Cheers, crosire =)
Last Edit: 1 year 5 months ago by crosire.
The administrator has disabled public write access.

ColorCorrection.h: Typo, variable undefined 1 year 5 months ago #3

  • Ganossa
  • Ganossa's Avatar
  • Offline
  • 최정장군
  • Posts: 790
  • Thank you received: 838
This is no mistake.
USE is a keyword for shader. COLORSAT is only a "boolean" variable of a shader. Therefore, the variable got intenionally renamed ( with specifically a lot of care for case sensitivity ;) )
The administrator has disabled public write access.
The following user(s) said Thank You: crosire, Wicked Sick, Ioxa

ColorCorrection.h: Typo, variable undefined 1 year 5 months ago #4

LuciferHawk wrote:
This is no mistake.
USE is a keyword for shader. COLORSAT is only a "boolean" variable of a shader. Therefore, the variable got intenionally renamed ( with specifically a lot of care for case sensitivity ;) )

The mistake was writing "Use" instead of "USE". I'm no expert but considering every other similarly structured variable has uppercase "USE", and having lowercase "Use" breaks old presets, this has to be a mistake. Unless you are expecting Users to change all their old presets for only this one variable from now on. I'd say its less work just bundling this little change into the next update to ensure compatibility with old Presets.
Last Edit: 1 year 5 months ago by LordBelakor.
The administrator has disabled public write access.

ColorCorrection.h: Typo, variable undefined 1 year 5 months ago #5

  • Ioxa
  • Ioxa's Avatar
  • Offline
  • Posts: 267
  • Thank you received: 245
LordBelakor wrote:
LuciferHawk wrote:
This is no mistake.
USE is a keyword for shader. COLORSAT is only a "boolean" variable of a shader. Therefore, the variable got intenionally renamed ( with specifically a lot of care for case sensitivity ;) )

The mistake was writing "Use" instead of "USE". I'm no expert but considering every other similarly structured variable has uppercase "USE", and having lowercase "Use" breaks old presets, this has to be a mistake. Unless you are expecting Users to change all their old presets for only this one variable from now on. I'd say its less work just bundling this little change into the next update to ensure compatibility with old Presets.
Like the LuciferHawk said, it was not a mistake. It needed to be changed for compatibility with the Mediator. And thats not the only one that was changed. Unfortunately it does break old presets so you will have to carry those values over manually. There may be a way to make the shaders compatible with old presets but the old presets would not be compatible with the Mediator.
The administrator has disabled public write access.