Simple Hue Shifting in ReShade 2.0.1
- BIGdrop
- Topic Author
Less
More
hello
i am trying to port a newer ReShade plugin for 3.0+ (found here ) to version 2.0.1 due to game compatibility issues
I have made 3 changes to get it to compile and run so far:
1) remove " #include ReShade.fxh" line
2) change "PostProcessVS" to "ReShade::VS_PostProcess"
3) changed "PI" declared variable to nPI because it seemed to conflict
4) also removed UI settings as I won't use those
Here is the full code currently:
It seems to run and print, however no changes to picture that I can see.
Im looking thru the changelog and other 2.0.1 plugins, and all the methods seem to match up, so IDK at this point
Any help appreciated, thanks in advance!
i am trying to port a newer ReShade plugin for 3.0+ (found here ) to version 2.0.1 due to game compatibility issues
I have made 3 changes to get it to compile and run so far:
1) remove " #include ReShade.fxh" line
2) change "PostProcessVS" to "ReShade::VS_PostProcess"
3) changed "PI" declared variable to nPI because it seemed to conflict
4) also removed UI settings as I won't use those
Here is the full code currently:
Warning: Spoiler!
/*
This code is shared under the Creative Commons Attribution-NonCommercial-ShareAlike license.
You can find more information about this license at https://creativecommons.org/licenses/by-nc-sa/2.5/
This file contains code written by J. "fluffy" Shagam and made available under the same license.
You can find more of fluffy's work at https://beesbuzz.biz
Feel free to modify and share any code in this file, but make sure you honor fluffy's original license.
*/
#pragma message "Disco Shader v1"
uniform float speed = 10;
uniform float shift = 60;
uniform int framecount < source = "framecount"; >;
static const float nPI = 3.14159265f;
float3 PS_colorCycle(float4 pos : SV_Position, float2 texcoord : TEXCOORD) : SV_Target {
float3 input = tex2D(ReShade::BackBuffer, texcoord).rgb;
float3 output;
float offset = shift + ((framecount)*speed/10.0);
/*
The following code is copyright J. "fluffy" Shagam and made available to the public s
under the Creative Commons Attribution-NonCommercial-ShareAlike license.
You can find more information about this license at https://creativecommons.org/licenses/by-nc-sa/2.5/
You can find more of fluffy's work at https://beesbuzz.biz
You can find this code specifically at https://beesbuzz.biz/code/hsv_color_transforms.php
*/
float U = cos(offset*nPI/180.0);
float W = sin(offset*nPI/180.0);
output.r = (.299+.701*U+.168*W)*input.r + (.587-.587*U+.330*W)*input.g + (.114-.114*U-.497*W)*input.b;
output.g = (.299-.299*U-.328*W)*input.r + (.587+.413*U+.035*W)*input.g + (.114-.114*U+.292*W)*input.b;
output.b = (.299-.3*U+1.25*W)*input.r + (.587-.588*U-1.05*W)*input.g + (.114+.886*U-.203*W)*input.b;
return output;
}
technique colorCycle {
pass colorCycle {
VertexShader = ReShade::VS_PostProcess;
PixelShader = PS_colorCycle;
}
}
It seems to run and print, however no changes to picture that I can see.
Im looking thru the changelog and other 2.0.1 plugins, and all the methods seem to match up, so IDK at this point
Any help appreciated, thanks in advance!
Please Log in or Create an account to join the conversation.
- Duran.te
Less
More
5 years 1 month ago #2
by Duran.te
Replied by Duran.te on topic Simple Hue Shifting in ReShade 2.0.1
Doesn't
HSLShift.fx
shader do the same?
Please Log in or Create an account to join the conversation.
- BIGdrop
- Topic Author
Less
More
I forgot to explain what it does. This script basically uses the framecount to shift the hue of all pixels and create a "trippy" moving rainbow effect
Please Log in or Create an account to join the conversation.