diff --git a/fsr/fsr-easu.slangp b/fsr/fsr-easu.slangp new file mode 100644 index 0000000..78abb17 --- /dev/null +++ b/fsr/fsr-easu.slangp @@ -0,0 +1,7 @@ +shaders = 1 + +shader0 = shaders/fsr-pass0.slang +filter_linear0 = true +scale_type0 = viewport +scale0 = 1.0 +wrap_mode0 = clamp_to_edge \ No newline at end of file diff --git a/fsr/fsr.slangp b/fsr/fsr.slangp index dcbce21..9b13f29 100644 --- a/fsr/fsr.slangp +++ b/fsr/fsr.slangp @@ -4,11 +4,13 @@ shader0 = shaders/fsr-pass0.slang filter_linear0 = true scale_type0 = viewport scale0 = 1.0 +wrap_mode0 = clamp_to_edge shader1 = shaders/fsr-pass1.slang filter_linear1 = true scale_type1 = source scale1 = 1.0 +wrap_mode1 = clamp_to_edge parameters = "FSR_SHARPENING;FSR_FILMGRAIN;FSR_GRAINCOLOR;FSR_GRAINPDF" FSR_SHARPENING = 0.3 diff --git a/fsr/shaders/ffx_fsr1.h b/fsr/shaders/ffx_fsr1.h index 15ecfde..4e0b3d5 100644 --- a/fsr/shaders/ffx_fsr1.h +++ b/fsr/shaders/ffx_fsr1.h @@ -747,12 +747,12 @@ AF1 sharpness){ // Immediate constants for peak range. AF2 peakC=AF2(1.0,-1.0*4.0); // Limiters, these need to be high precision RCPs. - AF1 hitMinR=mn4R*ARcpF1(AF1_(4.0)*mx4R); - AF1 hitMinG=mn4G*ARcpF1(AF1_(4.0)*mx4G); - AF1 hitMinB=mn4B*ARcpF1(AF1_(4.0)*mx4B); - AF1 hitMaxR=(peakC.x-mx4R)*ARcpF1(AF1_(4.0)*mn4R+peakC.y); - AF1 hitMaxG=(peakC.x-mx4G)*ARcpF1(AF1_(4.0)*mn4G+peakC.y); - AF1 hitMaxB=(peakC.x-mx4B)*ARcpF1(AF1_(4.0)*mn4B+peakC.y); + AF1 hitMinR=min(mn4R,eR)*ARcpF1(AF1_(4.0)*mx4R); + AF1 hitMinG=min(mn4G,eG)*ARcpF1(AF1_(4.0)*mx4G); + AF1 hitMinB=min(mn4B,eB)*ARcpF1(AF1_(4.0)*mx4B); + AF1 hitMaxR=(peakC.x-max(mx4R,eR))*ARcpF1(AF1_(4.0)*mn4R+peakC.y); + AF1 hitMaxG=(peakC.x-max(mx4G,eG))*ARcpF1(AF1_(4.0)*mn4G+peakC.y); + AF1 hitMaxB=(peakC.x-max(mx4B,eB))*ARcpF1(AF1_(4.0)*mn4B+peakC.y); AF1 lobeR=max(-hitMinR,hitMaxR); AF1 lobeG=max(-hitMinG,hitMaxG); AF1 lobeB=max(-hitMinB,hitMaxB); @@ -845,12 +845,12 @@ AF1 sharpness){ // Immediate constants for peak range. AH2 peakC=AH2(1.0,-1.0*4.0); // Limiters, these need to be high precision RCPs. - AH1 hitMinR=mn4R*ARcpH1(AH1_(4.0)*mx4R); - AH1 hitMinG=mn4G*ARcpH1(AH1_(4.0)*mx4G); - AH1 hitMinB=mn4B*ARcpH1(AH1_(4.0)*mx4B); - AH1 hitMaxR=(peakC.x-mx4R)*ARcpH1(AH1_(4.0)*mn4R+peakC.y); - AH1 hitMaxG=(peakC.x-mx4G)*ARcpH1(AH1_(4.0)*mn4G+peakC.y); - AH1 hitMaxB=(peakC.x-mx4B)*ARcpH1(AH1_(4.0)*mn4B+peakC.y); + AH1 hitMinR=min(mn4R,eR)*ARcpH1(AH1_(4.0)*mx4R); + AH1 hitMinG=min(mn4G,eG)*ARcpH1(AH1_(4.0)*mx4G); + AH1 hitMinB=min(mn4B,eB)*ARcpH1(AH1_(4.0)*mx4B); + AH1 hitMaxR=(peakC.x-max(mx4R,eR))*ARcpH1(AH1_(4.0)*mn4R+peakC.y); + AH1 hitMaxG=(peakC.x-max(mx4G,eG))*ARcpH1(AH1_(4.0)*mn4G+peakC.y); + AH1 hitMaxB=(peakC.x-max(mx4B,eB))*ARcpH1(AH1_(4.0)*mn4B+peakC.y); AH1 lobeR=max(-hitMinR,hitMaxR); AH1 lobeG=max(-hitMinG,hitMaxG); AH1 lobeB=max(-hitMinB,hitMaxB); @@ -963,12 +963,12 @@ AF1 sharpness){ // Immediate constants for peak range. AH2 peakC=AH2(1.0,-1.0*4.0); // Limiters, these need to be high precision RCPs. - AH2 hitMinR=mn4R*ARcpH2(AH2_(4.0)*mx4R); - AH2 hitMinG=mn4G*ARcpH2(AH2_(4.0)*mx4G); - AH2 hitMinB=mn4B*ARcpH2(AH2_(4.0)*mx4B); - AH2 hitMaxR=(peakC.x-mx4R)*ARcpH2(AH2_(4.0)*mn4R+peakC.y); - AH2 hitMaxG=(peakC.x-mx4G)*ARcpH2(AH2_(4.0)*mn4G+peakC.y); - AH2 hitMaxB=(peakC.x-mx4B)*ARcpH2(AH2_(4.0)*mn4B+peakC.y); + AH2 hitMinR=min(mn4R,eR)*ARcpH2(AH2_(4.0)*mx4R); + AH2 hitMinG=min(mn4G,eG)*ARcpH2(AH2_(4.0)*mx4G); + AH2 hitMinB=min(mn4B,eB)*ARcpH2(AH2_(4.0)*mx4B); + AH2 hitMaxR=(peakC.x-max(mx4R,eR))*ARcpH2(AH2_(4.0)*mn4R+peakC.y); + AH2 hitMaxG=(peakC.x-max(mx4G,eG))*ARcpH2(AH2_(4.0)*mn4G+peakC.y); + AH2 hitMaxB=(peakC.x-max(mx4B,eB))*ARcpH2(AH2_(4.0)*mn4B+peakC.y); AH2 lobeR=max(-hitMinR,hitMaxR); AH2 lobeG=max(-hitMinG,hitMaxG); AH2 lobeB=max(-hitMinB,hitMaxB); diff --git a/fsr/smaa+fsr.slangp b/fsr/smaa+fsr.slangp index ab33689..aaf010b 100644 --- a/fsr/smaa+fsr.slangp +++ b/fsr/smaa+fsr.slangp @@ -29,11 +29,13 @@ shader4 = shaders/fsr-pass0.slang filter_linear4 = true scale_type4 = viewport scale4 = 1.0 +wrap_mode4 = clamp_to_edge shader5 = shaders/fsr-pass1.slang filter_linear5 = true scale_type5 = source scale5 = 1.0 +wrap_mode5 = clamp_to_edge parameters = "SMAA_EDT;SMAA_THRESHOLD;SMAA_MAX_SEARCH_STEPS;SMAA_MAX_SEARCH_STEPS_DIAG;SMAA_LOCAL_CONTRAST_ADAPTATION_FACTOR;SMAA_CORNER_ROUNDING;FSR_SHARPENING;FSR_FILMGRAIN;FSR_GRAINCOLOR;FSR_GRAINPDF" SMAA_EDT = 1.0