shaders = 29

shader0 = ../../../shaders/guest/extras/hsm-drez-none.slang
filter_linear0 = false
srgb_framebuffer0 = true
scale_type0 = source
scale_x0 = 1
scale_y0 = 1
alias0 = "DerezedPass"

shader1 = ../../../shaders/base/cache-info-potato-params.slang
filter_linear1 = false
scale_type1 = source
scale1 = 1.0
alias1 = "InfoCachePass"

shader2 = ../../../shaders/guest/extras/hsm-fetch-drez-output.slang
filter_linear2 = false
srgb_framebuffer2 = true
scale_type2 = source
scale_x2 = 1
scale_y2 = 1

shader3 = ../../../shaders/dedither/dedither-gamma-prep-1-before.slang
alias3 = LinearGamma

shader4 = ../../../shaders/hyllian/sgenpt-mix/sgenpt-mix-pass1.slang
filter_linear4 = false
scale_type4 = source
scale4 = 1.0

shader5 = ../../../shaders/hyllian/sgenpt-mix/sgenpt-mix-pass2.slang
filter_linear5 = false
scale_type5 = source
scale5 = 1.0

shader6 = ../../../shaders/hyllian/sgenpt-mix/sgenpt-mix-pass3.slang
filter_linear6 = false
scale_type6 = source
scale6 = 1.0
alias6 = CB_Output

shader7 = ../../../shaders/hyllian/sgenpt-mix/sgenpt-mix-pass4.slang
filter_linear7 = false
scale_type7 = source
scale7 = 1.0

shader8 = ../../../shaders/hyllian/sgenpt-mix/sgenpt-mix-pass5.slang
filter_linear8 = false

shader9 = ../../../shaders/dedither/dedither-gamma-prep-2-after.slang

shader10 = ../../../shaders/guest/extras/hsm-g-sharp_resampler.slang

shader11 = ../../../shaders/guest/extras/hsm-sharpsmoother.slang
alias11 = "DeditherPass"

shader12 = ../../../shaders/base/stock.slang
# filter_linear12 = "false"
# wrap_mode12 = "clamp_to_border"
# mipmap_input12 = "false"
# float_framebuffer12 = "false"
# srgb_framebuffer12 = "true"
alias12 = XbrSource

shader13 = ../../../shaders/hyllian/crt-super-xbr/super-xbr-pass0.slang
filter_linear13 = "false"
wrap_mode13 = "clamp_to_border"
mipmap_input13 = "false"
float_framebuffer13 = "false"
srgb_framebuffer13 = "true"

shader14 = ../../../shaders/hyllian/crt-super-xbr/super-xbr-pass1.slang
filter_linear14 = "false"
wrap_mode14 = "clamp_to_border"
mipmap_input14 = "false"
alias14 = ""
float_framebuffer14 = "false"
srgb_framebuffer14 = "true"
scale_type_x14 = "source"
scale_x14 = "2.000000"
scale_type_y14 = "source"
scale_y14 = "2.000000"

shader15 = ../../../shaders/hyllian/crt-super-xbr/super-xbr-pass2.slang
filter_linear15 = "false"
wrap_mode15 = "clamp_to_border"
mipmap_input15 = "false"
alias15 = ""
float_framebuffer15 = "false"
srgb_framebuffer15 = "true"
scale_type_x15 = "source"
scale_x15 = "1.000000"
scale_type_y15 = "source"
scale_y15 = "1.000000"

shader16 = ../../../shaders/hyllian/crt-super-xbr/custom-bicubic-x.slang
filter_linear16 = "false"
wrap_mode16 = "clamp_to_border"
mipmap_input16 = "false"
alias16 = ""
float_framebuffer16 = "false"
srgb_framebuffer16 = "true"
scale_type_x16 = "source"
scale_x16 = "1.000000"
scale_type_y16 = "source"
scale_y16 = "1.000000"

shader17 = ../../../shaders/hyllian/crt-super-xbr/custom-bicubic-y.slang
filter_linear17 = false
scale_type_x17 = source
scale_x17 = 1
scale_type_y17 = source
scale_y17 = 0.5
wrap_mode17 = "clamp_to_edge"

# Color Correction with Dogway's awesome Grade shader
# Grade is after Afterglow so that brightening the black level does not break the afterglow
shader18 = ../../../shaders/dogway/hsm-grade.slang
filter_linear18 = false
scale_type18 = source
scale18 = 1.0
alias18 = "ColorCorrectPass"

shader19 = ../../../shaders/base/stock.slang
filter_linear19 = true
scale_type19 = source
scale_x19 = 1.0
scale_y19 = 1.0
alias19 = "PrePass"
mipmap_input19 = true

shader20 = ../../../shaders/guest/hsm-avg-lum.slang
filter_linear20 = true
scale_type20 = source
scale20 = 1.0
mipmap_input20 = true
alias20 = "AvgLumPass"

# Pass referenced by subsequent blurring passes and crt pass
shader21 = ../../../shaders/guest/hsm-interlace-and-linearize.slang
filter_linear21 = true
scale_type21 = source
scale21 = 1.0
float_framebuffer21 = true
alias21 = "LinearizePass"

shader22 = ../../../shaders/guest/hsm-gaussian_horizontal.slang
filter_linear22 = true
scale_type_x22 = absolute
scale_x22 = 800.0
scale_type_y22 = source
scale_y22 = 1.0 
float_framebuffer22 = true

shader23 = ../../../shaders/guest/hsm-gaussian_vertical.slang
filter_linear23 = true
scale_type_x23 = absolute
scale_x23 = 800.0
scale_type_y23 = absolute
scale_y23 = 600.0
float_framebuffer23 = true
alias23 = GlowPass

shader24 = ../../../shaders/guest/hsm-bloom_horizontal.slang
filter_linear24 = true
scale_type_x24 = absolute
scale_x24 = 800.0
scale_type_y24 = absolute
scale_y24 = 600.0 
float_framebuffer24 = true

shader25 = ../../../shaders/guest/hsm-bloom_vertical.slang
filter_linear25 = true
scale_type_x25 = source
scale_x25 = 1.0
scale_type_y25 = source
scale_y25 = 1.0
float_framebuffer25 = true
alias25 = BloomPass

shader26 = ../../../shaders/guest/hsm-crt-guest-advanced-potato.slang
filter_linear26 = true
scale_type26 = viewport
scale_x26 = 1.0
scale_y26 = 1.0
float_framebuffer26 = true

shader27 = ../../../shaders/guest/hsm-deconvergence-potato.slang
filter_linear27 = true
scale_type27 = viewport
scale_x27 = 1.0
scale_y27 = 1.0
float_framebuffer27 = true
alias27 = "CRTPass"

shader28 = ../../../shaders/base/post-crt-prep-potato.slang
mipmap_input28 = true
scale_type28 = viewport
float_framebuffer28 = true
alias28 = "PostCRTPass"

# Textures Potato
# Define textures to be used by the different passes
textures = "SamplerLUT1;SamplerLUT2;SamplerLUT3;SamplerLUT4;ScreenPlacementImage;BackgroundImage;BackgroundVertImage"

SamplerLUT1 = ../../../shaders/guest/lut/trinitron-lut.png
SamplerLUT1_linear = true 
SamplerLUT2 = ../../../shaders/guest/lut/inv-trinitron-lut.png
SamplerLUT2_linear = true 
SamplerLUT3 = ../../../shaders/guest/lut/nec-lut.png
SamplerLUT3_linear = true
SamplerLUT4 = ../../../shaders/guest/lut/ntsc-lut.png
SamplerLUT4_linear = true

ScreenPlacementImage = ../../../shaders/textures/Placeholder_Transparent_16x16.png
ScreenPlacementImage_linear = false

BackgroundImage = ../../../shaders/textures/Baked_Frame_Carbonfiber_Background.png
BackgroundImage_linear = true
BackgroundImage_mipmap = 1

BackgroundVertImage = ../../../shaders/textures/Baked_Frame_Carbonfiber_Background_Vert.png
BackgroundVertImage_linear = true
BackgroundVertImage_mipmap = 1

# Parameters
HSM_ASPECT_RATIO_MODE = 1

# Use for matching vanilla GDV-Advanced
# HSM_ASPECT_RATIO_MODE = 6
# HSM_CURVATURE_MODE = 0

# SUPER-XBR GDV Parameters
SGPT_BLEND_OPTION = 1

SHARPSMOOTHER_ON = 1
max_w = 0.05
min_w = 0
smoot = 0.4
lumad = 0.5
mtric = 0.3

SUPERXBR_ON = 1

SHARPEN = 1

HSM_CORE_RES_SAMPLING_MULT_SCANLINE_DIR = 600
HSM_CORE_RES_SAMPLING_MULT_OPPOSITE_DIR = 100
HSM_DOWNSAMPLE_BLUR_SCANLINE_DIR = 0
HSM_DOWNSAMPLE_BLUR_OPPOSITE_DIR = 0

# gamma_c = 0.9
# gsl = -1
# scanline1 = 3
# shadowMask = 3
# maskDark = 0.4
# maskLight = 1.2
# mask_gamma = 4

# Mask Size is Auto, so it will look the same at 1080p and 4K
masksize = 0
