From ee7e1a9d901a89635f342f427d65fd49291de106 Mon Sep 17 00:00:00 2001 From: Merlin1809 Date: Wed, 27 Aug 2025 01:53:06 +0200 Subject: [PATCH] Fix dragon death beams, merge xonks latest commits --- shaders/dimensions/DH_translucent.fsh | 21 ++- shaders/dimensions/all_particles.fsh | 8 +- shaders/dimensions/all_particles.vsh | 11 +- shaders/dimensions/all_solid.fsh | 6 +- shaders/dimensions/all_translucent.fsh | 46 +++-- shaders/dimensions/all_translucent.vsh | 6 +- shaders/dimensions/begin.csh | 4 +- shaders/dimensions/composite.fsh | 18 +- shaders/dimensions/composite1.fsh | 15 +- shaders/dimensions/composite3.fsh | 113 ++++++------ shaders/dimensions/composite5.fsh | 4 + shaders/dimensions/final.fsh | 4 + .../dimensions/fogBehindTranslucent_pass.fsh | 5 +- shaders/lang/en_us.lang | 174 +++++++++++------- shaders/lib/Shadows.glsl | 9 +- shaders/lib/settings.glsl | 35 ++-- shaders/lib/specular.glsl | 68 ++++--- shaders/shaders.properties | 31 ++-- shaders/world1/shadow.fsh | 10 - shaders/world1/shadow.vsh | 20 +- 20 files changed, 365 insertions(+), 243 deletions(-) diff --git a/shaders/dimensions/DH_translucent.fsh b/shaders/dimensions/DH_translucent.fsh index 77b3908..3a9abf7 100644 --- a/shaders/dimensions/DH_translucent.fsh +++ b/shaders/dimensions/DH_translucent.fsh @@ -1,4 +1,9 @@ #include "/lib/settings.glsl" + +#ifdef CUSTOM_MOON_ROTATION + #include "/lib/SSBOs.glsl" +#endif + #include "/lib/util.glsl" #include "/lib/res_params.glsl" #include "/lib/color_transforms.glsl" @@ -162,11 +167,13 @@ float invLdFast(float linearDepth) { return (dhFarPlane * (dhNearPlane - linearDepth)) / ((dhNearPlane - dhFarPlane) * linearDepth); } +#define FORWARD_SSR_QUALITY 30 // [0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 200 300 400 500] + vec3 rayTrace(vec3 dir, vec3 position, float dither, float fresnel) { float biasAmount = 0.0000015; - float quality = float(SSR_STEPS_DH); + float quality = float(FORWARD_SSR_QUALITY); vec3 clipPosition = DH_toClipSpace3(position); float rayLength = ((position.z + dir.z * dhFarPlane*sqrt(3.)) > -dhNearPlane) ? @@ -189,7 +196,9 @@ vec3 rayTrace(vec3 dir, vec3 position, float dither, float fresnel) { float maxZ = spos.z; for (int i = 0; i <= int(quality); i++) { - if(spos.x < 0 || spos.x > 1 || spos.y < 0 || spos.y > 1) return vec3(1.1); + #if DEFERRED_SSR_QUALITY != 1 + if(spos.x < 0 || spos.x > 1 || spos.y < 0 || spos.y > 1) return vec3(1.1); + #endif float sampleDepth = sqrt(texelFetch2D(colortex12, ivec2(spos.xy / (texelSize * 4.0)), 0).a / 65000.0); float sp = invLdFast(sampleDepth*dhFarPlane); @@ -266,9 +275,11 @@ vec3 applyBump(mat3 tbnMatrix, vec3 bump, float puddle_values){ } #define FORWARD_SPECULAR -#define FORWARD_ENVIORNMENT_REFLECTION #define FORWARD_BACKGROUND_REFLECTION -#define FORWARD_ROUGH_REFLECTION +// #define FORWARD_ROUGH_REFLECTION + +#ifdef FORWARD_ROUGH_REFLECTION +#endif /* RENDERTARGETS:2,7,14 */ void main() { @@ -426,7 +437,7 @@ if (gl_FragCoord.x * texelSize.x < 1.0 && gl_FragCoord.y * texelSize.y < 1.0 ) #ifdef SNELLS_WINDOW if(isEyeInWater == 1) fresnel = pow(clamp(1.5 + normalDotEye,0.0,1.0), 25.0); #endif - #if defined FORWARD_ENVIORNMENT_REFLECTION && defined DH_SCREENSPACE_REFLECTIONS + #if FORWARD_SSR_QUALITY > 0 && defined DH_SCREENSPACE_REFLECTIONS vec3 rtPos = rayTrace(reflectedVector, viewPos, interleaved_gradientNoise_temporal(), fresnel); if (rtPos.z < 0.99999){ vec3 previousPosition = mat3(gbufferModelViewInverse) * DH_toScreenSpace(rtPos) + gbufferModelViewInverse[3].xyz + cameraPosition-previousCameraPosition; diff --git a/shaders/dimensions/all_particles.fsh b/shaders/dimensions/all_particles.fsh index 8b81ff4..09e8131 100644 --- a/shaders/dimensions/all_particles.fsh +++ b/shaders/dimensions/all_particles.fsh @@ -1,5 +1,9 @@ #include "/lib/settings.glsl" +#if defined CUSTOM_MOON_ROTATION || defined END_ISLAND_LIGHT + #include "/lib/SSBOs.glsl" +#endif + // #if defined END_SHADER || defined NETHER_SHADER // #undef IS_LPV_ENABLED // #endif @@ -139,10 +143,6 @@ float encodeVec2(float x,float y){ return encodeVec2(vec2(x,y)); } -#if defined CUSTOM_MOON_ROTATION || defined END_ISLAND_LIGHT - #include "/lib/SSBOs.glsl" -#endif - // #undef BASIC_SHADOW_FILTER #if defined OVERWORLD_SHADER float ComputeShadowMap(inout vec3 directLightColor, vec3 playerPos, float maxDistFade){ diff --git a/shaders/dimensions/all_particles.vsh b/shaders/dimensions/all_particles.vsh index 04180ce..9e299da 100644 --- a/shaders/dimensions/all_particles.vsh +++ b/shaders/dimensions/all_particles.vsh @@ -103,9 +103,9 @@ void main() { bool istopv = worldpos.y > cameraPosition.y + 5.0 && lmtexcoord.w > 0.99; if(!istopv){ - worldpos.xyz -= cameraPosition - vec3(2.0,0.0,2.0) * min(max(eyeBrightnessSmooth.y/240.0-0.95,0.0)*11.0,1.0); + worldpos.xyz -= cameraPosition - vec3(2.0,0.0,2.0) * min(max(clamp(eyeBrightnessSmooth.y/240.0,0,1)-0.95,0)/0.05,1); }else{ - worldpos.xyz -= cameraPosition ; + worldpos.xyz -= cameraPosition; } position = mat3(gbufferModelView) * worldpos + gbufferModelView[3].xyz; @@ -136,10 +136,11 @@ void main() { #endif + #ifdef TAA_UPSCALING + gl_Position.xy = gl_Position.xy * RENDER_SCALE + RENDER_SCALE * gl_Position.w - gl_Position.w; + #endif + #ifndef WEATHER - #ifdef TAA_UPSCALING - gl_Position.xy = gl_Position.xy * RENDER_SCALE + RENDER_SCALE * gl_Position.w - gl_Position.w; - #endif #ifdef TAA gl_Position.xy += offsets[framemod8] * gl_Position.w*texelSize; #endif diff --git a/shaders/dimensions/all_solid.fsh b/shaders/dimensions/all_solid.fsh index 0aa812d..71b71b7 100644 --- a/shaders/dimensions/all_solid.fsh +++ b/shaders/dimensions/all_solid.fsh @@ -185,8 +185,8 @@ float encodeVec2(float x,float y){ } #ifdef MC_NORMAL_MAP - vec3 applyBump(mat3 tbnMatrix, vec3 bump, float puddle_values){ - float bumpmult = clamp(puddle_values,0.0,1.0); + vec3 applyBump(mat3 tbnMatrix, vec3 bump){ + float bumpmult = NORMAL_MAP_MULT; bump = bump * vec3(bumpmult, bumpmult, bumpmult) + vec3(0.0f, 0.0f, 1.0f - bumpmult); return normalize(bump*tbnMatrix); } @@ -594,7 +594,7 @@ void main() { NormalTex.xy = NormalTex.xy * 2.0-1.0; NormalTex.z = sqrt(max(1.0 - dot(NormalTex.xy, NormalTex.xy), 0.0)); - normal = applyBump(tbnMatrix, NormalTex.xyz, 1.0); + normal = applyBump(tbnMatrix, NormalTex.xyz); #endif //////////////////////////////// //////////////////////////////// diff --git a/shaders/dimensions/all_translucent.fsh b/shaders/dimensions/all_translucent.fsh index 9c34fa1..d31d1bc 100644 --- a/shaders/dimensions/all_translucent.fsh +++ b/shaders/dimensions/all_translucent.fsh @@ -156,20 +156,24 @@ uniform float dhFarPlane; #endif #define FORWARD_SPECULAR -#define FORWARD_ENVIORNMENT_REFLECTION +#define FORWARD_SSR_QUALITY 30 // [0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 200 300 400 500] #define FORWARD_BACKGROUND_REFLECTION -#define FORWARD_ROUGH_REFLECTION +// #define FORWARD_ROUGH_REFLECTION #ifdef FORWARD_SPECULAR #endif -#ifdef FORWARD_ENVIORNMENT_REFLECTION +#if FORWARD_SSR_QUALITY > -1 #endif #ifdef FORWARD_BACKGROUND_REFLECTION #endif #ifdef FORWARD_ROUGH_REFLECTION #endif +#include "/lib/blocks.glsl" +#include "/lib/lpv_blocks.glsl" +#include "/lib/lpv_buffer.glsl" + #include "/lib/specular.glsl" #include "/lib/diffuse_lighting.glsl" @@ -230,8 +234,8 @@ vec3 getParallaxDisplacement(vec3 waterPos, vec3 playerPos) { return parallaxPos; } -vec3 applyBump(mat3 tbnMatrix, vec3 bump, float puddle_values, vec3 rippleBump){ - float bumpmult = puddle_values; +vec3 applyBump(mat3 tbnMatrix, vec3 bump, float mult, vec3 rippleBump){ + float bumpmult = mult; bump = bump * bumpmult + vec3(0.0f, 0.0f, 1.0f - bumpmult); #if defined PHYSICSMOD_OCEAN_SHADER && defined PHYSICS_OCEAN @@ -521,14 +525,19 @@ if (gl_FragCoord.x * texelSize.x < 1.0 && gl_FragCoord.y * texelSize.y < 1.0 ) #endif #endif - #if defined DISTANT_HORIZONS && DH_CHUNK_FADING > 0 + #if defined DISTANT_HORIZONS && DH_CHUNK_FADING > 0 && !defined LIGHTNING float ditherFade = smoothstep(0.98 * far, 1.03 * far, viewDist); - if (step(ditherFade, R2_dither()) == 0.0 && LIGHTNING_BOLT == 0.0) discard; + if (step(ditherFade, R2_dither()) == 0.0) discard; #endif #ifdef LIGHTNING - if (LIGHTNING_BOLT > 0.0) Albedo = 2.5 * vec3(1.0,2.2,6.5); + if (LIGHTNING_BOLT > 0.0){ + Albedo = 2.5 * vec3(1.0,2.2,6.5); + } else { + Albedo *= color.a; + gl_FragData[0].a = color.a; + } #endif #ifdef ENTITIES @@ -654,9 +663,11 @@ if (gl_FragCoord.x * texelSize.x < 1.0 && gl_FragCoord.y * texelSize.y < 1.0 ) #if defined PHYSICSMOD_OCEAN_SHADER && defined PHYSICS_OCEAN rippleBump *= physics_localWaviness; - normal = mix(applyBump(tbnMatrix, NormalTex.xyz, 1.0, rippleBump), applyBump(tbnMatrix, NormalTex.xyz, PHYSICS_OCEAN_TRANSITION, rippleBump), smoothstep(0.0, 0.1, physics_localWaviness)); + float bumpmult = mix(isWater ? 1.0 : NORMAL_MAP_MULT, isWater ? PHYSICS_OCEAN_TRANSITION : NORMAL_MAP_MULT, smoothstep(0.0, 0.1, physics_localWaviness)); + + normal = applyBump(tbnMatrix, NormalTex.xyz, bumpmult, rippleBump); #else - normal = applyBump(tbnMatrix, NormalTex.xyz, 1.0, rippleBump); + normal = applyBump(tbnMatrix, NormalTex.xyz, isWater ? 1.0 : NORMAL_MAP_MULT, rippleBump); #endif worldSpaceNormal = viewToWorld(normal); @@ -758,7 +769,12 @@ if (gl_FragCoord.x * texelSize.x < 1.0 && gl_FragCoord.y * texelSize.y < 1.0 ) #ifdef END_SHADER - float vortexBounds = clamp(vortexBoundRange - length(worldPos), 0.0,1.0); + #ifdef END_LIGHTNING + float vortexBounds = clamp(vortexBoundRange - length(feetPlayerPos+cameraPosition), 0.0,1.0); + #else + float vortexBounds = 1.0; + #endif + vec3 lightPos = LightSourcePosition(worldPos, cameraPosition,vortexBounds); float lightningflash = texelFetch2D(colortex4,ivec2(1,1),0).x/150.0; @@ -817,7 +833,13 @@ if (gl_FragCoord.x * texelSize.x < 1.0 && gl_FragCoord.y * texelSize.y < 1.0 ) const vec3 lpvPos = vec3(0.0); #endif - Indirect_lighting += doBlockLightLighting( vec3(TORCH_R,TORCH_G,TORCH_B), lightmap.x, feetPlayerPos, lpvPos); + #ifdef LIGHTNING + vec3 lightColor = vec3(1.0); + #else + vec3 lightColor = vec3(TORCH_R,TORCH_G,TORCH_B); + #endif + + Indirect_lighting += doBlockLightLighting(lightColor, lightmap.x, feetPlayerPos, lpvPos); vec4 flashLightSpecularData = vec4(0.0); #ifdef FLASHLIGHT diff --git a/shaders/dimensions/all_translucent.vsh b/shaders/dimensions/all_translucent.vsh index 8763bc3..6460219 100644 --- a/shaders/dimensions/all_translucent.vsh +++ b/shaders/dimensions/all_translucent.vsh @@ -240,7 +240,7 @@ void main() { viewVector = normalize(tbnMatrix * viewVector); - color = vec4(gl_Color.rgb, 1.0); + color = gl_Color; #ifdef OVERWORLD_SHADER lightCol.rgb = texelFetch2D(colortex4,ivec2(6,37),0).rgb; @@ -267,10 +267,10 @@ void main() { #endif LIGHTNING_BOLT = 0.0; - #ifdef ENTITIES + #ifdef LIGHTNING + normalMat.a = 0.5; if(entityId == ENTITY_LIGHTNING){ LIGHTNING_BOLT = 1.0; - normalMat.a = 0.50; } #endif diff --git a/shaders/dimensions/begin.csh b/shaders/dimensions/begin.csh index f33a1c7..af46557 100644 --- a/shaders/dimensions/begin.csh +++ b/shaders/dimensions/begin.csh @@ -76,8 +76,6 @@ const ivec3 workGroups = ivec3(1, 1, 1); #else if (sunElevation > 0.0) return shadowModelView; #endif - #else - localLightDir = normalize(END_LIGHT_POS); #endif #endif @@ -144,7 +142,7 @@ void main() { #endif #if defined END_ISLAND_LIGHT && defined END_SHADER - customShadowMatrixSSBO = BuildShadowViewMatrix(vec3(0.0, 1.0, 0.0)); + customShadowMatrixSSBO = BuildShadowViewMatrix(normalize(END_LIGHT_POS)); customShadowPerspectiveSSBO = createPerspectiveMatrix(); #endif } diff --git a/shaders/dimensions/composite.fsh b/shaders/dimensions/composite.fsh index 69fe849..88e1beb 100644 --- a/shaders/dimensions/composite.fsh +++ b/shaders/dimensions/composite.fsh @@ -49,6 +49,7 @@ uniform vec2 texelSize; uniform float frameTimeCounter; uniform float rainStrength; uniform int frameCounter; +uniform ivec2 eyeBrightnessSmooth; uniform mat4 gbufferModelViewInverse; @@ -74,6 +75,8 @@ uniform float near; uniform float dhFarPlane; uniform float dhNearPlane; +#include "/lib/Shadows.glsl" + #define ffstep(x,y) clamp((y - x) * 1e35,0.0,1.0) #define diagonal3(m) vec3((m)[0].x, (m)[1].y, m[2].z) #define projMAD(m, v) (diagonal3(m) * (v) + (m)[3].xyz) @@ -256,7 +259,7 @@ float convertHandDepth_2(in float depth, bool hand) { } vec2 SSAO( - vec3 viewPos, vec3 normal, vec3 flatnormal, bool hand, bool leaves, float noise + vec3 viewPos, vec3 normal, vec3 flatnormal, bool hand, float noise ){ int samples = 4; float occlusion = 0.0; @@ -360,6 +363,8 @@ void main() { vec2 lightmap = dataUnpacked1.yz; + float lightLeakFix = clamp(pow(eyeBrightnessSmooth.y/240. + lightmap.y,2.0) ,0.0,1.0); + gl_FragData[1] = vec4(0.0,0.0,0.0, texelFetch2D(colortex14,ivec2((floor(gl_FragCoord.xy)/VL_RENDER_RESOLUTION*texelSize+0.5*texelSize)/texelSize),0).a); @@ -410,7 +415,7 @@ void main() { if(z >= 1.0) FlatNormals = normal; - vec2 SSAO_SSS = SSAO(viewPos, worldToView(normal),worldToView(FlatNormals), hand, isLeaf, noise); + vec2 SSAO_SSS = SSAO(viewPos, worldToView(normal),worldToView(FlatNormals), hand, noise); #ifndef OLD_INDIRECT_SSS SSAO_SSS.y = clamp(SSAO_SSS.y + 0.5 * lightmap.y*lightmap.y,0.0,1.0); #endif @@ -455,8 +460,6 @@ void main() { #endif float maxshadowfilt = Max_Shadow_Filter_Radius; - if(lightmap.y < 0.1) maxshadowfilt = min(maxshadowfilt, minshadowfilt); - #ifdef BASIC_SHADOW_FILTER if (LabSSS > 0.0 && NdotL < 0.001){ minshadowfilt = 50; @@ -470,6 +473,11 @@ void main() { #ifdef Variable_Penumbra_Shadows // if (LabSSS > -1) { + + #if LIGHTLEAKFIX_MODE == 1 + if(!hand) GriAndEminShadowFix(feetPlayerPos, FlatNormals, lightLeakFix); + #endif + #ifdef OVERWORLD_SHADER #ifdef CUSTOM_MOON_ROTATION vec3 projectedShadowPosition = mat3(customShadowMatrixSSBO) * feetPlayerPos + customShadowMatrixSSBO[3].xyz; @@ -526,7 +534,7 @@ void main() { // vec2 offsetS = SpiralSample(i, 7, 8, noise) * 0.5; vec2 offsetS = CleanSample(i, VPS_Search_Samples - 1, noise) * 0.5; - float weight = 3.0 + (i+noise) *rdMul/SHADOW_FILTER_SAMPLE_COUNT*shadowMapResolution*distortFactor/2.7; + float weight = 3.0 + (i+noise) * rdMul/SHADOW_FILTER_SAMPLE_COUNT*shadowMapResolution*distortFactor/2.7; float d = texelFetch2D(shadow, ivec2((projectedShadowPosition.xy+offsetS*rdMul)*shadowMapResolution),0).x; float b = smoothstep(weight*diffthresh/2.0, weight*diffthresh, projectedShadowPosition.z - d); diff --git a/shaders/dimensions/composite1.fsh b/shaders/dimensions/composite1.fsh index 300bc7d..a1e1369 100644 --- a/shaders/dimensions/composite1.fsh +++ b/shaders/dimensions/composite1.fsh @@ -68,7 +68,7 @@ uniform float rainStrength; flat varying vec3 sunCol; - #if Sun_specular_Strength != 0 + #if SUN_SPECULAR_MULT != 0 #define LIGHTSOURCE_REFLECTION #endif @@ -210,13 +210,13 @@ float convertHandDepth_2(in float depth, bool hand) { #endif #define DEFERRED_SPECULAR -#define DEFERRED_ENVIORNMENT_REFLECTION +#define DEFERRED_SSR_QUALITY 30 // [0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 200 300 400 500] #define DEFERRED_BACKGROUND_REFLECTION #define DEFERRED_ROUGH_REFLECTION #ifdef DEFERRED_SPECULAR #endif -#ifdef DEFERRED_ENVIORNMENT_REFLECTION +#if DEFERRED_SSR_QUALITY > -1 #endif #ifdef DEFERRED_BACKGROUND_REFLECTION #endif @@ -1151,7 +1151,7 @@ void main() { vec3 shadowPlayerPos = mat3(gbufferModelViewInverse) * viewPos + gbufferModelViewInverse[3].xyz; #if LIGHTLEAKFIX_MODE == 1 - if(!hand) GriAndEminShadowFix(shadowPlayerPos, FlatNormals, vanilla_AO, lightmap.y, lightLeakFix); + if(!hand) GriAndEminShadowFix(shadowPlayerPos, FlatNormals, lightLeakFix); #endif #ifdef OVERWORLD_SHADER @@ -1256,7 +1256,12 @@ void main() { #endif #ifdef END_SHADER - float vortexBounds = clamp(vortexBoundRange - length(feetPlayerPos+cameraPosition), 0.0,1.0); + #ifdef END_LIGHTNING + float vortexBounds = clamp(vortexBoundRange - length(feetPlayerPos+cameraPosition), 0.0,1.0); + #else + float vortexBounds = 1.0; + #endif + vec3 lightPos = LightSourcePosition(feetPlayerPos+cameraPosition, cameraPosition,vortexBounds); float lightningflash = texelFetch2D(colortex4,ivec2(1,1),0).x/150.0; diff --git a/shaders/dimensions/composite3.fsh b/shaders/dimensions/composite3.fsh index 176fbb0..284abd8 100644 --- a/shaders/dimensions/composite3.fsh +++ b/shaders/dimensions/composite3.fsh @@ -246,56 +246,61 @@ vec2 clampUV(in vec2 uv, vec2 texcoord){ return clamp(mix(uv, texcoord, vignette),0.0,0.9999999); } -vec3 doRefractionEffect( inout vec2 texcoord, vec2 normal, float linearDistance, bool isReflectiveEntity, bool underwater){ - - // make the tangent space normals match the directions of the texcoord UV, this greatly improves the refraction effect. - vec2 UVNormal = vec2(normal.x,-normal.y); - - float refractionMult = 0.5 / (1.0 + pow(linearDistance,0.8) * (underwater ? 0.1 : 1.0)); - float diffractionMult = 0.035; - float smudgeMult = 1.0; - if(isReflectiveEntity) refractionMult *= 0.5; - - // for diffraction, i wanted to know *when* normals were at an angle - float clampValue = 0.2; - vec2 abberationOffset = clamp(UVNormal, -clampValue, clampValue) / clampValue * diffractionMult; - - #ifdef REFRACTION_SMUDGE - vec2 directionalSmudge = abberationOffset * (blueNoise()-0.5) * smudgeMult; - #else - vec2 directionalSmudge = vec2(0.0); - #endif - - vec2 refractedUV_no_offset = clampUV(texcoord - (UVNormal + directionalSmudge)*refractionMult, texcoord); - vec2 refractedUV = refractedUV_no_offset; - - - #ifdef FAKE_DISPERSION_EFFECT - refractionMult *= min( decodeVec2(texelFetch2D(colortex11, ivec2(clampUV(texcoord - ((UVNormal + abberationOffset) + directionalSmudge)*refractionMult,texcoord)/texelSize),0).b).g, - decodeVec2(texelFetch2D(colortex11, ivec2(clampUV(texcoord + ((UVNormal + abberationOffset) + directionalSmudge)*refractionMult,texcoord)/texelSize),0).b).g ) > 0.0 ? 1.0 : 0.0; - #else - refractionMult *= decodeVec2(texelFetch2D(colortex11, ivec2(refractedUV_no_offset/texelSize),0).b).g > 0.0 ? 1.0 : 0.0; - #endif - +vec3 doRefractionEffect( inout vec2 passTexcoord, vec2 normal, float linearDistance, bool isReflectiveEntity, bool underwater){ + // correct normal directions to match texcoord directions (right facing X, up facing Y) + normal.y = -normal.y; + vec2 texcoord = passTexcoord; vec3 color = vec3(0.0); - #ifdef FAKE_DISPERSION_EFFECT - //// RED - refractedUV = clampUV(texcoord - ((UVNormal + abberationOffset) + directionalSmudge)*refractionMult,texcoord); - color.r = texture2D(colortex3, refractedUV).r; - //// GREEN - refractedUV = clampUV(texcoord - (UVNormal + directionalSmudge)*refractionMult,texcoord); - color.g = texture2D(colortex3, refractedUV).g; - //// BLUE - refractedUV = clampUV(texcoord - ((UVNormal - abberationOffset) + directionalSmudge)*refractionMult,texcoord); - color.b = texture2D(colortex3, refractedUV).b; + float refractAmount = float(FAKE_REFRACTION_AMOUNT)/4.0; + float dispersionAmount = float(FAKE_DISPERSION_AMOUNT)/4.0; + float smudgeAmount = float(REFRACTION_SMUDGE_AMOUNT)/4.0; + + refractAmount *= 0.5 / (1.0 + pow(linearDistance,0.8) * (underwater ? 0.1 : 1.0)); + if(isReflectiveEntity) refractAmount *= 0.5; + + dispersionAmount *= 0.035; + smudgeAmount *= 0.035; + + vec2 dispersion = (clamp(normal, -0.2, 0.2) / 0.2); + #if REFRACTION_SMUDGE_AMOUNT > 0 + vec2 smudge = smudgeAmount * dispersion * (blueNoise()-0.5); #else - color = texture2D(colortex3, refractedUV_no_offset).rgb; + vec2 smudge = vec2(0.0, 0.0); #endif - texcoord = refractedUV_no_offset; + dispersion *= dispersionAmount; + + #if FAKE_DISPERSION_AMOUNT > 0 + // do not offset texcoord if alpha is 1.0 + refractAmount *= min( decodeVec2(texelFetch2D(colortex11, ivec2(clampUV(texcoord - ((normal + dispersion) + smudge)*refractAmount, texcoord)/texelSize),0).b).g, + decodeVec2(texelFetch2D(colortex11, ivec2(clampUV(texcoord - ((normal - dispersion) + smudge)*refractAmount, texcoord)/texelSize),0).b).g ) > 0.0 ? 1.0 : 0.0; + + // create offsets + vec2 offsetTexcoord = clampUV(texcoord - (normal + smudge)*refractAmount, texcoord); + passTexcoord = offsetTexcoord; + + // sample color with offsetted texcoord. in this case, the red and blue channels have offsets in opposite directions for a dispersion effect. + color.g = texture2D(colortex3, offsetTexcoord).g; + + offsetTexcoord = clampUV(texcoord - ((normal + dispersion) + smudge)*refractAmount, texcoord); + color.r = texture2D(colortex3, offsetTexcoord).r; + + offsetTexcoord = clampUV(texcoord - ((normal - dispersion) + smudge)*refractAmount, texcoord); + color.b = texture2D(colortex3, offsetTexcoord).b; + #else + // do not offset texcoord if alpha is 1.0 + refractAmount *= decodeVec2(texelFetch2D(colortex11, ivec2(clampUV(texcoord - (normal + smudge)*refractAmount, texcoord)/texelSize),0).b).g > 0.0 ? 1.0 : 0.0; + + // create offsets + vec2 offsetTexcoord = clampUV(texcoord - (normal + smudge)*refractAmount, texcoord); + passTexcoord = offsetTexcoord; + + // sample color with distorted texcoords + color.rgb = texture2D(colortex3, offsetTexcoord).rgb; + #endif return color; } @@ -454,7 +459,7 @@ void blendAllFogTypes( inout vec3 color, inout float bloomyFogMult, vec4 volumet float fogfade = 1.0 - max((1.0 - linearDistance / min(far, 16.0*7.0) ),0); color.rgb += (transmittance2 * scatterCoef) * fogfade; - bloomyFogMult *= 0.5; + bloomyFogMult *= dot(transmittance,vec3(0.3333))*0.5; } /// blend volumetrics @@ -510,7 +515,6 @@ void main() { bool hand = depth < 0.56; float z = depth; - float z2 = texture2D(depthtex1, texcoord).x; float frDepth = linearize(z); float swappedDepth = z; @@ -542,11 +546,14 @@ void main() { float linearDistance_cylinder = length(playerPos.xz); vec3 playerPos_normalized = normalize(playerPos); - vec3 viewPos_alt = toScreenSpace(vec3(texcoord/RENDER_SCALE, z2)); - vec3 playerPos_alt = mat3(gbufferModelViewInverse) * viewPos_alt + gbufferModelViewInverse[3].xyz; - float linearDistance_cylinder_alt = length(playerPos_alt.xz); + #ifndef DISTANT_HORIZONS + float z2 = texture2D(depthtex1, texcoord).x; + vec3 viewPos_alt = toScreenSpace(vec3(texcoord/RENDER_SCALE, z2)); + vec3 playerPos_alt = mat3(gbufferModelViewInverse) * viewPos_alt + gbufferModelViewInverse[3].xyz; + float linearDistance_cylinder_alt = length(playerPos_alt.xz); + #endif - float lightleakfix = clamp(pow(eyeBrightnessSmooth.y/240.,2) ,0.0,1.0); + float lightleakfix = clamp(pow(eyeBrightnessSmooth.y/240.,2.) ,0.0,1.0); float lightleakfixfast = clamp(eyeBrightness.y/240.,0.0,1.0); ////// --------------- UNPACK OPAQUE GBUFFERS --------------- ////// @@ -592,10 +599,10 @@ void main() { ////// --------------- MAIN COLOR BUFFER ////// --------------- distort texcoords as a refraction effect vec2 refractedCoord = texcoord; - #ifdef FAKE_REFRACTION_EFFECT + #if FAKE_REFRACTION_AMOUNT > 0 vec3 color = doRefractionEffect(refractedCoord, tangentNormals.xy, linearDistance, isReflectiveEntity, isWater && isEyeInWater == 1); #else - vec3 color = texture2D(colortex3, refractedCoord).rgb; + vec3 color = texture2D(colortex3, texcoord).rgb; #endif ////// --------------- lightning effect @@ -751,7 +758,7 @@ void main() { #endif borderFog *= BorderFogIntensity; #if !defined DISTANT_HORIZONS - color = mix(color, borderFog.rgb, getBorderFogDensity(linearDistance_cylinder_alt, normalize(playerPos_alt), z2 >= 1.0 || TranslucentShader.a <= 0)); + if(!isWater) color = mix(color, borderFog.rgb, getBorderFogDensity(linearDistance_cylinder_alt, normalize(playerPos_alt), z2 >= 1.0 || TranslucentShader.a <= 0)); #endif #else vec4 borderFog = vec4(0.0); @@ -787,7 +794,7 @@ void main() { // blend all fog types. volumetric fog, volumetric clouds, distance based fogs for lava, powdered snow, blindness, and darkness. blendAllFogTypes(color, bloomyFogMult, temporallyFilteredVL, linearDistance, playerPos_normalized, cameraPosition, isSky, isLightning); -////// --------------- RAINBOWS + ////// --------------- RAINBOWS #if RAINBOW > 0 && defined OVERWORLD_SHADER #if RAINBOW > 1 diff --git a/shaders/dimensions/composite5.fsh b/shaders/dimensions/composite5.fsh index 08ee8c5..1cfb16e 100644 --- a/shaders/dimensions/composite5.fsh +++ b/shaders/dimensions/composite5.fsh @@ -1,6 +1,10 @@ #include "/lib/settings.glsl" #include "/lib/res_params.glsl" +#ifdef CUSTOM_MOON_ROTATION + #include "/lib/SSBOs.glsl" +#endif + /* const int colortex0Format = RGBA16F; // low res clouds (deferred->composite2) + low res VL (composite5->composite15) const int colortex1Format = RGBA16; // terrain gbuffer (gbuffer->composite2) diff --git a/shaders/dimensions/final.fsh b/shaders/dimensions/final.fsh index df1faf3..7451fcc 100644 --- a/shaders/dimensions/final.fsh +++ b/shaders/dimensions/final.fsh @@ -1,5 +1,9 @@ #include "/lib/settings.glsl" +#ifdef CUSTOM_MOON_ROTATION + #include "/lib/SSBOs.glsl" +#endif + uniform sampler2D colortex7; uniform sampler2D colortex5; uniform sampler2D colortex6; diff --git a/shaders/dimensions/fogBehindTranslucent_pass.fsh b/shaders/dimensions/fogBehindTranslucent_pass.fsh index 7b22345..8d9c4a9 100644 --- a/shaders/dimensions/fogBehindTranslucent_pass.fsh +++ b/shaders/dimensions/fogBehindTranslucent_pass.fsh @@ -229,7 +229,7 @@ vec4 waterVolumetrics( vec3 rayStart, vec3 rayEnd, float estEndDepth, float estS if(shadow2D(shadowtex1, pos).x > pos.z && sh.x < 1.0){ vec4 translucentShadow = texture2D(shadowcolor0, pos.xy); - if(translucentShadow.a < 0.9) sh = normalize(translucentShadow.rgb+0.0001); + if(translucentShadow.a < 0.9) sh *= normalize(translucentShadow.rgb+0.0001); } #else sh *= vec3(shadow2D(shadow, pos).x); @@ -278,11 +278,12 @@ void main() { bool iswater = alpha > 0.99; + bool isLightning = alpha < 0.51 || alpha > 0.49; ////////////////////////////////////////////////////////// ///////////////// BEHIND OF TRANSLUCENTS ///////////////// ////////////////////////////////////////////////////////// - if(blendedAlpha > 0.0 || iswater){ + if(blendedAlpha > 0.0 || iswater || isLightning){ float noise_1 = R2_dither(); float noise_2 = blueNoise(); diff --git a/shaders/lang/en_us.lang b/shaders/lang/en_us.lang index e941382..9411e96 100644 --- a/shaders/lang/en_us.lang +++ b/shaders/lang/en_us.lang @@ -118,21 +118,21 @@ screen.Direct_Light = Direct Light value.shadowDistance.224.0 = 14 Chunks value.shadowDistance.240.0 = 15 Chunks value.shadowDistance.256.0 = 16 Chunks - value.shadowDistance.272.0 = 17 Chunks - value.shadowDistance.288.0 = 18 Chunks - value.shadowDistance.304.0 = 19 Chunks - value.shadowDistance.320.0 = 20 Chunks - value.shadowDistance.336.0 = 21 Chunks - value.shadowDistance.352.0 = 22 Chunks - value.shadowDistance.368.0 = 23 Chunks - value.shadowDistance.384.0 = 24 Chunks - value.shadowDistance.512.0 = 32 Chunks - value.shadowDistance.768.0 = 48 Chunks - value.shadowDistance.1024.0 = 64 Chunks - value.shadowDistance.1536.0 = 96 Chunks - value.shadowDistance.2048.0 = 128 Chunks - value.shadowDistance.4096.0 = 256 Chunks - value.shadowDistance.8192.0 = 512 Chunks + value.shadowDistance.272.0 = 17 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.288.0 = 18 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.304.0 = 19 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.320.0 = 20 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.336.0 = 21 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.352.0 = 22 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.368.0 = 23 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.384.0 = 24 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.512.0 = 32 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.768.0 = 48 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.1024.0 = 64 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.1536.0 = 96 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.2048.0 = 128 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.4096.0 = 256 Chunks §cNOT RECOMMENDED§r + value.shadowDistance.8192.0 = 512 Chunks §cNOT RECOMMENDED§r option.entityShadowDistanceMul = Entity Shadow Distance value.entityShadowDistanceMul.0.01 = 1% of Shadow Distance @@ -197,20 +197,6 @@ screen.Direct_Light = Direct Light suffix.LPV_VL_FOG_ILLUMINATION_BRIGHTNESS=% option.VANILLA_LIGHTMAP_MASK = Vanilla Lightmap Mask -screen.Subsurface_Scattering = Sub-Surface Scattering - option.LabSSS_Curve = LabSSS Curve - option.MISC_BLOCK_SSS = SSS for Random Blocks - option.MOB_SSS = SSS for Mobs - option.Ambient_SSS = SSS from the Sky - option.ambientsss_brightness = Sky SSS Brightness - option.SSS_TYPE = Mode - value.SSS_TYPE.0 = None - value.SSS_TYPE.1 = Hardcoded only - value.SSS_TYPE.2 = Hardcoded + LabSSS - value.SSS_TYPE.3 = LabSSS only - option.sss_density_multiplier = SSS Density Multiplier - option.sss_absorbance_multiplier = SSS Absorbance Multiplier - screen.Ambient_light = Ambient Light option.AO_Strength = AO Multiplier @@ -587,11 +573,6 @@ screen.Climate = Climate Settings screen.World = World screen.Sky_coefficients = Sky Coefficients screen.Water = Water Settings - option.WATER_REFLECTIONS = Specular Reflections for Water - option.SCREENSPACE_REFLECTIONS = Screen-Space Reflections - option.SSR_STEPS = SSR Quality - option.WATER_SUN_SPECULAR = Sun/Moon Reflections - option.WATER_BACKGROUND_SPECULAR = Sky/Fog Reflections option.FAKE_REFRACTION_EFFECT = Refraction In Water/Glass option.FAKE_DISPERSION_EFFECT = Dispersion In Water option.REFRACTION_SMUDGE = Refraction Smudge @@ -606,6 +587,39 @@ screen.World = World option.MINIMUM_WATER_ABSORBANCE = Minimum Water Absorbance value.MINIMUM_WATER_ABSORBANCE.-1 = AUTO + option.FAKE_REFRACTION_AMOUNT = Refraction amount + value.FAKE_REFRACTION_AMOUNT.0 = OFF + value.FAKE_REFRACTION_AMOUNT.1 = 0.25x + value.FAKE_REFRACTION_AMOUNT.2 = 0.50x + value.FAKE_REFRACTION_AMOUNT.3 = 0.75x + value.FAKE_REFRACTION_AMOUNT.4 = 1.00x + value.FAKE_REFRACTION_AMOUNT.5 = 1.25x + value.FAKE_REFRACTION_AMOUNT.6 = 1.50x + value.FAKE_REFRACTION_AMOUNT.7 = 1.75x + value.FAKE_REFRACTION_AMOUNT.8 = 2.00x + + option.FAKE_DISPERSION_AMOUNT = Dispersion amount + value.FAKE_DISPERSION_AMOUNT.0 = OFF + value.FAKE_DISPERSION_AMOUNT.1 = 0.25x + value.FAKE_DISPERSION_AMOUNT.2 = 0.50x + value.FAKE_DISPERSION_AMOUNT.3 = 0.75x + value.FAKE_DISPERSION_AMOUNT.4 = 1.00x + value.FAKE_DISPERSION_AMOUNT.5 = 1.25x + value.FAKE_DISPERSION_AMOUNT.6 = 1.50x + value.FAKE_DISPERSION_AMOUNT.7 = 1.75x + value.FAKE_DISPERSION_AMOUNT.8 = 2.00x + + option.REFRACTION_SMUDGE_AMOUNT = Smudge amount + value.REFRACTION_SMUDGE_AMOUNT.0 = OFF + value.REFRACTION_SMUDGE_AMOUNT.1 = 0.25x + value.REFRACTION_SMUDGE_AMOUNT.2 = 0.50x + value.REFRACTION_SMUDGE_AMOUNT.3 = 0.75x + value.REFRACTION_SMUDGE_AMOUNT.4 = 1.00x + value.REFRACTION_SMUDGE_AMOUNT.5 = 1.25x + value.REFRACTION_SMUDGE_AMOUNT.6 = 1.50x + value.REFRACTION_SMUDGE_AMOUNT.7 = 1.75x + value.REFRACTION_SMUDGE_AMOUNT.8 = 2.00x + screen.Water_fog_color = Water Fog Settings option.Dirt_Scatter_R = Scatter Red (dirt) option.Dirt_Scatter_G = Scatter Green (dirt) @@ -651,18 +665,30 @@ screen.Post_Processing = Post Processing option.HIGHLIGHTS_GRADE_MUL = Highlights Brightness -screen.Resource_Pack_Support = Resource Pack Support - screen.Reflections = Specular Reflections - option.Specular_Reflections = Specular Reflections - option.Screen_Space_Reflections = Screen-Space Reflections - option.Rough_reflections = Detailed Roughness - option.Sky_reflection = Sky/Fog in Reflections - option.Dynamic_SSR_quality = Dynamic SSR Quality - option.Roughness_Threshold = Reflection Threshold - option.Sun_specular_Strength = Sun Reflection Multiplier - option.reflection_quality = SSR Quality +screen.Resource_Pack_Support = Materials / Resource Pack Support + screen.SPECULAR = Specular Reflections + option.DEFERRED_SPECULAR = Reflections on terrain + option.DEFERRED_SSR_QUALITY =^ Environment reflections + value.DEFERRED_SSR_QUALITY.0 =§c OFF + value.DEFERRED_SSR_QUALITY.1 = mirrored view mode + suffix.DEFERRED_SSR_QUALITY = §§ samples + option.DEFERRED_BACKGROUND_REFLECTION =^ Background reflections + option.DEFERRED_ROUGH_REFLECTION =^ Rough reflections + option.FORWARD_SPECULAR = Reflections on water, glass + option.FORWARD_SSR_QUALITY =^ Environment reflections + value.FORWARD_SSR_QUALITY.0 =§c OFF + value.FORWARD_SSR_QUALITY.1 = mirrored view mode + suffix.FORWARD_SSR_QUALITY = §§ samples + option.FORWARD_BACKGROUND_REFLECTION =^ Background reflections + option.FORWARD_ROUGH_REFLECTION =^ Rough reflections + option.SUN_SPECULAR_MULT = Sun/Moon reflection + value.SUN_SPECULAR_MULT.0 =§c OFF + value.SUN_SPECULAR_MULT.1 = ON + suffix.SUN_SPECULAR_MULT =x brighter + option.ROUGHNESS_THRESHOLD = Reflection Visibilty Threshold + value.ROUGHNESS_THRESHOLD.0.0 = no threshold - screen.Emissives = Emissives + screen.Emissives = Emissives / Glowing Textures option.Emissive_Brightness = Emission Multiplier option.Emissive_Curve = Emission Curve option.EMISSIVE_TYPE = Mode @@ -680,6 +706,19 @@ screen.POM = Parallax Occlusion Mapping / POM option.Adaptive_Step_length = Dynamic Quality option.Horrible_slope_normals = Horrible Slope Normals +screen.Subsurface_Scattering = Sub-Surface Scattering + option.LabSSS_Curve = LabSSS Curve + option.MISC_BLOCK_SSS = SSS for Random Blocks + option.MOB_SSS = SSS for Mobs + option.Ambient_SSS = SSS from the Sky + option.ambientsss_brightness = Sky SSS Brightness + option.SSS_TYPE = Mode + value.SSS_TYPE.0 = None + value.SSS_TYPE.1 = Hardcoded only + value.SSS_TYPE.2 = Hardcoded + LabSSS + value.SSS_TYPE.3 = LabSSS only + option.sss_density_multiplier = SSS Density Multiplier + option.sss_absorbance_multiplier = SSS Absorbance Multiplier screen.Porosity = Porosity / Puddles option.Porosity = Porosity @@ -695,6 +734,9 @@ screen.Rainbow_Settings = Rainbow Settings option.RAINBOW_ONLY_BELOW_CLOUDS = Rainbow above Clouds option.MATERIAL_AO = Material Ambient Occlusion +option.NORMAL_MAP_MULT = Normal map multiplier +value.NORMAL_MAP_MULT.1.0 = Default 1.0 §aresourcepacks expect this value +suffix.NORMAL_MAP_MULT = §c resourcepacks DO NOT expect this value option.DOF_QUALITY=Depth Of Field value.DOF_QUALITY.-1=Off @@ -807,15 +849,22 @@ screen.Ambient_light.comment = Configure settings related to the lighting in sha option.LPV_VL_FOG_ILLUMINATION_BRIGHTNESS.comment = Configure the brightness of lit up fog. screen.Resource_Pack_Support.comment = A handfull of effects that use information provided by a resourcepack. - screen.Reflections.comment = Configure the reflections that use information provided by a LabPBR resourcepack. - option.Specular_Reflections.comment = Toggle all reflections for Labpbr packs. This enables the sun reflection, and allows other settings to be enabled below. §aPERFORMANCE COST:§r low - option.Screen_Space_Reflections.comment = Toggle screen-space reflections. §aPERFORMANCE COST:§r medium - option.Rough_reflections.comment = Toggle more detailed roughness for higher quality reflection. This will cause a good amount of visible noise. §aPERFORMANCE COST:§r medium to high - option.Sky_reflection.comment = Toggle reflections of the sky and fog. §aPERFORMANCE COST:§r low to medium. - option.Dynamic_SSR_quality.comment = This lowers the quality of screen-space reflections based on how visible they are. it can improve performance but lower the quality. - option.Roughness_Threshold.comment = If the roughness reaches this threshold, all reflections except the sun do not render. it can improve performance. - option.Sun_specular_Strength.comment = Configure how bright the sun's reflection is. - option.reflection_quality.comment = Configure the quality of the screen-space reflections. + screen.SPECULAR.comment = Configure the reflections. they can use information provided by a LabPBR resourcepack. + option.DEFERRED_SPECULAR.comment = Toggle detailed reflections on all solid objects. §bWhat is this?§r "solid" meaning anything you cannot see through, like stone, wood, grass, leaves + option.FORWARD_SPECULAR.comment = Toggle detailed reflections on all translucent objects. §bWhat is this?§r "translucent" meaning things you can see through, like glass, water, ice, slime + + option.DEFERRED_SSR_QUALITY.comment = Configure the quality of reflections of the world around you that are visible on terrain. §bWhat is this?§r Configure how many samples the SSR/screen-space-reflections take to create a reflection of the world. §b"mirrored view mode"§r is quite literally the image you see, but mirrored on every surface - EXTREMLY low quality. §aPERFORMANCE COST:§r low to very high + option.FORWARD_SSR_QUALITY.comment = Configure the quality of reflections of the world around you that are visible on water, glass, and other translucent things. §bWhat is this?§r Configure how many samples the SSR/screen-space-reflections take to create a reflection of the world. §b"mirrored view mode"§r is quite literally the image you see, but mirrored on every surface - EXTREMLY low quality. §aPERFORMANCE COST:§r low to very high + + option.DEFERRED_BACKGROUND_REFLECTION.comment = Toggle the reflections of the sky, clouds, or fog that are visible on terrain. §bWhat is this?§r Reflections of things like the sky, clouds, and fog. §aPERFORMANCE COST:§r low + option.FORWARD_BACKGROUND_REFLECTION.comment = Toggle the reflections of the sky, clouds, or fog that are visible on water, glass, and other translucent things. §bWhat is this?§r Reflections of things like the sky, clouds, and fog. §aPERFORMANCE COST:§r low + + option.DEFERRED_ROUGH_REFLECTION.comment = Toggle rough reflections that are visible on terrain. §bWhat is this?§r This is how "spread around" a reflection is based on how "smooth" a surface is, really un-smooth surfaces scatter reflections around alot, while smooth surfaces look like mirrors. §aPERFORMANCE COST:§r medium + option.FORWARD_ROUGH_REFLECTION.comment = Toggle rough reflections that are visible on water, glass, and other translucent things. §bWhat is this?§r This is how "spread around" a reflection is based on how "smooth" a surface is, really un-smooth surfaces scatter reflections around alot, while smooth surfaces look like mirrors. §aPERFORMANCE COST:§r medium + + option.ROUGHNESS_THRESHOLD.comment = Configure a threshold for environment and background reflections to stop being visible at. §bThis does not impact sun/moon reflections§r. §aPERFORMANCE COST:§r high thresholds can improve performance - low thresholds can worsen performance + option.SUN_SPECULAR_MULT.comment = Toggle the reflection of the sun or moon, or make them brighter. §bThis remains visible even if both environment and background reflections are disabled§r. §aPERFORMANCE COST:§r very low + screen.Subsurface_Scattering.comment = §bWhat is this?§r Sub-surface scattering is what happens when you put a bright light on your hand, and it starts to glow. The sun actually does the same thing to plants, cloth, skin, and other things. option.SSS_TYPE.comment = Configure how the sub-surface scattering is applied to the world. §bHardcoded:§r The shader decides what gets it. §bLabSSS:§r The resourcepack decides what gets it. §aPERFORMANCE COST:§r very low @@ -842,6 +891,10 @@ screen.Porosity.comment = Configure settings related to wetness and puddles option.Puddles.comment = Toggle puddles for when it rains. §aPERFORMANCE COST:§r low option.Puddle_Size.comment = Configure the size of the puddles. +option.FAKE_REFRACTION_AMOUNT.comment = Configure the amount of distortion refraction will do. §bWhat is this?§r you could think of refraction as light bending when going through water or glass, making the things viewed through them look stretched, squished, distorted. §aPERFORMANCE COST:§r very low +option.FAKE_DISPERSION_AMOUNT.comment = Configure the amount of dispersion within the refraction. §bWhat is this?§r when refraction happens, the parts that get really distorted will get a "chromatic abberation", faking the look of a rainbow or light prism. §aPERFORMANCE COST:§r very low +option.REFRACTION_SMUDGE_AMOUNT.comment = Configure the amount of smudge within the refraction. §bWhat is this?§r when refraction happens, the parts that get really distorted will get smudged. §cWill cause visaul noise within refraction. §aPERFORMANCE COST:§r very low + screen.Fog.comment = Configure settings related to the raymarched volumetric fog, or distance based fog. option.VL_RENDER_RESOLUTION.comment = Configure the resolution of the volumetric fog. §aPERFORMANCE COST:§r high option.VL_SAMPLES.comment = Configure the quality of the volumetric fog. §aPERFORMANCE COST:§r high @@ -871,16 +924,9 @@ screen.Clouds.comment = Configure settings related to the raymarched volumetric screen.World.comment = Configure settings for various things that happen in the world, from waving plants to water related settings. screen.Water.comment = Configure settings related to the water. - option.WATER_REFLECTIONS.comment = Toggle all reflections for translucent things. This allows other settings to be enabled below. §aPERFORMANCE COST:§r low-high - option.SCREENSPACE_REFLECTIONS.comment = Toggle screen-space reflections on translucent things. §aPERFORMANCE COST:§r medium - option.SSR_STEPS.comment = Configure the quality of the screen-space reflections on translucent things. §aPERFORMANCE COST:§r medium to high - option.WATER_SUN_SPECULAR.comment = Toggle the sun and moon reflections on translucent things. §aPERFORMANCE COST:§r low - option.WATER_BACKGROUND_SPECULAR.comment = Toggle the sky and fog reflections on translucent things. §aPERFORMANCE COST:§r low to medium - option.FAKE_REFRACTION_EFFECT.comment = Toggle refraction on translucent things. §bWhat is this?§r If you look at water, you can see the light refracting distorts what is in it. §aPERFORMANCE COST:§r low option.Dirt_Amount.comment = Configure how much dirt is in water. This controls how much fog is within water. option.Water_Top_Layer.comment = Configure the Y coordinate at which the ocean should be in the world. - - screen.Water_fog_color.comment = Configure colors of the water fog. + screen.Water_fog_color.comment = Configure colors of the water fog. screen.World_Effects = World Weather Effects option.Puddles = Puddles @@ -937,7 +983,9 @@ screen.Post_Processing.comment = Configure settings for all post processing effe option.TAA.comment = Toggle temporal anti-aliasing. This removes all jagged edges on things, softens the image, and helps remove noise for many effects. This will cause ghosting or trailing because it uses past frames for extra information on the world. §aPERFORMANCE COST:§r low option.BLEND_FACTOR.comment = Configure how much of frame history is used. high numbers means it relies less on frame history, so it may look flickery and noisy. low numbers rely more on frame history, so it may look less moisy, but more smudged with more trailing. option.TAA_UPSCALING.comment = Toggle temporal upscaling. This retains a good amount of quality from a lower resolution image when it upscales. so you can still have a high looking resolution compared to typical upsampling and still have better performance. - option.SCALE_FACTOR.comment = Configure from what fraction of your resolution to upscale from. Below 0.5 is not recommended at all i only have it as an option because it's funny :P + option.SCALE_FACTOR.comment = Configure from what fraction of your resolution to upscale from - §abelow 0.50x is not recommend, it is only allowed for fun!§r + + screen.COLOR_GRADING.comment = Advanced color grading options option.LUMINANCE_CURVE.comment = Enable the tone curve. This is independent from color grading and is applied first. option.COLOR_GRADING_ENABLED.comment = Enable color grading. The RGB sliders will not affect the brightness. This is applied after the tone curve diff --git a/shaders/lib/Shadows.glsl b/shaders/lib/Shadows.glsl index 6202e45..832043f 100644 --- a/shaders/lib/Shadows.glsl +++ b/shaders/lib/Shadows.glsl @@ -4,12 +4,13 @@ void GriAndEminShadowFix( inout vec3 WorldPos, vec3 FlatNormal, - float VanillaAO, - float SkyLightmap, float transition ){ - float zoomLevel = 1.0-(transition*transition*transition*transition*0.5+0.5); - if(SkyLightmap < 0.1 && isEyeInWater != 1) WorldPos = WorldPos - ( fract(WorldPos+cameraPosition - WorldPos*0.0001)*zoomLevel - zoomLevel*0.5); + transition = 1.0-transition; + transition *= transition*transition*transition*transition*transition*transition; + float zoomLevel = mix(0.0, 0.5, transition); + + if(zoomLevel > 0.001 && isEyeInWater != 1) WorldPos = WorldPos - ( fract(WorldPos+cameraPosition - WorldPos*0.0001)*zoomLevel - zoomLevel*0.5); } void applyShadowBias(inout vec3 projectedShadowPosition, in vec3 playerPos, in vec3 geoNormals){ diff --git a/shaders/lib/settings.glsl b/shaders/lib/settings.glsl index 2d96b21..32bd28f 100644 --- a/shaders/lib/settings.glsl +++ b/shaders/lib/settings.glsl @@ -9,7 +9,7 @@ // #define Vanilla_like_water #define WATER_WAVE_STRENGTH 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0] #define WATER_WAVE_SPEED 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0] -#define Dirt_Amount 0.12 // [0.0 0.04 0.08 0.12 0.16 0.2 0.24 0.28 0.32 0.36 0.4 0.44 0.48 0.52 0.56 0.6 0.64 0.68 0.72 0.76 0.8 0.84 0.88 0.92 0.96 1.0 1.04 1.08 1.12 1.16 1.2 1.24 1.28 1.32 1.36 1.4 1.44 1.48 1.52 1.56 1.6 1.64 1.68 1.72 1.76 1.8 1.84 1.88 1.92 1.96 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0] +#define Dirt_Amount 0.14 // [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 1.02 1.04 1.06 1.08 1.1 1.12 1.14 1.16 1.18 1.2 1.22 1.24 1.26 1.28 1.3 1.32 1.34 1.36 1.38 1.4 1.42 1.44 1.46 1.48 1.5 1.52 1.54 1.56 1.58 1.6 1.62 1.64 1.66 1.68 1.7 1.72 1.74 1.76 1.78 1.8 1.82 1.84 1.86 1.88 1.9 1.92 1.94 1.96 1.98 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0] #define WATER_INTERACTION #define Dirt_Scatter_R 0.5 // [0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 ] @@ -26,15 +26,14 @@ #define rayMarchSampleCount 2 // [1 2 3 4 6 8 12 16 32 64] #define Water_Top_Layer 62.90 // [0.90 1.90 2.90 3.90 4.90 5.90 6.90 7.90 8.90 9.90 10.90 11.90 12.90 13.90 14.90 15.90 16.90 17.90 18.90 19.90 20.90 21.90 22.90 23.90 24.90 25.90 26.90 27.90 28.90 29.90 30.90 31.90 32.90 33.90 34.90 35.90 36.90 37.90 38.90 39.90 40.90 41.90 42.90 43.90 44.90 45.90 46.90 47.90 48.90 49.90 50.90 51.90 52.90 53.90 54.90 55.90 56.90 57.90 58.90 59.90 60.90 61.90 62.90 63.90 64.90 65.90 66.90 67.90 68.90 69.90 70.90 71.90 72.90 73.90 74.90 75.90 76.90 77.90 78.90 79.90 80.90 81.90 82.90 83.90 84.90 85.90 86.90 87.90 88.90 89.90 90.90 91.90 92.90 93.90 94.90 95.90 96.90 97.90 98.90 99.90 100.90 101.90 102.90 103.90 104.90 105.90 106.90 107.90 108.90 109.90 110.90 111.90 112.90 113.90 114.90 115.90 116.90 117.90 118.90 119.90 120.90 121.90 122.90 123.90 124.90 125.90 126.90 127.90 128.90 129.90 130.90 131.90 132.90 133.90 134.90 135.90 136.90 137.90 138.90 139.90 140.90 141.90 142.90 143.90 144.90 145.90 146.90 147.90 148.90 149.90 150.90 151.90 152.90 153.90 154.90 155.90 156.90 157.90 158.90 159.90 160.90 161.90 162.90 163.90 164.90 165.90 166.90 167.90 168.90 169.90 170.90 171.90 172.90 173.90 174.90 175.90 176.90 177.90 178.90 179.90 180.90 181.90 182.90 183.90 184.90 185.90 186.90 187.90 188.90 189.90 190.90 191.90 192.90 193.90 194.90 195.90 196.90 197.90 198.90 199.90] -#define FAKE_REFRACTION_EFFECT -#define FAKE_DISPERSION_EFFECT -// #define REFRACTION_SMUDGE - -#define SSR_STEPS 30 // [10 15 20 25 30 35 40 50 100 200 400] -#define SSR_STEPS_DH floor(float(SSR_STEPS) * 2.0/3.0) -#define USE_QUARTER_RES_DEPTH #define SNELLS_WINDOW +#define FAKE_REFRACTION_AMOUNT 4 // [0 1 2 3 4 5 6 7 8] +#define FAKE_DISPERSION_AMOUNT 4 // [0 1 2 3 4 5 6 7 8] +#define REFRACTION_SMUDGE_AMOUNT 0 // [0 1 2 3 4 5 6 7 8] + +#define USE_QUARTER_RES_DEPTH + //////////////////////////////////////// // ----- PLANT RELATED SETTINGS ----- // //////////////////////////////////////// @@ -79,7 +78,7 @@ // ----- INDIRECT LIGHT RELATED SETTINGS ----- // ///////////////////////////////////////////////// -#define MIN_LIGHT_AMOUNT 0.5 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 100.0 ] +#define MIN_LIGHT_AMOUNT 0.8 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 100.0 ] #define MIN_LIGHT_AMOUNT_INSIDE 0.5 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0 15.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 100.0 ] #define ambient_brightness 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 ] @@ -90,7 +89,7 @@ #define SeparateAmbientColorRain #define AmbientLightRain_R 0.15 // [0.0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0] #define AmbientLightRain_G 0.15 // [0.0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0] -#define AmbientLightRain_B 0.15 // [0.0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0] +#define AmbientLightRain_B 0.1475 // [0.0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0] #define AmbientLightEnd_R 0.3 // [0.0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0] #define AmbientLightEnd_G 0.35 // [0.0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.6 0.65 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0] @@ -106,7 +105,7 @@ #define indirect_effect 1 // [0 1 2 3 4] -// #define AO_in_sunlight +#define AO_in_sunlight #define AO_Strength 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0] // #define SKY_CONTRIBUTION_IN_SSRT @@ -130,7 +129,7 @@ const float ambientOcclusionLevel = 1.0; // this controls vanilla minecrafts amb const float sunPathRotation = -35; //[-90 -89 -88 -87 -86 -85 -84 -83 -82 -81 -80 -79 -78 -77 -76 -75 -74 -73 -72 -71 -70 -69 -68 -67 -66 -65 -64 -63 -62 -61 -60 -59 -58 -57 -56 -55 -54 -53 -52 -51 -50 -49 -48 -47 -46 -45 -44 -43 -42 -41 -40 -39 -38 -37 -36 -35 -34 -33 -32 -31 -30 -29 -28 -27 -26 -25 -24 -23 -22 -21 -20 -19 -18 -17 -16 -15 -14 -13 -12 -11 -10 -9 -8 -7 -6 -5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 ] -const int shadowMapResolution = 2048; // [512 768 1024 1536 2048 3172 4096 8192] +const int shadowMapResolution = 2048; // [512 768 1024 1536 2048 2560 3172 3684 4096 5120 6144 7168 8192] const float shadowDistance = 128.0; // [32.0 48.0 64.0 80.0 96.0 112.0 128.0 144.0 160.0 176.0 192.0 208.0 224.0 240.0 256.0 272.0 288.0 304.0 320.0 336.0 352.0 368.0 384.0 512.0 768.0 1024.0 1536.0 2048.0 4096.0 8192.0] const float shadowDistanceRenderMul = 1.0; @@ -269,9 +268,8 @@ const float entityShadowDistanceMul = 0.25; // [0.01 0.02 0.03 0.04 0.05 0.10 0. // ----- LABPBR MATERIALS RELATED SETTINGS ----- // /////////////////////////////////////////////////// -#define Sun_specular_Strength 1 // [0 1 2 3 4 5 6 7 8 9 10] -#define reflection_quality 30 // [6.0 7.0 8.0 9.0 10.0 11.0 12.0 13.0 14.0 15.0 16.0 17.0 18.0 19.0 20.0 25.0 30.0 35.0 40.0 45.0 50.0 55.0 60.0 65.0 70.0 75.0 80.0 85.0 90.0 95.0 100.0 ] -#define Roughness_Threshold 0.3 // [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.00] +#define SUN_SPECULAR_MULT 1 // [0 1 2 3 4 5 6 7 8 9 10] +#define ROUGHNESS_THRESHOLD 0.3 // [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.00] #ifdef Specular_Reflections #define LIGHTSOURCE_REFLECTION @@ -290,7 +288,7 @@ const float entityShadowDistanceMul = 0.25; // [0.01 0.02 0.03 0.04 0.05 0.10 0. #define MAX_DIST 25.0 // [5.0 10.0 15.0 20.0 25.0 35.0 30.0 40.0 50.0 60.0 70.0 80.0 90.0 100.0 125.0 150.0 200.0 300.0 400.0 500.0] #define SSS_TYPE 1 // [0 1 2 3] -#define LabSSS_Curve 1.0 // [0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 ] +#define LabSSS_Curve 1.0 // [0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0] // #define MOB_SSS // #define MISC_BLOCK_SSS #define Ambient_SSS @@ -314,6 +312,7 @@ const float entityShadowDistanceMul = 0.25; // [0.01 0.02 0.03 0.04 0.05 0.10 0. // #define MATERIAL_AO +#define NORMAL_MAP_MULT 1.0 // [0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 1.2 1.3 1.4 1.5 1.6 1.7 1.8 1.9 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 4.0 5.0 6.0 7.0 8.0 9.0 10.0] ////////////////////////////////////// // ----- SKY RELATED SETTINGS ----- // @@ -648,7 +647,7 @@ const float aperture = focal/fstop; #define CONTRAST_ADAPTATIVE_SHARPENING #define SHARPENING 0.45 // [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0] -#define SATURATION 0.0 // [-1.0 -0.98 -0.96 -0.94 -0.92 -0.9 -0.88 -0.86 -0.84 -0.82 -0.8 -0.78 -0.76 -0.74 -0.72 -0.7 -0.68 -0.66 -0.64 -0.62 -0.6 -0.58 -0.56 -0.54 -0.52 -0.5 -0.48 -0.46 -0.44 -0.42 -0.4 -0.38 -0.36 -0.34 -0.32 -0.3 -0.28 -0.26 -0.24 -0.22 -0.2 -0.18 -0.16 -0.14 -0.12 -0.1 -0.08 -0.06 -0.04 -0.02 0.0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.2 0.22 0.24 0.26 0.28 0.3 0.32 0.34 0.36 0.38 0.4 0.42 0.44 0.46 0.48 0.5 0.52 0.54 0.56 0.58 0.6 0.62 0.64 0.66 0.68 0.7 0.72 0.74 0.76 0.78 0.8 0.82 0.84 0.86 0.88 0.9 0.92 0.94 0.96 0.98 1.0 ]= +#define SATURATION 0.0 // [-1.0 -0.99 -0.98 -0.96 -0.94 -0.92 -0.9 -0.88 -0.86 -0.84 -0.82 -0.8 -0.78 -0.76 -0.74 -0.72 -0.7 -0.68 -0.66 -0.64 -0.62 -0.6 -0.58 -0.56 -0.54 -0.52 -0.5 -0.48 -0.46 -0.44 -0.42 -0.4 -0.38 -0.36 -0.34 -0.32 -0.3 -0.28 -0.26 -0.24 -0.22 -0.2 -0.18 -0.16 -0.14 -0.12 -0.1 -0.08 -0.06 -0.04 -0.02 0.0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.2 0.22 0.24 0.26 0.28 0.3 0.32 0.34 0.36 0.38 0.4 0.42 0.44 0.46 0.48 0.5 0.52 0.54 0.56 0.58 0.6 0.62 0.64 0.66 0.68 0.7 0.72 0.74 0.76 0.78 0.8 0.82 0.84 0.86 0.88 0.9 0.92 0.94 0.96 0.98 0.99 1.0] #define CROSSTALK 0.0 // [-1.0 -0.98 -0.96 -0.94 -0.92 -0.9 -0.88 -0.86 -0.84 -0.82 -0.8 -0.78 -0.76 -0.74 -0.72 -0.7 -0.68 -0.66 -0.64 -0.62 -0.6 -0.58 -0.56 -0.54 -0.52 -0.5 -0.48 -0.46 -0.44 -0.42 -0.4 -0.38 -0.36 -0.34 -0.32 -0.3 -0.28 -0.26 -0.24 -0.22 -0.2 -0.18 -0.16 -0.14 -0.12 -0.1 -0.08 -0.06 -0.04 -0.02 0.0 0.02 0.04 0.06 0.08 0.1 0.12 0.14 0.16 0.18 0.2 0.22 0.24 0.26 0.28 0.3 0.32 0.34 0.36 0.38 0.4 0.42 0.44 0.46 0.48 0.5 0.52 0.54 0.56 0.58 0.6 0.62 0.64 0.66 0.68 0.7 0.72 0.74 0.76 0.78 0.8 0.82 0.84 0.86 0.88 0.9 0.92 0.94 0.96 0.98 1.0 ] #define WHITE_BALANCE 6500 // [1000 1100 1200 1300 1400 1500 1600 1700 1800 1900 2000 2100 2200 2300 2400 2500 2600 2700 2800 2900 3000 3100 3200 3300 3400 3500 3600 3700 3800 3900 4000 4100 4200 4300 4400 4500 4600 4700 4800 4900 5000 5100 5200 5300 5400 5500 5600 5700 5800 5900 6000 6100 6200 6300 6400 6500 6600 6700 6800 6900 7000 7100 7200 7300 7400 7500 7600 7700 7800 7900 8000 8100 8200 8300 8400 8500 8600 8700 8800 8900 9000 9100 9200 9300 9400 9500 9600 9700 9800 9900 10000 15000 20000 25000 50000] @@ -676,8 +675,6 @@ const vec3 MIDS_TARGET = length(vec3(MIDS_GRADE_R, MIDS_GRADE_G, MIDS_GRADE_B)) const vec3 HIGHLIGHTS_TARGET = length(vec3(HIGHLIGHTS_GRADE_R, HIGHLIGHTS_GRADE_G, HIGHLIGHTS_GRADE_B)) < 0.001 ? vec3(0.0) : normalize(vec3(HIGHLIGHTS_GRADE_R, HIGHLIGHTS_GRADE_G, HIGHLIGHTS_GRADE_B)); -#define CONTRAST 1.0 // [0.0 0.01 0.02 0.03 0.04 0.05 0.06 0.07 0.08 0.09 0.1 0.11 0.12 0.13 0.14 0.15 0.16 0.17 0.18 0.19 0.2 0.21 0.22 0.23 0.24 0.25 0.26 0.27 0.28 0.29 0.3 0.31 0.32 0.33 0.34 0.35 0.36 0.37 0.38 0.39 0.4 0.41 0.42 0.43 0.44 0.45 0.46 0.47 0.48 0.49 0.5 0.51 0.52 0.53 0.54 0.55 0.56 0.57 0.58 0.59 0.6 0.61 0.62 0.63 0.64 0.65 0.66 0.67 0.68 0.69 0.7 0.71 0.72 0.73 0.74 0.75 0.76 0.77 0.78 0.79 0.8 0.81 0.82 0.83 0.84 0.85 0.86 0.87 0.88 0.89 0.9 0.91 0.92 0.93 0.94 0.95 0.96 0.97 0.98 0.99 1.0 1.0 1.01 1.02 1.03 1.04 1.05 1.06 1.07 1.08 1.09 1.1 1.11 1.12 1.13 1.14 1.15 1.16 1.17 1.18 1.19 1.2 1.21 1.22 1.23 1.24 1.25 1.26 1.27 1.28 1.29 1.3 1.31 1.32 1.33 1.34 1.35 1.36 1.37 1.38 1.39 1.4 1.41 1.42 1.43 1.44 1.45 1.46 1.47 1.48 1.49 1.5 1.51 1.52 1.53 1.54 1.55 1.56 1.57 1.58 1.59 1.6 1.61 1.62 1.63 1.64 1.65 1.66 1.67 1.68 1.69 1.7 1.71 1.72 1.73 1.74 1.75 1.76 1.77 1.78 1.79 1.8 1.81 1.82 1.83 1.84 1.85 1.86 1.87 1.88 1.89 1.9 1.91 1.92 1.93 1.94 1.95 1.96 1.97 1.98 1.99 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 2.9 3.0 3.1 3.2 3.3 3.4 3.5 3.6 3.7 3.8 3.9 4.0 4.1 4.2 4.3 4.4 4.5 4.6 4.7 4.8 4.9 5.0 6.0 7.0 8.0 9.0 10.0 11.0 12.0 13.0 14.0 15.0 16.0 17.0 18.0 19.0 20.0 ] - #define EXPOSURE_MULTIPLIER 1.0 // [0.25 0.4 0.5 0.6 0.7 0.75 0.8 0.85 0.9 0.95 1.0 1.1 1.2 1.3 1.4 1.5 2.0 3.0 4.0] #define AUTO_EXPOSURE #define Manual_exposure_value 1.0 // [0.000553 0.000581 0.000611 0.000642 0.000675 0.000710 0.000746 0.000784 0.000825 0.000867 0.000911 0.000958 0.001007 0.001059 0.001113 0.001170 0.001230 0.001294 0.001360 0.001430 0.001503 0.001580 0.001661 0.001746 0.001836 0.001930 0.002029 0.002133 0.002242 0.002357 0.002478 0.002605 0.002739 0.002879 0.003027 0.003182 0.003345 0.003517 0.003697 0.003887 0.004086 0.004296 0.004516 0.004748 0.004991 0.005247 0.005516 0.005799 0.006096 0.006409 0.006737 0.007083 0.007446 0.007828 0.008229 0.008651 0.009095 0.009561 0.010051 0.010567 0.011108 0.011678 0.012277 0.012906 0.013568 0.014264 0.014995 0.015764 0.016572 0.017422 0.018315 0.019254 0.020241 0.021279 0.022370 0.023517 0.024723 0.025991 0.027323 0.028724 0.030197 0.031745 0.033373 0.035084 0.036883 0.038774 0.040762 0.042852 0.045049 0.047358 0.049787 0.052339 0.055023 0.057844 0.060810 0.063927 0.067205 0.070651 0.074273 0.078081 0.082084 0.086293 0.090717 0.095369 0.100258 0.105399 0.110803 0.116484 0.122456 0.128734 0.135335 0.142274 0.149568 0.157237 0.165298 0.173773 0.182683 0.192049 0.201896 0.212247 0.223130 0.234570 0.246596 0.259240 0.272531 0.286504 0.301194 0.316636 0.332871 0.349937 0.367879 0.386741 0.406569 0.427414 0.449328 0.472366 0.496585 0.522045 0.548811 0.576949 0.606530 0.637628 0.670320 0.704688 0.740818 0.778800 0.818730 0.860707 0.904837 0.951229 1.0 1.051271 1.105170 1.161834 1.221402 1.284025 1.349858 1.419067 1.491824 1.568312 1.648721 1.733253 1.822118 1.915540 2.013752 2.117000 2.225540 2.339646 2.459603 2.585709 2.718281 2.857651 3.004166 3.158192 3.320116 3.490342 3.669296 3.857425 4.055199 4.263114 4.481689 4.711470 4.953032 5.206979 5.473947 5.754602 6.049647 6.359819 6.685894 7.028687 7.389056 7.767901 8.166169 8.584858 9.025013 9.487735 9.974182 10.48556 11.02317 11.58834 12.18249 ] diff --git a/shaders/lib/specular.glsl b/shaders/lib/specular.glsl index ee9ddd5..fa1ab3f 100644 --- a/shaders/lib/specular.glsl +++ b/shaders/lib/specular.glsl @@ -94,8 +94,8 @@ float shlickFresnelRoughness(float XdotN, float roughness){ float shlickFresnel = clamp(1.0 + XdotN,0.0,1.0); - float curves = exp(-4.0*pow(1-(roughness),2.5)); - float brightness = exp(-3.0*pow(1-sqrt(roughness),3.50)); + float curves = exp(-4.0*pow(1.0-(roughness),2.5)); + float brightness = exp(-3.0*pow(1.0-sqrt(roughness),3.50)); shlickFresnel = pow(1.0-pow(1.0-shlickFresnel, mix(1.0, 1.9, curves)),mix(5.0, 2.6, curves)); shlickFresnel = mix(0.0, mix(1.0,0.065, brightness) , clamp(shlickFresnel,0.0,1.0)); @@ -151,7 +151,11 @@ vec3 rayTraceSpeculars(vec3 dir, vec3 position, float dither, float quality, boo float rayLength = ((position.z + dir.z * far*sqrt(3.)) > -near) ? (-near -position.z) / dir.z : far*sqrt(3.); vec3 direction = toClipSpace3_DH(position + dir*rayLength) - clipPosition; //convert to clip space - vec3 reflectedTC = vec3((direction.xy + clipPosition.xy) * RENDER_SCALE, 1.0); + vec3 reflectedTC = vec3((direction.xy + clipPosition.xy) * RENDER_SCALE, 0.999999); + + #if FORWARD_SSR_QUALITY == 1 + return reflectedTC; + #endif //get at which length the ray intersects with the edge of the screen vec3 maxLengths = (step(0.0, direction) - clipPosition) / direction; @@ -174,7 +178,9 @@ vec3 rayTraceSpeculars(vec3 dir, vec3 position, float dither, float quality, boo vec3 hitPos = vec3(1.1); for (int i = 0; i <= int(quality); i++) { - if(spos.x < 0 || spos.x > 1 || spos.y < 0 || spos.y > 1) return hitPos; + #if DEFERRED_SSR_QUALITY != 1 + if(!hand && (spos.x < 0 || spos.x > 1 || spos.y < 0 || spos.y > 1)) return vec3(1.1); + #endif #if defined DISTANT_HORIZONS && defined DH_SCREENSPACE_REFLECTIONS #ifdef FULLRESDEPTH @@ -203,6 +209,10 @@ vec3 rayTraceSpeculars(vec3 dir, vec3 position, float dither, float quality, boo reflectionLength += 1.0 / quality; } + #if DEFERRED_SSR_QUALITY == 1 + return reflectedTC; + #endif + if(hand) return reflectedTC; return hitPos; } @@ -218,12 +228,19 @@ vec4 screenSpaceReflections( ){ vec4 reflection = vec4(0.0); - float reflectionLength = 0.0; - float quality = SSR_STEPS; + + float quality = 1.0f; + + #ifdef FORWARD_SPECULAR + quality = float(FORWARD_SSR_QUALITY); + #endif + + #ifdef DEFERRED_SPECULAR + quality = float(DEFERRED_SSR_QUALITY); + #endif vec3 raytracePos = rayTraceSpeculars(reflectedVector, viewPos, noise, quality, isHand, reflectionLength); - if (raytracePos.z > 1.0) return reflection; // use higher LOD as the reflection goes on, to blur it. this helps denoise a little. @@ -281,7 +298,7 @@ float getReflectionVisibility(float f0, float roughness){ // the goal is to determine if the reflection is even visible. // if it reaches a point in smoothness or reflectance where it is not visible, allow it to interpolate to diffuse lighting. - float thresholdValue = Roughness_Threshold; + float thresholdValue = ROUGHNESS_THRESHOLD; if(thresholdValue < 0.01) return 0.0; @@ -378,11 +395,8 @@ vec3 specularReflections( vec3 reflectedVector_L = reflect(playerPos, normal); #endif - float shlickFresnel = shlickFresnelRoughness(dot(-normalize(viewDir), vec3(0.0,0.0,1.0)), roughness); - - #if defined FORWARD_SPECULAR && defined SNELLS_WINDOW - if(isEyeInWater == 1 && isWater) shlickFresnel = mix(shlickFresnel, 1.0, min(max(0.98 - (1.0-shlickFresnel),0.0)/(1-0.98),1.0)); - #endif + float VdotN = dot(-normalize(viewDir), vec3(0.0,0.0,1.0)); + float shlickFresnel = shlickFresnelRoughness(VdotN, roughness); // F0 < 230 dialectrics // F0 >= 230 hardcoded metal f0 @@ -396,6 +410,16 @@ vec3 specularReflections( #if defined FORWARD_SPECULAR reflectanceForAlpha = clamp(dot(F0, vec3(0.3333333)), 0.0,1.0); + + #if defined SNELLS_WINDOW + if(isEyeInWater == 1 && isWater){ + // emulate how mojang did snells window in vibrant visuals because it works nicely tbh + float snellsWindow = min(max(0.54 - clamp(1.0 + VdotN,0,1),0.)/0.1,1.); + snellsWindow = 1.0-snellsWindow*snellsWindow; + snellsWindow *= snellsWindow*snellsWindow; + reflectanceForAlpha = f0 + (1.0-f0) * snellsWindow; + } + #endif #endif vec3 specularReflections = diffuseLighting; @@ -404,7 +428,7 @@ vec3 specularReflections( vec4 enviornmentReflection = vec4(0.0); - #if defined DEFERRED_BACKGROUND_REFLECTION || defined FORWARD_BACKGROUND_REFLECTION || defined DEFERRED_ENVIORNMENT_REFLECTION || defined FORWARD_ENVIORNMENT_REFLECTION + #if defined DEFERRED_BACKGROUND_REFLECTION || defined FORWARD_BACKGROUND_REFLECTION || DEFERRED_SSR_QUALITY > 0 || FORWARD_SSR_QUALITY > 0 if(reflectionVisibilty < 1.0){ float backgroundReflectMask = lightmap; @@ -416,12 +440,14 @@ vec3 specularReflections( //vec2 p = sphereToCarte(reflectedVector_L); vec3 backgroundReflection = skyCloudsFromTex(reflectedVector_L, colortex4).rgb / 1200.0; //vec3 backgroundReflection = imageLoad(reflectionSphere, ivec2(p)).rgb; - - if(isEyeInWater == 1) backgroundReflection *= exp(-vec3(Water_Absorb_R, Water_Absorb_G, Water_Absorb_B) * 15.0)*2; + + #if defined SNELLS_WINDOW + if(isEyeInWater == 1) backgroundReflection *= exp(-vec3(Water_Absorb_R, Water_Absorb_G, Water_Absorb_B) * 15.0)*2; + #endif #endif #endif - #if defined DEFERRED_ENVIORNMENT_REFLECTION || defined FORWARD_ENVIORNMENT_REFLECTION + #if DEFERRED_SSR_QUALITY > 0 || FORWARD_SSR_QUALITY > 0 enviornmentReflection = screenSpaceReflections(mat3(gbufferModelView) * reflectedVector_L, viewPos, noise.z, isHand, roughness, backgroundReflectMask); // darkening for metals. vec3 DarkenedDiffuseLighting = isMetal ? diffuseLighting * (1.0-enviornmentReflection.a) * (1.0-lightmap) : diffuseLighting; @@ -435,7 +461,7 @@ vec3 specularReflections( specularReflections = mix(DarkenedDiffuseLighting, backgroundReflection, backgroundReflectMask); #endif - #if defined DEFERRED_ENVIORNMENT_REFLECTION || defined FORWARD_ENVIORNMENT_REFLECTION + #if DEFERRED_SSR_QUALITY > 0 || FORWARD_SSR_QUALITY > 0 specularReflections = mix(specularReflections, enviornmentReflection.rgb, enviornmentReflection.a); #endif @@ -446,9 +472,9 @@ vec3 specularReflections( } #endif - #if defined OVERWORLD_SHADER - vec3 lightSourceReflection = Sun_specular_Strength * lightColor * GGX(normal, -playerPos, lightPos, roughness, reflectance, metalAlbedoTint); - #if defined DEFERRED_ENVIORNMENT_REFLECTION || defined FORWARD_ENVIORNMENT_REFLECTION + #if defined OVERWORLD_SHADER || SUN_SPECULAR_MULT > 0 + vec3 lightSourceReflection = SUN_SPECULAR_MULT * lightColor * GGX(normal, -playerPos, lightPos, roughness, reflectance, metalAlbedoTint); + #if DEFERRED_SSR_QUALITY > 0 || FORWARD_SSR_QUALITY > 0 specularReflections += mix(lightSourceReflection, vec3(0.0), enviornmentReflection.a); #else specularReflections += lightSourceReflection; diff --git a/shaders/shaders.properties b/shaders/shaders.properties index 1d57337..633cd0c 100644 --- a/shaders/shaders.properties +++ b/shaders/shaders.properties @@ -8,7 +8,7 @@ profile.POTATO = !MOON_NORMALS RAINBOW:0 !CUSTOM_MOON_ROTATION CUSTOM_SHADOWS_QU profile.VERY_LOW = !MOON_NORMALS RAINBOW:0 !CUSTOM_MOON_ROTATION CUSTOM_SHADOWS_QUALITY:0 !END_ISLAND_LIGHT CloudLayer0_distance:100000.0 CloudLayer1_distance:100000.0 !RIPPLE_PUDDLES !RIPPLE_WATER !Puddles ShaderSnow:0 CUMULONIMBUS:0 CloudLayer0 !CloudLayer1 !CloudLayer2 !CloudLayer3 VL_RENDER_RESOLUTION:0.25 indirect_effect:0 RAY_COUNT:4 VL_SAMPLES:4 REALMOON shadowMapResolution:1024 shadowDistance:96.0 !DH_SCREENSPACE_REFLECTIONS !LPV_ENABLED !SAND_STORMS !SNOW_STORMS TAA_UPSCALING SCALE_FACTOR:0.8 SHARPENING:0.5 !FORWARD_ENVIORNMENT_REFLECTION profile.LOW = !MOON_NORMALS RAINBOW:1 CUSTOM_MOON_ROTATION CUSTOM_SHADOWS_QUALITY:0 !END_ISLAND_LIGHT CloudLayer0_distance:100000.0 CloudLayer1_distance:100000.0 !RIPPLE_PUDDLES !RIPPLE_WATER !Puddles ShaderSnow:0 CUMULONIMBUS:0 CloudLayer0 !CloudLayer1 CloudLayer2 !CloudLayer3 VL_RENDER_RESOLUTION:0.25 indirect_effect:1 RAY_COUNT:4 VL_SAMPLES:6 REALMOON shadowMapResolution:1536 shadowDistance:112.0 !DH_SCREENSPACE_REFLECTIONS !LPV_ENABLED SAND_STORMS SNOW_STORMS TAA_UPSCALING SCALE_FACTOR:0.9 SHARPENING:0.45 FORWARD_ENVIORNMENT_REFLECTION profile.MEDIUM = MOON_NORMALS RAINBOW:1 CUSTOM_MOON_ROTATION CUSTOM_SHADOWS_QUALITY:1 END_ISLAND_LIGHT CloudLayer0_distance:100000.0 CloudLayer1_distance:100000.0 !RIPPLE_PUDDLES RIPPLE_WATER !Puddles ShaderSnow:0 CUMULONIMBUS:0 CloudLayer0 CloudLayer1 CloudLayer2 !CloudLayer3 VL_RENDER_RESOLUTION:0.5 indirect_effect:1 RAY_COUNT:4 SAMPLES:6 REALMOON shadowMapResolution:2048 shadowDistance:128.0 DH_SCREENSPACE_REFLECTIONS !LPV_ENABLED SAND_STORMS SNOW_STORMS !TAA_UPSCALING SCALE_FACTOR:0.75 SHARPENING:0.45 FORWARD_ENVIORNMENT_REFLECTION -profile.HIGH = MOON_NORMALS RAINBOW:1 CUSTOM_MOON_ROTATION CUSTOM_SHADOWS_QUALITY:1 END_ISLAND_LIGHT CloudLayer0_distance:100000.0 CloudLayer1_distance:100000.0 RIPPLE_PUDDLES RIPPLE_WATER Puddles ShaderSnow:1 CUMULONIMBUS:0 CloudLayer0 CloudLayer1 CloudLayer2 !CloudLayer3 VL_RENDER_RESOLUTION:0.5 indirect_effect:1 RAY_COUNT:4 SAMPLES:8 REALMOON shadowMapResolution:2048 shadowDistance:128.0 DH_SCREENSPACE_REFLECTIONS LPV_ENABLED SAND_STORMS SNOW_STORMS !TAA_UPSCALING SCALE_FACTOR:0.75 SHARPENING:0.45 FORWARD_ENVIORNMENT_REFLECTION +profile.HIGH = MOON_NORMALS RAINBOW:1 CUSTOM_MOON_ROTATION CUSTOM_SHADOWS_QUALITY:1 END_ISLAND_LIGHT CloudLayer0_distance:100000.0 CloudLayer1_distance:100000.0 RIPPLE_PUDDLES RIPPLE_WATER Puddles ShaderSnow:1 CUMULONIMBUS:0 CloudLayer0 CloudLayer1 CloudLayer2 !CloudLayer3 VL_RENDER_RESOLUTION:0.5 indirect_effect:1 RAY_COUNT:4 SAMPLES:8 REALMOON shadowMapResolution:2560 shadowDistance:128.0 DH_SCREENSPACE_REFLECTIONS LPV_ENABLED SAND_STORMS SNOW_STORMS !TAA_UPSCALING SCALE_FACTOR:0.75 SHARPENING:0.45 FORWARD_ENVIORNMENT_REFLECTION profile.VERY_HIGH = MOON_NORMALS RAINBOW:1 CUSTOM_MOON_ROTATION CUSTOM_SHADOWS_QUALITY:2 END_ISLAND_LIGHT CloudLayer0_distance:100000.0 CloudLayer1_distance:100000.0 RIPPLE_PUDDLES RIPPLE_WATER Puddles ShaderSnow:1 CUMULONIMBUS:0 CloudLayer0 CloudLayer1 CloudLayer2 CloudLayer3 VL_RENDER_RESOLUTION:1.0 indirect_effect:3 RAY_COUNT:4 SAMPLES:8 REALMOON shadowMapResolution:3172 shadowDistance:144.0 DH_SCREENSPACE_REFLECTIONS LPV_ENABLED SAND_STORMS SNOW_STORMS !TAA_UPSCALING SCALE_FACTOR:0.75 SHARPENING:0.45 FORWARD_ENVIORNMENT_REFLECTION profile.ULTRA = MOON_NORMALS RAINBOW:1 CUSTOM_MOON_ROTATION CUSTOM_SHADOWS_QUALITY:2 END_ISLAND_LIGHT CloudLayer0_distance:100000.0 CloudLayer1_distance:100000.0 RIPPLE_PUDDLES RIPPLE_WATER Puddles ShaderSnow:1 CUMULONIMBUS:1 CloudLayer0 CloudLayer1 CloudLayer2 CloudLayer3 VL_RENDER_RESOLUTION:1.0 indirect_effect:4 RAY_COUNT:6 SAMPLES:10 REALMOON shadowMapResolution:4096 shadowDistance:144.0 DH_SCREENSPACE_REFLECTIONS LPV_ENABLED SAND_STORMS SNOW_STORMS !TAA_UPSCALING SCALE_FACTOR:0.75 SHARPENING:0.45 FORWARD_ENVIORNMENT_REFLECTION @@ -188,7 +188,7 @@ alphaTest.gbuffers_water = false alphaTest.gbuffers_skybasic = false alphaTest.gbuffers_skytextured = false -sliders = RAINBOW_TIME RAINBOW RAINBOW_DISTANCE RAINBOW_BRIGHTNESS VORTEX_LIGHT_COL_R VORTEX_LIGHT_COL_G VORTEX_LIGHT_COL_B END_LIGHTNING_COL_R END_LIGHTNING_COL_G END_LIGHTNING_COL_B END_HAZE_DENSTIY NETHER_CEILING_SMOKE_DENSITY NETHER_HAZE_DENSITY Max_Filter_Depth_END Min_Shadow_Filter_Radius_END MOON_TIME_OFFSET EARTH_ROTATION_TILT CUSTOM_SHADOWS_QUALITY MOON_LATITUDE MOON_SIZE_SETTING MONTH_LENGTH LIGHTNING_SHADOWS WHITE_BALANCE STARS_BRIGHTNESS STARS_AMOUNT AmbientLightEnd_R AmbientLightEnd_G AmbientLightEnd_B CloudLayer0_distance CloudLayer1_distance CloudLayer2_distance CloudLayer3_distance BLEND_FACTOR_DURING_MOVEMENT CloudLayer0_detail CloudLayer1_detail LPV_VL_FOG_ILLUMINATION MIN_LIGHT_AMOUNT_INSIDE CUMULONIMBUS_FADE_TIME CUMULONIMBUS NOISE_RESOLUTION NOISE_INTENSITY NOISE_DROPOFF WAVE_DETAIL DH_CHUNK_FADING CLOUD_MOVEMENT_TYPE LIGHTLEAKFIX_MODE EMISSIVE_ORES_STRENGTH RIPPLE_STRENGTH RIPPLE_INTENSITY CUSTOM_LIGHTNING_SCALE CUSTOM_LIGHTNING_R CUSTOM_LIGHTNING_G CUSTOM_LIGHTNING_B CUSTOM_LIGHTNING_TEX CUSTOM_LIGHTNING_POS_X CUSTOM_LIGHTNING_POS_Y CUSTOM_LIGHTNING_POS_Z CUMULONIMBUS_LIGHTNING_BRIGHTNESS CUMULONIMBUS_LIGHTNING_DELAY ShaderSnow ShaderSnowStrength BorderFogIntensity CAVE_DETECTION ON_FIRE_DISTORT_EFFECT_STRENGTH USE_CUSTOM_SKY_GROUND_LIGHTING_COLORS DIRECTLIGHT_DIFFUSE_R DIRECTLIGHT_DIFFUSE_G DIRECTLIGHT_DIFFUSE_B INDIRECTLIGHT_DIFFUSE_R INDIRECTLIGHT_DIFFUSE_G INDIRECTLIGHT_DIFFUSE_B DIRECTLIGHT_CLOUDS_R DIRECTLIGHT_CLOUDS_G DIRECTLIGHT_CLOUDS_B INDIRECTLIGHT_CLOUDS_R INDIRECTLIGHT_CLOUDS_G INDIRECTLIGHT_CLOUDS_B DIRECTLIGHT_FOG_R DIRECTLIGHT_FOG_G DIRECTLIGHT_FOG_B INDIRECTLIGHT_FOG_R INDIRECTLIGHT_FOG_G INDIRECTLIGHT_FOG_B SKY_GROUND_R SKY_GROUND_G SKY_GROUND_B DOF_DISPERSION_MULT FLASHLIGHT_BRIGHTNESS_MULT FLASHLIGHT_BRIGHTNESS_FALLOFF_MULT FLASHLIGHT_RANGE FLASHLIGHT_SIZE FLASHLIGHT_R FLASHLIGHT_G FLASHLIGHT_B LOW_HEALTH_EFFECT_START CRITICALLY_LOW_HEALTH_EFFECT_START CloudLayer2_scale CloudLayer0_scale CloudLayer1_scale CloudLayer3_scale CloudLayer0_tallness CloudLayer1_tallness EXPOSURE_DARKENING EXPOSURE_BRIGHTENING VIGNETTE_STRENGTH CURVATURE_AMOUNT MINIMUM_WATER_ABSORBANCE CHROMATIC_ABERRATION_STRENGTH SELECT_BOX_COL_R SELECT_BOX_COL_G SELECT_BOX_COL_B LPV_VL_FOG_ILLUMINATION_BRIGHTNESS minRayMarchSteps MOTION_BLUR_STRENGTH OVERDRAW_MAX_DISTANCE DAY0_l3_coverage DAY0_l3_density DAY1_l3_coverage DAY1_l3_density DAY2_l3_coverage DAY2_l3_density DAY3_l3_coverage DAY3_l3_density DAY4_l3_coverage DAY4_l3_density DAY5_l3_coverage DAY5_l3_density DAY6_l3_coverage DAY6_l3_density DAY7_l3_coverage DAY7_l3_density DAY8_l3_coverage DAY8_l3_density DAY9_l3_coverage DAY9_l3_density DAY0_l0_coverage DAY0_l1_coverage DAY0_l2_coverage DAY0_ufog_density DAY0_l0_density DAY0_l1_density DAY0_l2_density DAY0_cfog_density DAY1_l0_coverage DAY1_l1_coverage DAY1_l2_coverage DAY1_ufog_density DAY1_l0_density DAY1_l1_density DAY1_l2_density DAY1_cfog_density DAY2_l0_coverage DAY2_l1_coverage DAY2_l2_coverage DAY2_ufog_density DAY2_l0_density DAY2_l1_density DAY2_l2_density DAY2_cfog_density DAY3_l0_coverage DAY3_l1_coverage DAY3_l2_coverage DAY3_ufog_density DAY3_l0_density DAY3_l1_density DAY3_l2_density DAY3_cfog_density DAY4_l0_coverage DAY4_l1_coverage DAY4_l2_coverage DAY4_ufog_density DAY4_l0_density DAY4_l1_density DAY4_l2_density DAY4_cfog_density DAY5_l0_coverage DAY5_l1_coverage DAY5_l2_coverage DAY5_ufog_density DAY5_l0_density DAY5_l1_density DAY5_l2_density DAY5_cfog_density DAY6_l0_coverage DAY6_l1_coverage DAY6_l2_coverage DAY6_ufog_density DAY6_l0_density DAY6_l1_density DAY6_l2_density DAY6_cfog_density DAY7_l0_coverage DAY7_l1_coverage DAY7_l2_coverage DAY7_ufog_density DAY7_l0_density DAY7_l1_density DAY7_l2_density DAY7_cfog_density DAY8_l0_coverage DAY8_l1_coverage DAY8_l2_coverage DAY8_ufog_density DAY8_l0_density DAY8_l1_density DAY8_l2_density DAY8_cfog_density DAY9_l0_coverage DAY9_l1_coverage DAY9_l2_coverage DAY9_ufog_density DAY9_l0_density DAY9_l1_density DAY9_l2_density DAY9_cfog_density sss_density_multiplier sss_absorbance_multiplier MOTION_AMOUNT TONEMAP WATER_WAVE_SPEED WATER_CAUSTICS_BRIGHTNESS WATER_CAUSTICS_POWER DEBUG_VIEW entityShadowDistanceMul HANDHELD_LIGHT_RANGE CLOUD_SHADOW_STRENGTH CloudLayer0_coverage CloudLayer0_density CloudLayer0_height CloudLayer1_coverage CloudLayer1_density CloudLayer1_height CloudLayer2_coverage CloudLayer2_density CloudLayer2_height CloudLayer3_coverage CloudLayer3_density CloudLayer3_height PLANET_GROUND_BRIGHTNESS FOG_START_HEIGHT WATER_WAVE_STRENGTH SWAMP_UNIFORM_DENSITY SWAMP_CLOUDY_DENSITY SWAMP_R SWAMP_G SWAMP_B JUNGLE_UNIFORM_DENSITY JUNGLE_CLOUDY_DENSITY JUNGLE_R JUNGLE_G JUNGLE_B DARKFOREST_UNIFORM_DENSITY DARKFOREST_CLOUDY_DENSITY DARKFOREST_R DARKFOREST_G DARKFOREST_B NETHER_PLUME_DENSITY END_STORM_DENSTIY LIT_PARTICLE_BRIGHTNESS UPPER_CURVE LOWER_CURVE EMISSIVE_TYPE SCALE_FACTOR ambientsss_brightness SSS_TYPE Cloud_Speed Cloud_Speed_Rain Cloud_Speed_Thunder ORB_ColMult ORB_X ORB_Y ORB_Z ORB_R ORB_G ORB_B TOD_Fog_mult Morning_Uniform_Fog Noon_Uniform_Fog Evening_Uniform_Fog Night_Uniform_Fog Morning_Cloudy_Fog Noon_Cloudy_Fog Evening_Cloudy_Fog Night_Cloudy_Fog Summer_Leaf_R Summer_Leaf_G Summer_Leaf_B Fall_Leaf_R Fall_Leaf_G Fall_Leaf_B Winter_Leaf_R Winter_Leaf_G Winter_Leaf_B Spring_Leaf_R Spring_Leaf_G Spring_Leaf_B Summer_R Summer_G Summer_B Fall_R Fall_G Fall_B Winter_R Winter_G Winter_B Spring_R Spring_G Spring_B Season_Length CaveFogFallOff CaveFogColor_R CaveFogColor_G CaveFogColor_B indirect_effect GI_Strength ambient_brightness AmbientLightRain_R AmbientLightRain_G AmbientLightRain_B AmbientLight_R AmbientLight_G AmbientLight_B Rain_coverage Thunder_coverage Moon_temp Haze_amount RainFog_amount Sun_temp Puddle_Size Puddle_Reflection_Sharpness LabSSS_Curve Emissive_Curve Emissive_Brightness AO_Strength BLOOMY_FOG WAVY_SPEED WAVY_STRENGTH BLOOM_STRENGTH shadowDistance Sky_Brightness fog_coefficientMieR fog_coefficientMieG fog_coefficientMieB sun_illuminance sunColorG sunColorB sunColorR sky_mieg sky_coefficientMieB sky_coefficientMieG sky_coefficientMieR sky_coefficientRayleighB sky_coefficientRayleighG sky_coefficientRayleighR CLOUDS_QUALITY EXPOSURE_MULTIPLIER MIN_LIGHT_AMOUNT TORCH_R TORCH_G TORCH_B TORCH_AMOUNT shadowMapResolution sunPathRotation BLEND_FACTOR VL_SAMPLES Exposure_Speed POM_DEPTH MAX_ITERATIONS MAX_DIST SSR_STEPS ambientOcclusionLevel SEA_LEVEL moon_illuminance moonColorR moonColorG moonColorB fog_coefficientRayleighR fog_coefficientRayleighG SATURATION Manual_exposure_value focal fstop MANUAL_FOCUS SHADOW_FILTER_SAMPLE_COUNT Max_Filter_Depth VPS_Search_Samples Min_Shadow_Filter_Radius Max_Shadow_Filter_Radius Water_Top_Layer fog_coefficientRayleighB SHARPENING rayMarchSampleCount Dirt_Amount Dirt_Scatter_R Dirt_Scatter_G Dirt_Scatter_B Dirt_Absorb_R Dirt_Absorb_G Dirt_Absorb_B Water_Absorb_R Water_Absorb_G Water_Absorb_B Purkinje_strength Purkinje_strength Purkinje_R Purkinje_G Purkinje_B Texture_MipMap_Bias DoF_Adaptation_Speed Purkinje_Multiplier CROSSTALK VL_RENDER_RESOLUTION BLOOM_QUALITY VL_RENDER_RESOLUTION RAY_COUNT STEPS STEP_LENGTH cloud_LevelOfDetail cloud_ShadowLevelOfDetail cloud_LevelOfDetailLQ cloud_ShadowLevelOfDetailLQ minRayMarchSteps maxRayMarchSteps minRayMarchStepsLQ maxRayMarchStepsLQ fbmAmount fbmPower1 fbmPower2 Roughness_Threshold Sun_specular_Strength reflection_quality DOF_QUALITY DOF_ANAMORPHIC_RATIO AEROCHROME_PINKNESS DOF_JITTER_FOCUS JITTER_STRENGTH SHADOWS_GRADE_R MIDS_GRADE_R HIGHLIGHTS_GRADE_R SHADOWS_GRADE_G MIDS_GRADE_G HIGHLIGHTS_GRADE_G SHADOWS_GRADE_B MIDS_GRADE_B HIGHLIGHTS_GRADE_B SHADOWS_GRADE_MUL MIDS_GRADE_MUL HIGHLIGHTS_GRADE_MUL LPV_SATURATION LPV_TINT_SATURATION LPV_NORMAL_STRENGTH +sliders = FAKE_REFRACTION_AMOUNT FAKE_DISPERSION_AMOUNT REFRACTION_SMUDGE_AMOUNT NORMAL_MAP_MULT DEFERRED_SSR_QUALITY FORWARD_SSR_QUALITY RAINBOW_TIME RAINBOW RAINBOW_DISTANCE RAINBOW_BRIGHTNESS VORTEX_LIGHT_COL_R VORTEX_LIGHT_COL_G VORTEX_LIGHT_COL_B END_LIGHTNING_COL_R END_LIGHTNING_COL_G END_LIGHTNING_COL_B END_HAZE_DENSTIY NETHER_CEILING_SMOKE_DENSITY NETHER_HAZE_DENSITY Max_Filter_Depth_END Min_Shadow_Filter_Radius_END MOON_TIME_OFFSET EARTH_ROTATION_TILT CUSTOM_SHADOWS_QUALITY MOON_LATITUDE MOON_SIZE_SETTING MONTH_LENGTH LIGHTNING_SHADOWS WHITE_BALANCE STARS_BRIGHTNESS STARS_AMOUNT AmbientLightEnd_R AmbientLightEnd_G AmbientLightEnd_B CloudLayer0_distance CloudLayer1_distance CloudLayer2_distance CloudLayer3_distance BLEND_FACTOR_DURING_MOVEMENT CloudLayer0_detail CloudLayer1_detail LPV_VL_FOG_ILLUMINATION MIN_LIGHT_AMOUNT_INSIDE CUMULONIMBUS_FADE_TIME CUMULONIMBUS NOISE_RESOLUTION NOISE_INTENSITY NOISE_DROPOFF WAVE_DETAIL DH_CHUNK_FADING CLOUD_MOVEMENT_TYPE LIGHTLEAKFIX_MODE EMISSIVE_ORES_STRENGTH RIPPLE_STRENGTH RIPPLE_INTENSITY CUSTOM_LIGHTNING_SCALE CUSTOM_LIGHTNING_R CUSTOM_LIGHTNING_G CUSTOM_LIGHTNING_B CUSTOM_LIGHTNING_TEX CUSTOM_LIGHTNING_POS_X CUSTOM_LIGHTNING_POS_Y CUSTOM_LIGHTNING_POS_Z CUMULONIMBUS_LIGHTNING_BRIGHTNESS CUMULONIMBUS_LIGHTNING_DELAY ShaderSnow ShaderSnowStrength BorderFogIntensity CAVE_DETECTION ON_FIRE_DISTORT_EFFECT_STRENGTH USE_CUSTOM_SKY_GROUND_LIGHTING_COLORS DIRECTLIGHT_DIFFUSE_R DIRECTLIGHT_DIFFUSE_G DIRECTLIGHT_DIFFUSE_B INDIRECTLIGHT_DIFFUSE_R INDIRECTLIGHT_DIFFUSE_G INDIRECTLIGHT_DIFFUSE_B DIRECTLIGHT_CLOUDS_R DIRECTLIGHT_CLOUDS_G DIRECTLIGHT_CLOUDS_B INDIRECTLIGHT_CLOUDS_R INDIRECTLIGHT_CLOUDS_G INDIRECTLIGHT_CLOUDS_B DIRECTLIGHT_FOG_R DIRECTLIGHT_FOG_G DIRECTLIGHT_FOG_B INDIRECTLIGHT_FOG_R INDIRECTLIGHT_FOG_G INDIRECTLIGHT_FOG_B SKY_GROUND_R SKY_GROUND_G SKY_GROUND_B DOF_DISPERSION_MULT FLASHLIGHT_BRIGHTNESS_MULT FLASHLIGHT_BRIGHTNESS_FALLOFF_MULT FLASHLIGHT_RANGE FLASHLIGHT_SIZE FLASHLIGHT_R FLASHLIGHT_G FLASHLIGHT_B LOW_HEALTH_EFFECT_START CRITICALLY_LOW_HEALTH_EFFECT_START CloudLayer2_scale CloudLayer0_scale CloudLayer1_scale CloudLayer3_scale CloudLayer0_tallness CloudLayer1_tallness EXPOSURE_DARKENING EXPOSURE_BRIGHTENING VIGNETTE_STRENGTH CURVATURE_AMOUNT MINIMUM_WATER_ABSORBANCE CHROMATIC_ABERRATION_STRENGTH SELECT_BOX_COL_R SELECT_BOX_COL_G SELECT_BOX_COL_B LPV_VL_FOG_ILLUMINATION_BRIGHTNESS minRayMarchSteps MOTION_BLUR_STRENGTH OVERDRAW_MAX_DISTANCE DAY0_l3_coverage DAY0_l3_density DAY1_l3_coverage DAY1_l3_density DAY2_l3_coverage DAY2_l3_density DAY3_l3_coverage DAY3_l3_density DAY4_l3_coverage DAY4_l3_density DAY5_l3_coverage DAY5_l3_density DAY6_l3_coverage DAY6_l3_density DAY7_l3_coverage DAY7_l3_density DAY8_l3_coverage DAY8_l3_density DAY9_l3_coverage DAY9_l3_density DAY0_l0_coverage DAY0_l1_coverage DAY0_l2_coverage DAY0_ufog_density DAY0_l0_density DAY0_l1_density DAY0_l2_density DAY0_cfog_density DAY1_l0_coverage DAY1_l1_coverage DAY1_l2_coverage DAY1_ufog_density DAY1_l0_density DAY1_l1_density DAY1_l2_density DAY1_cfog_density DAY2_l0_coverage DAY2_l1_coverage DAY2_l2_coverage DAY2_ufog_density DAY2_l0_density DAY2_l1_density DAY2_l2_density DAY2_cfog_density DAY3_l0_coverage DAY3_l1_coverage DAY3_l2_coverage DAY3_ufog_density DAY3_l0_density DAY3_l1_density DAY3_l2_density DAY3_cfog_density DAY4_l0_coverage DAY4_l1_coverage DAY4_l2_coverage DAY4_ufog_density DAY4_l0_density DAY4_l1_density DAY4_l2_density DAY4_cfog_density DAY5_l0_coverage DAY5_l1_coverage DAY5_l2_coverage DAY5_ufog_density DAY5_l0_density DAY5_l1_density DAY5_l2_density DAY5_cfog_density DAY6_l0_coverage DAY6_l1_coverage DAY6_l2_coverage DAY6_ufog_density DAY6_l0_density DAY6_l1_density DAY6_l2_density DAY6_cfog_density DAY7_l0_coverage DAY7_l1_coverage DAY7_l2_coverage DAY7_ufog_density DAY7_l0_density DAY7_l1_density DAY7_l2_density DAY7_cfog_density DAY8_l0_coverage DAY8_l1_coverage DAY8_l2_coverage DAY8_ufog_density DAY8_l0_density DAY8_l1_density DAY8_l2_density DAY8_cfog_density DAY9_l0_coverage DAY9_l1_coverage DAY9_l2_coverage DAY9_ufog_density DAY9_l0_density DAY9_l1_density DAY9_l2_density DAY9_cfog_density sss_density_multiplier sss_absorbance_multiplier MOTION_AMOUNT TONEMAP WATER_WAVE_SPEED WATER_CAUSTICS_BRIGHTNESS WATER_CAUSTICS_POWER DEBUG_VIEW entityShadowDistanceMul HANDHELD_LIGHT_RANGE CLOUD_SHADOW_STRENGTH CloudLayer0_coverage CloudLayer0_density CloudLayer0_height CloudLayer1_coverage CloudLayer1_density CloudLayer1_height CloudLayer2_coverage CloudLayer2_density CloudLayer2_height CloudLayer3_coverage CloudLayer3_density CloudLayer3_height PLANET_GROUND_BRIGHTNESS FOG_START_HEIGHT WATER_WAVE_STRENGTH SWAMP_UNIFORM_DENSITY SWAMP_CLOUDY_DENSITY SWAMP_R SWAMP_G SWAMP_B JUNGLE_UNIFORM_DENSITY JUNGLE_CLOUDY_DENSITY JUNGLE_R JUNGLE_G JUNGLE_B DARKFOREST_UNIFORM_DENSITY DARKFOREST_CLOUDY_DENSITY DARKFOREST_R DARKFOREST_G DARKFOREST_B NETHER_PLUME_DENSITY END_STORM_DENSTIY LIT_PARTICLE_BRIGHTNESS UPPER_CURVE LOWER_CURVE EMISSIVE_TYPE SCALE_FACTOR ambientsss_brightness SSS_TYPE Cloud_Speed Cloud_Speed_Rain Cloud_Speed_Thunder ORB_ColMult ORB_X ORB_Y ORB_Z ORB_R ORB_G ORB_B TOD_Fog_mult Morning_Uniform_Fog Noon_Uniform_Fog Evening_Uniform_Fog Night_Uniform_Fog Morning_Cloudy_Fog Noon_Cloudy_Fog Evening_Cloudy_Fog Night_Cloudy_Fog Summer_Leaf_R Summer_Leaf_G Summer_Leaf_B Fall_Leaf_R Fall_Leaf_G Fall_Leaf_B Winter_Leaf_R Winter_Leaf_G Winter_Leaf_B Spring_Leaf_R Spring_Leaf_G Spring_Leaf_B Summer_R Summer_G Summer_B Fall_R Fall_G Fall_B Winter_R Winter_G Winter_B Spring_R Spring_G Spring_B Season_Length CaveFogFallOff CaveFogColor_R CaveFogColor_G CaveFogColor_B indirect_effect GI_Strength ambient_brightness AmbientLightRain_R AmbientLightRain_G AmbientLightRain_B AmbientLight_R AmbientLight_G AmbientLight_B Rain_coverage Thunder_coverage Moon_temp Haze_amount RainFog_amount Sun_temp Puddle_Size Puddle_Reflection_Sharpness LabSSS_Curve Emissive_Curve Emissive_Brightness AO_Strength BLOOMY_FOG WAVY_SPEED WAVY_STRENGTH BLOOM_STRENGTH shadowDistance Sky_Brightness fog_coefficientMieR fog_coefficientMieG fog_coefficientMieB sun_illuminance sunColorG sunColorB sunColorR sky_mieg sky_coefficientMieB sky_coefficientMieG sky_coefficientMieR sky_coefficientRayleighB sky_coefficientRayleighG sky_coefficientRayleighR CLOUDS_QUALITY EXPOSURE_MULTIPLIER MIN_LIGHT_AMOUNT TORCH_R TORCH_G TORCH_B TORCH_AMOUNT shadowMapResolution sunPathRotation BLEND_FACTOR VL_SAMPLES Exposure_Speed POM_DEPTH MAX_ITERATIONS MAX_DIST ambientOcclusionLevel SEA_LEVEL moon_illuminance moonColorR moonColorG moonColorB fog_coefficientRayleighR fog_coefficientRayleighG SATURATION Manual_exposure_value focal fstop MANUAL_FOCUS SHADOW_FILTER_SAMPLE_COUNT Max_Filter_Depth VPS_Search_Samples Min_Shadow_Filter_Radius Max_Shadow_Filter_Radius Water_Top_Layer fog_coefficientRayleighB SHARPENING rayMarchSampleCount Dirt_Amount Dirt_Scatter_R Dirt_Scatter_G Dirt_Scatter_B Dirt_Absorb_R Dirt_Absorb_G Dirt_Absorb_B Water_Absorb_R Water_Absorb_G Water_Absorb_B Purkinje_strength Purkinje_strength Purkinje_R Purkinje_G Purkinje_B Texture_MipMap_Bias DoF_Adaptation_Speed Purkinje_Multiplier CROSSTALK VL_RENDER_RESOLUTION BLOOM_QUALITY VL_RENDER_RESOLUTION RAY_COUNT STEPS STEP_LENGTH cloud_LevelOfDetail cloud_ShadowLevelOfDetail cloud_LevelOfDetailLQ cloud_ShadowLevelOfDetailLQ minRayMarchSteps maxRayMarchSteps minRayMarchStepsLQ maxRayMarchStepsLQ fbmAmount fbmPower1 fbmPower2 ROUGHNESS_THRESHOLD SUN_SPECULAR_MULT reflection_quality DOF_QUALITY DOF_ANAMORPHIC_RATIO AEROCHROME_PINKNESS DOF_JITTER_FOCUS JITTER_STRENGTH SHADOWS_GRADE_R MIDS_GRADE_R HIGHLIGHTS_GRADE_R SHADOWS_GRADE_G MIDS_GRADE_G HIGHLIGHTS_GRADE_G SHADOWS_GRADE_B MIDS_GRADE_B HIGHLIGHTS_GRADE_B SHADOWS_GRADE_MUL MIDS_GRADE_MUL HIGHLIGHTS_GRADE_MUL LPV_SATURATION LPV_TINT_SATURATION LPV_NORMAL_STRENGTH screen.columns=2 screen = \ @@ -253,16 +253,16 @@ SHADER_VERSION_LABEL \ ### RESOURCE PACK SUPPORT screen.Resource_Pack_Support.columns = 1 - screen.Resource_Pack_Support = [Reflections] [Emissives] [Subsurface_Scattering] [POM] MATERIAL_AO RESOURCEPACK_SKY + screen.Resource_Pack_Support = [SPECULAR] [Emissives] [Subsurface_Scattering] [POM] [Refraction] MATERIAL_AO \ + SUN_SPECULAR_MULT ROUGHNESS_THRESHOLD screen.Subsurface_Scattering.columns=1 screen.Subsurface_Scattering = SSS_TYPE sss_density_multiplier sss_absorbance_multiplier LabSSS_Curve MISC_BLOCK_SSS MOB_SSS Ambient_SSS ambientsss_brightness SCREENSPACE_DIRECT_SSS_BLENDING @@ -275,6 +275,9 @@ SHADER_VERSION_LABEL \ screen.Porosity.columns = 1 screen.Porosity = Porosity + + screen.Refraction.columns = 1 + screen.Refraction = FAKE_REFRACTION_AMOUNT FAKE_DISPERSION_AMOUNT REFRACTION_SMUDGE_AMOUNT SNELLS_WINDOW [Water] ### FloodFill screen.LPV.columns = 2 @@ -398,12 +401,10 @@ SHADER_VERSION_LABEL \ ### WATER screen.Water.columns=2 - screen.Water = FAKE_REFRACTION_EFFECT [Water_fog_color] \ - FAKE_DISPERSION_EFFECT Dirt_Amount \ - REFRACTION_SMUDGE MINIMUM_WATER_ABSORBANCE \ - SNELLS_WINDOW Water_Top_Layer \ - WATER_WAVE_STRENGTH WATER_WAVE_SPEED \ - WAVE_DETAIL WATER_INTERACTION + screen.Water = Dirt_Amount [Water_fog_color] \ + MINIMUM_WATER_ABSORBANCE SNELLS_WINDOW \ + WATER_WAVE_SPEED Water_Top_Layer \ + WATER_WAVE_STRENGTH \ screen.Water_fog_color.columns=1 screen.Water_fog_color = Dirt_Scatter_R Dirt_Scatter_G Dirt_Scatter_B Dirt_Absorb_R Dirt_Absorb_G Dirt_Absorb_B Water_Absorb_R Water_Absorb_G Water_Absorb_B @@ -677,7 +678,7 @@ uniform.bool.isInJungleBiomes = in(biome_category, CAT_JUNGLE) # using the smooth() function to interpolate to the newest value of eyeAltitude over time, i can make it take a very long time to interpolate. essentially freezing/unfreezing the value in place at any time i need to. # force water surface level to a fixed height if you entered the water from an area in low light levels (caves). if youre above the hardcoded y level, allow it use the current height -variable.float.waterEnteredLowLight = if(eyeBrightness.y < 0.004, max(eyeAltitude, SEA_LEVEL), eyeAltitude) +variable.float.waterEnteredLowLight = if(eyeBrightness.y < 0.004, max(eyeAltitude+16.0, SEA_LEVEL), eyeAltitude) variable.float.freezeTranstion = if(isEyeInWater == 1, 100000000000000.0, 0.0) uniform.float.waterEnteredAltitude = smooth(waterEnteredLowLight, freezeTranstion, freezeTranstion) diff --git a/shaders/world1/shadow.fsh b/shaders/world1/shadow.fsh index c0ce056..7898fae 100644 --- a/shaders/world1/shadow.fsh +++ b/shaders/world1/shadow.fsh @@ -9,7 +9,6 @@ varying vec4 color; varying vec2 texcoord; -varying vec3 vertexPos; uniform sampler2D tex; uniform sampler2D texture; uniform sampler2D noisetex; @@ -32,15 +31,6 @@ float blueNoise(){ void main() { #ifdef END_ISLAND_LIGHT if (LIGHTNING > 0.0) discard; - - //#if defined DISTANT_HORIZONS && DH_CHUNK_FADING > 1 - // float viewDist = length(vertexPos); - // float minDist = min(shadowDistance, far); - // - // float ditherFade = smoothstep(0.93 * minDist, minDist, viewDist); - // - // if (step(ditherFade, blueNoise()) == 0.0) discard; - //#endif vec4 shadowColor = vec4(texture2D(tex,texcoord.xy).rgb * color.rgb, texture2DLod(tex, texcoord.xy, 0).a); diff --git a/shaders/world1/shadow.vsh b/shaders/world1/shadow.vsh index 022a8e6..c2da24b 100644 --- a/shaders/world1/shadow.vsh +++ b/shaders/world1/shadow.vsh @@ -50,7 +50,6 @@ varying float LIGHTNING; varying vec4 color; varying vec2 texcoord; -varying vec3 vertexPos; //#include "/lib/Shadow_Params.glsl" @@ -59,19 +58,10 @@ varying vec3 vertexPos; void main() { - texcoord.xy = gl_MultiTexCoord0.xy; - color = gl_Color; - vertexPos = gl_Vertex.xyz; - - LIGHTNING = 0.0; - if (entityId == ENTITY_LIGHTNING) LIGHTNING = 1.0; - - //entity = 0.0; - //if (renderStage == MC_RENDER_STAGE_ENTITIES) entity = 1.0; - #if defined END_ISLAND_LIGHT || (defined IS_LPV_ENABLED && defined MC_GL_EXT_shader_image_load_store) vec3 shadowViewPos = mat3(gl_ModelViewMatrix) * vec3(gl_Vertex) + gl_ModelViewMatrix[3].xyz; vec3 feetPlayerPos = mat3(shadowModelViewInverse) * shadowViewPos + shadowModelViewInverse[3].xyz; + #endif #if defined IS_LPV_ENABLED && defined MC_GL_EXT_shader_image_load_store #ifdef LPV_NOSHADOW_HACK @@ -84,6 +74,14 @@ void main() { #endif #ifdef END_ISLAND_LIGHT + texcoord.xy = gl_MultiTexCoord0.xy; + color = gl_Color; + + // hide lightning and dragon death beams + vec3 normal = normalize(gl_NormalMatrix * gl_Normal); + LIGHTNING = 0.0; + if (renderStage == MC_RENDER_STAGE_ENTITIES && (entityId == ENTITY_LIGHTNING || (entityId == 0 && gl_Color.a < 0.2 && abs(normal.y) < 0.2))) LIGHTNING = 1.0; + gl_Position = customShadowPerspectiveSSBO * customShadowMatrixSSBO * vec4(feetPlayerPos, 1.0); gl_Position.z /= 6.0;