
////----------//
///**GLOBAL**///
//----------////
//-Global Defines-//

//>CustomFX Suite General Settings<\\
//-Commentary:The Custom Suite contains various distinct shader.\nBeginning from Technicolor, all following shader are grouped to together under the ColorCorrection set.
#define ColorCorrection_ToggleKey RFX_ToggleKey //[undef] //-


////----------//
///**CUSTOM**///
//----------////
#define USE_CUSTOM 0 //[Custom] //-

//>Custom Shader General Settings<\\
//-Commentary:This shader is not doing anything but a starting point for new shader developers.
#define val1 0.00 //[0.00:1.00] //-...
#define val2 1.00 //[0.00:1.00] //-...
#define Custom_ToggleKey RFX_ToggleKey //[undef] //-


////-------//
///**CEL**///
//-------////
#define USE_CEL 0 //[Cel] //-Cel : Creates an outline on objects, similar to Borderlands' cel shading effect. Requires depth buffer to work.

//>Cel Settings<\\
#define CelAccuracy 10.0 //[0.0:100.0] //-Accuracy or amount of Cel shading.
#define Cel_ToggleKey RFX_ToggleKey //[undef] //-


////----------//
///**DEBAND**///
//----------////
#define USE_DEBAND 1 //[Deband] //-Applies debanding to minimize banding artifacts

//>Deband Settings<\\
#define DEBAND_RADIUS 32.0 //[0.0:1024.0] //-Sampling radius, higher values will reduce further banding but might also reduce details
#define DEBAND_THRESHOLD 0.017 //[0.000:0.100] //-Threshold, higher values will reduce further banding but might also reduce details and increase noise
#define DEBAND_SAMPLE_COUNT 8 //[1:8] //-Sample count, higher values are better
#define DEBAND_OFFSET_MODE 3 //[1:3] //-1 = cross (axis aligned, fast), 2 = diagonal (45 degrees, slower), 3 = box (fully random, much slower)
#define DEBAND_DITHERING 1 //[0:3] //-Additional dithering options to smoothen the output. 0 = No dithering 1 = Ordered dithering, 2 = Random dithering, 3 = Iestyn's RGB dither (Valve)

//>Deband debug settings<\\
#define DEBAND_SKIP_THRESHOLD_TEST 0 //[0:1] //-1 = Skip threshold to see the unfiltered sampling pattern
#define DEBAND_OUTPUT_BOOST 1.0 //[-2.0:2.0] //-Default = 1.0. Any value other than the default activates debug mode. When fine-tuning the values you might use both these settings to boost luminance, which should make it easier to see banding artifacts.
#define DEBAND_OUTPUT_OFFSET 0.0 //[-1.0:3.0] //-Default = 0.0. Any value other than the default activates debug mode. When fine-tuning the values you might use both these settings to boost luminance, which should make it easier to see banding artifacts.
#define Deband_ToggleKey RFX_ToggleKey //[undef] //-


////---------//
///**PAINT**///
//---------////
#define USE_PAINT 0 //[Paint] //-Gives the image a painty look

//>Paint Settings<\\
#define PaintRadius 1 //[0:64] //-Amount of effect. Higher values require more performance.
#define PaintMethod 1 //[0:1] //-The algorithm used for paint effect. 0 = kingeric1992's paint effect, 1 = Basic kuwahara filtering
#define Paint_ToggleKey RFX_ToggleKey //[undef] //-


////-------------------//
///**ADAPTIVESHARPEN**///
//-------------------////
#define USE_ADAPTIVESHARPEN 0 //[AdaptiveSharpen] //-Adaptive sharpen shader by bacondither. For more information: http://forum.doom9.org/showthread.php?t=172131

//>Adaptive Sharpen Settings<\\
#define curve_height 0.10 //[0.15:3.0] //-Main sharpening strength.

//>Advanced Adaptive Sharpen Settings<\\
//-Commentary:Defined values under this row are "optimal". Do not change if you do not know what you are doing.
#define video_level_out 0 //[0:1] //-(MPC-HC and MPDN specific) True to preserve BTB & WTW (minor summation error). Normally it should be set to false (0).
#define curveslope (curve_height*1.5) //[undef] //-Sharpening curve slope, edge region.
#define D_overshoot 0.016 //[undef] //-Max dark overshoot before max compression.
#define D_comp_ratio 0.250 //[undef] //-Max compression ratio, dark overshoot (1/0.25=4x).
#define L_overshoot 0.004 //[undef] //-Max light overshoot before max compression.
#define L_comp_ratio 0.167 //[undef] //-Max compression ratio, light overshoot (1/0.167=6x).
#define max_scale_lim 10.0 //[undef] //-Abs change before max compression (1/10=?10%).
#define AdaptiveSharpen_ToggleKey RFX_ToggleKey //[undef] //-


////---------//
///**GAUSS**///
//---------////
#define USE_GAUSS 0 //[Gaussian] //-Gaussian Blur / Bloom / Unsharpmask

//>Gaussian Blur / Unsharpmask Settings<\\
#define Use_GaussianBlur 1 //[0:1] //-0 = off, 1 = on. Blurs the image
#define BlurStrength 0.13 //[0.00:1.00] //-Strength of the blur effect
#define Use_Unsharpmask 1 //[0:1] //-0 = off, 1 = on. Sharpens the image
#define SharpStrength 0.05 //[0.00:1.00] //-Strength of the sharpening effect
#define GaussSigma 1 //[1|2|3|4] //-Makes the blur and sharpening radius wider. Only works when GaussQuality is set to 1 or higher.
#define GaussQuality 1 //[0:12] //-Higher #'s = more blur passes for Blur and Unsharp Mask (Higher performance cost).

//>Gaussian Bloom Settings<\\
#define Use_GaussianBloom 1 //[0:1] //-0 = off, 1 = on. 
#define BloomStrength 0.46 //[0.00:1.00] //-Amount of bloom effect added to the image.
#define GaussBloomWarmth 2 //[0|1|2] //-0 = neutral, 1 = warm, 2 = hazy/foggy
#define GaussThreshold 0.504 //[0.000:1.000] //-Threshold for what is considered a bright light. Lower #'s = brighter
#define GaussExposure 43.70 //[0.00:100.00] //-Exposure of the effect. Lower #'s = brighter 
#define BloomSigma 4 //[1|2|3|4] //-Makes the bloom radius wider. Only works when BloomQuality is set to 1 or higher. 
#define BloomRed 1.00 //[0.00:2.00] //-Adds a RED tint to bloom. #'s < 1.00 add color, #'s > 1.00 remove color.
#define BloomGreen 1.00 //[0.00:2.00] //-Adds a GREEN tint to bloom. #'s < 1.00 add color, #'s > 1.00 remove color.
#define BloomBlue 1.00 //[0.00:2.00] //-Adds a BLUE tint to bloom. #'s < 1.00 add color, #'s > 1.00 remove color.
#define GaussBloomQuality 4 //[0:12] //-Higher #'s = more blur passes

//>Performance and Misc Options<\\
#define GaussTexScale 0 //[0|1|2] //-0 = Off, 1 = 1/2 Resolution, 2 = 1/4 Resolution. Reduces performance cost. Works best with Quality settings > 1.
#define BloomTexScale 2 //[0|1|2] //-0 = Off, 1 = 1/2 Resolution, 2 = 1/4 Resolution. Reduces performance cost. Works best with Quality settings > 1.
#define Gaussian_ToggleKey RFX_ToggleKey //[undef] //-


////-------------//
///**TILTSHIFT**///
//-------------////
#define USE_TILTSHIFT 0 //[TiltShift] //-TiltShift effect based of GEMFX

//>TiltShift Settings<\\
#define TiltShiftPower 5.0 //[0.0:100.0] //-Amount of blur applied to the screen edges
#define TiltShiftCurve 3.0 //[0.0:10.0] //-Defines the sharp focus / blur radius
#define TiltShiftOffset -0.6 //[-5.0:5.0] //-Defines the sharp focus aligned to the y-axis
#define TiltShift_TimeOut 0 //[0:100000] //-Defined Toggle Key will activate the shader until time (in ms) runs out. "0" deactivates the timeout feature.
#define TiltShift_ToggleKey VK_SPACE //[undef] //-


////-----------------//
///**TUNINGPALETTE**///
//-----------------////
#define USE_TUNINGPALETTE 0 //[TuningPalette] //-Allows to use color maps (like in ENB) or color palettes

//>Tuning Palette Settings General<\\
#define TuningColorPalette 0 //[0:1] //-ColorPalette
#define TuningColorMap 0 //[0:1] //-ColorMap
#define TuningColorLUT 1 //[0:1] //-ColorLUT
#define TuningPaletteDependency 0 //[0:1] //-0: PixelColor; 1: PixelBrightness (0 is recommended for the ColorPalette effect)
#define TuningPalettePower 0.075 //[0.000:1.000] //-Strength of the Tuning Palette effect
#define TuningPalette_ToggleKey RFX_ToggleKey //[undef] //-No description given

//>Color Palette Parameters<\\
#define TuningColorPaletteSmoothMix 0.3 //[0.0:1.0] //-Amount of smooth integration into original image
#define TuningTileAmountX 5 //[1:16] //-Amount of tiles the selected palette has on the X-axis
#define TuningTileAmountY 1 //[1:16] //-Amount of tiles the selected palette has on the Y-axis
#define TuningColorPaletteTexture "CFX_vintage.png" //[undef] //-Define the color palette for palette effect (e.g. CFX_quake.png, CFX_vintage.png)
#define TuningColorPalettePower 1/float3(1.0,1.0,1.0) //[undef] //-Defines the impact of red, green and blue when applying palette colors 

//>Color Map Parameters<\\
#define TuningColorMapTexture "CFX_TuningPalette.bmp" //[undef] //-needs to have 256x256 pixels  

//>Color LUT Settings<\\
#define TuningColorLUTIntensity 1.00 //[0.00:1.00] //-Intensity of the effect overlay
#define TuningColorLUTDstTexture "CFX_ColorLUTDst.png" //[undef] //-Needs to have 256x16 pixels
#define TuningColorLUTTileAmountX 256 //[undef] //-LUT Width
#define TuningColorLUTTileAmountY 16 //[undef] //-LUT Height


////-------------//
///**GR8MMFILM**///
//-------------////
#define USE_GR8MMFILM 0 //[Gr8mmFilm] //-Applies cutomized 8mm film overlays

//>Gr8mm Film Settings<\\
#define Gr8mmFilmTileAmount 7.0 //[2.0:20.0] //-Amount of frames used in the Gr8mmFilm.png
#define Gr8mmFilmPower 0.95 //[0.00:1.00] //-Overall intensity of the effect	
#define Gr8mmFilmVignettePower 1.0 //[0.0:2.0] //-Strength of the effect at the edges
#define Gr8mmFilmAlphaPower 1.2 //[0.0:2.0] //-Takes gradients into account (white => transparent)
#define Gr8mmFilmBlackFrameMix 0 //[0:1] //-0: Adds a black frame into the mix; 1: No black frame added
#define Gr8mmFilmScroll 0 //[0:1] //-0: Jumps from frame to frame; 1: Scrolls from frame to frame
#define Gr8mmFilmTexture "CFX_Gr8mmFilm.png" //[undef] //-Defines the texture which contains the single frames
#define Gr8mmFilmTextureSizeX 1280 //[undef] //-Size of the defined texture (Width)
#define Gr8mmFilmTextureSizeY 5040 //[undef] //-Size of the defined texture (Height)
#define Gr8mmFilm_ToggleKey RFX_ToggleKey //[undef] //-No description given


////---------//
///**GRAIN**///
//---------////
#define USE_GRAIN 0 //[Grain] //-Adds an active graininess to the image. Helps with banding and can add the illusion of detail

//>Film Grain Settings<\\
//-Commentary:This Martins improved Film Grain shader (http://devlog-martinsh.blogspot.com) which was ported by Alo81.
#define GrainPower 0.03 //[0.00:1.00] //-Intensity of applied grain
#define GrainColored 0 //[0:1] //-Whether grain should be colored or not. Colored grain is not as noticeable, so it helps to increase grain power.
#define GrainColorAmount 1.00 //[0.00:1.00] //-Amount of color to add to grain
#define GrainSize 1.50 //[1.25:2.50] //-Size of individual pieces of grain. Below 1.25 the pattern becomes noticeable.
#define GrainLuma 0.80 //[0.00:1.00] //-Grain brightness. 0 makes grain not visible.  
#define Grain_ToggleKey RFX_ToggleKey //[undef] //-No description given


////----------//
///**EMBOSS**///
//----------////
#define USE_EMBOSS 0 //[Emboss] //-Gives the image a painty look

//>Emboss Settings<\\
#define bEmbossDoDepthCheck 1 //[0:1] //-EXPERIMENTAL! If enabled, shader compares emboss samples depth to avoid artifacts at object borders.
#define fEmbossDepthCutoff 0.0001 //[0.0001:0.0100] //-Preserves object edges from getting artifacts. If pixel depth difference of emboss samples is higher than that, pixel gets skipped. 
#define fEmbossPower 0.666 //[0.100:2.000] //-Amount of embossing.	
#define fEmbossOffset 2.0 //[0.5:5.0] //-Pixel offset for embossing.
#define iEmbossAngle 90.00 //[0.00:360.00] //-Pixel offset angle for embossing.
#define Emboss_ToggleKey RFX_ToggleKey //[undef] //-


////-------//
///**LUT**///
//-------////
#define USE_LUT 0 //[ColorCorrection] //-Color Lookup Table: Uses a gradient texture to adjust the colors of the image.


////---------------//
///**TECHNICOLOR**///
//---------------////
#define USE_TECHNICOLOR 0 //[ColorCorrection] //-Technicolor : Attempts to mimic the look of an old movie using the Technicolor three-strip color process. Algorithm from prod80

//>Technicolor Settings<\\
#define ColStrengthR 0.20 //[0.05:1.00] //-Color Strength of Red channel. Higher means darker and more intense colors.	
#define ColStrengthG 0.20 //[0.05:1.00] //-Color Strength of Green channel. Higher means darker and more intense colors.
#define ColStrengthB 0.20 //[0.05:1.00] //-Color Strength of Blue channel. Higher means darker and more intense colors.
#define TechniBrightness 1.0 //[0.5:1.5] //-Brightness Adjustment, higher means brighter image.
#define TechniStrength 1.0 //[0.0:1.0] //-Strength of Technicolor effect. 0.0 means original image.
#define TechniSat 0.7 //[0.0:1.5] //-Additional saturation control since technicolor tends to oversaturate the image.


////-----------------//
///**SKYRIMTONEMAP**///
//-----------------////
#define USE_SKYRIMTONEMAP 0 //[ColorCorrection] //-Skyrim Tonemap: Applies color correction/tonemapping based on tonemappers of popular Skyrim ENB's.

//>Skyrim Tonemap Settings<\\
#define POSTPROCESS 5 //[1:6] //-Mode of postprocessing you want. Mode 1 uses V1 values, Mode 2 uses V2 values etc

//>Skyrim Tonemap Settings<\\
#define EAdaptationMinV1 0.05 //[0.00:1.00] //-
#define EAdaptationMaxV1 0.125 //[0.000:1.000] //-
#define EContrastV1 1.00 //[0.00:1.00] //-
#define EColorSaturationV1 1.00 //[0.00:1.00] //- 
#define EToneMappingCurveV1 6.00 //[0.00:100.00] //-

//>Skyrim Tonemap Settings<\\
#define EAdaptationMinV2 0.36 //[0.00:1.00] //- 
#define EAdaptationMaxV2 0.29 //[0.00:1.00] //-
#define EToneMappingCurveV2 8.00 //[0.00:100.00] //- 
#define EIntensityContrastV2 2.50 //[0.00:100.00] //-
#define EColorSaturationV2 3.20 //[0.00:100.00] //-
#define EToneMappingOversaturationV2 180.00 //[0.00:1000.00] //-

//>Skyrim Tonemap Settings<\\
#define EAdaptationMinV3 0.001 //[0.000:1.000] //-
#define EAdaptationMaxV3 0.025 //[0.000:1.000] //- 
#define EToneMappingCurveV3 30.00 //[0.00:100.00] //-  
#define EToneMappingOversaturationV3 111160.00 //[0.00:1000000.00] //- 

//>Skyrim Tonemap Settings<\\
#define EAdaptationMinV4 0.20 //[0.00:1.00] //-
#define EAdaptationMaxV4 0.125 //[0.000:1.000] //-
#define EBrightnessCurveV4 0.70 //[0.00:1.00] //-
#define EBrightnessMultiplierV4 0.45 //[0.00:1.00] //- 
#define EBrightnessToneMappingCurveV4 0.30 //[0.00:1.00] //-

//>Skyrim Tonemap Settings<\\
#define EAdaptationMinV5 0.08 //[0.00:1.00] //-
#define EToneMappingCurveV5 8.00 //[0.00:100.00] //- 
#define EIntensityContrastV5 3.475 //[0.000:100.000] //- 
#define EColorSaturationV5 4.00 //[0.00:100.00] //-   
#define HCompensateSatV5 2.00 //[0.00:100.00] //- 
#define EToneMappingOversaturationV5 180.00 //[0.00:1000.00] //- 

//>Skyrim Tonemap Settings<\\
#define EBrightnessV6Day 2.50 //[0.00:100.00] //-    
#define EIntensityContrastV6Day 1.50 //[0.00:100.00] //-     
#define EColorSaturationV6Day 2.00 //[0.00:100.00] //-      
#define HCompensateSatV6Day 3.00 //[0.00:100.00] //- 
#define EAdaptationMinV6Day 0.64 //[0.00:1.00] //-      
#define EAdaptationMaxV6Day 0.24 //[0.00:1.00] //-  
#define EToneMappingCurveV6Day 8.00 //[0.00:100.00] //-
#define EToneMappingOversaturationV6Day 2500.00 //[0.00:10000.00] //-   


////-------------//
///**COLORMOOD**///
//-------------////
#define USE_COLORMOOD 0 //[ColorCorrection] //-Color Mood: Applies a "mood" to the color, tinting mainly the dark colors.

//>ColorMood Settings<\\
#define fRatio 0.30 //[0.00:3.00] //-Amount of moody coloring you want
#define moodR 0.5 //[0.0:2.0] //-How strong dark red colors shall be boosted
#define moodG 1.2 //[0.0:2.0] //-How strong dark green colors shall be boosted
#define moodB 1.0 //[0.0:2.0] //-How strong dark blue colors shall be boosted


////----------------//
///**CROSSPROCESS**///
//----------------////
#define USE_CROSSPROCESS 1 //[ColorCorrection] //-Cross Processing: Simulates wrong chemistry in color processing.

//>CrossProcess Settings<\\
#define CrossContrast 0.95000 //[0.50:2.00] //-The names of these values should explain their functions
#define CrossSaturation 0.66 //[0.50:2.00] //-
#define CrossBrightness -0.01120 //[-1.000:1.000] //-[-0.300 to 0.300]
#define CrossAmount 0.051 //[0.05:1.50] //-


////------------//
///**REINHARD**///
//------------////
#define USE_REINHARD 0 //[ColorCorrection] //-Reinhard: This is the Reinhard tonemapping shader, if you are interested, google how it works.

//>Reinhard Tonemap Settings<\\
#define ReinhardWhitepoint 4.0 //[1.0:10.0] //-Point above which everything is pure white
#define ReinhardScale 0.5 //[0.0:2.0] //-Amount of applied tonemapping


////------------//
///**COLORMOD**///
//------------////
#define USE_COLORMOD 0 //[ColorCorrection] //-Colormod: Contrast, Saturation and Brightness ported from colormod.asi.

//>ColorMod Settings<\\
#define ColormodChroma 0.80 //[-1.00:2.00] //-Saturation
#define ColormodGammaR 1.05 //[-1.00:2.00] //-Gamma for Red color channel
#define ColormodGammaG 0.90 //[-1.00:2.00] //-Gamma for Green color channel
#define ColormodGammaB 0.9 //[-1.00:2.00] //-Gamma for Blue color channel
#define ColormodContrastR 1.00 //[-1.00:2.00] //-Contrast for Red color channel
#define ColormodContrastG 1.0 //[-1.00:2.00] //-Contrast for Green color channel
#define ColormodContrastB 1.0 //[-1.00:2.00] //-Contrast for Blue color channel
#define ColormodBrightnessR 0.08 //[-1.00:2.00] //-Brightness for Red color channel
#define ColormodBrightnessG 0.08 //[-1.00:2.00] //-Brightness for Green color channel
#define ColormodBrightnessB 0.08 //[-1.00:2.00] //-Brightness for Blue color channel


////--------------------//
///**SPHERICALTONEMAP**///
//--------------------////
#define USE_SPHERICALTONEMAP 0 //[ColorCorrection] //-Spherical Tonemap: Another approach on tonemapping, uses some sphere algorithms.

//>Spherical Tonemap Settings<\\
#define sphericalAmount 1.0 //[0.0:2.0] //-Amount of spherical tonemapping applied...sort of


////-------//
///**HPD**///
//-------////
#define USE_HPD 0 //[ColorCorrection] //-Haarm Peter Duiker Filmic Tonemapping: Tonemapping used in Watch Dogs, ripped from the Watch Dogs shaders themselves.


////---------------//
///**FILMICCURVE**///
//---------------////
#define USE_FILMICCURVE 0 //[ColorCorrection] //-Filmic Curve: Improved version of the well-known Uncharted 2 filmic curve, first seen in iCEnhancer 0.3.


////--------------------//
///**WATCHDOG_TONEMAP**///
//--------------------////
#define USE_WATCHDOG_TONEMAP 0 //[ColorCorrection] //-Watch Dogs Tonemap: Enables one of the numerous watch dogs tonemapping algorithms. No tweaking values.


////-----------//
///**SINCITY**///
//-----------////
#define USE_SINCITY 0 //[ColorCorrection] //-Sin City: Effect from the movie "Sin City" - everything else than red is grey.


////--------------//
///**COLORHUEFX**///
//--------------////
#define USE_COLORHUEFX 0 //[ColorCorrection] //--Color Hue FX: Desaturates everything but colors from a fixed hue mid and the range around it. Similiar to Sin City but much better. Thanks, prod80!

//>ColorHueFX Settings <\\
#define Use_COLORSAT 0 //[0:1] //-This will use original color saturation as an added limiter to the strength of the effect
#define hueMid 0.6 //[0.0:1.0] //-Hue (rotation around the color wheel) of the color which you want to keep
#define hueRange 0.1 //[0.0:1.0] //-Range of different hue's around the hueMid that will also kept. Using a max range of 1.0 will allow the reverse of the effect where it will only filter a specific hue to B&W
#define satLimit 2.9 //[0.0:4.0] //-Saturation control, better keep it higher than 0 for strong colors in contrast to the gray stuff around
#define fxcolorMix 0.8 //[0.0:1.0] //-Interpolation between the original and the effect, 0 means full original image, 1 means full grey-color image.

