FIX cloud flicker issue. FIX red hurt effect missing for translucent entities. FIX line on water edges. FIX RTAO/SSGI being super dark. IMPROVE cloud lighting and shapes. ADD toggle to use quarter res depth with rtao/ssgi.UPDATE zh_ch.lang file

This commit is contained in:
Xonk
2024-03-12 17:16:30 -04:00
parent 201ee55b9b
commit e0f61f0128
18 changed files with 286 additions and 109 deletions

View File

@ -16,6 +16,7 @@ flat varying vec3 lightSourceColor;
flat varying vec3 sunColor;
flat varying vec3 moonColor;
// flat varying vec3 zenithColor;
// flat varying vec3 rayleighAborbance;
// flat varying vec3 WsunVec;
@ -231,9 +232,10 @@ if (gl_FragCoord.x > pixelPos6.x && gl_FragCoord.x < pixelPos6.x + 1 && gl_FragC
if (gl_FragCoord.x > 8. && gl_FragCoord.x < 9. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
gl_FragData[0] = vec4(sunColor,1.0);
if (gl_FragCoord.x > 13. && gl_FragCoord.x < 14. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
if (gl_FragCoord.x > 9. && gl_FragCoord.x < 10. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
gl_FragData[0] = vec4(moonColor,1.0);
// if (gl_FragCoord.x > 16. && gl_FragCoord.x < 17. && gl_FragCoord.y > 19.+18. && gl_FragCoord.y < 19.+18.+1 )
// gl_FragData[0] = vec4(rayleighAborbance,1.0);
#endif
@ -273,7 +275,7 @@ if (gl_FragCoord.x > 18.+257. && gl_FragCoord.y > 1. && gl_FragCoord.x < 18+257+
vec2 p = clamp(floor(gl_FragCoord.xy-vec2(18.+257,1.))/256.+tempOffsets/256.,0.0,1.0);
vec3 viewVector = cartToSphere(p);
WsunVec = ( float(sunElevation > 1e-5)*2-1. )*normalize(mat3(gbufferModelViewInverse) * sunPosition);
WsunVec = normalize(mat3(gbufferModelViewInverse) * sunPosition) * ( float(sunElevation > 1e-5)*2.0-1.0 );
vec3 sky = texelFetch2D(colortex4,ivec2(gl_FragCoord.xy)-ivec2(257,0),0).rgb/150.0;
@ -287,7 +289,7 @@ if (gl_FragCoord.x > 18.+257. && gl_FragCoord.y > 1. && gl_FragCoord.x < 18+257+
sky = sky*clouds.a + clouds.rgb / 5.0;
sky = mix(dot(sky,vec3(0.333)) * vec3(0.5), sky, pow(clamp(viewVector.y+1.0,0.0,1.0),5));
vec4 VL_Fog = GetVolumetricFog(mat3(gbufferModelView)*viewVector*1024., vec2(fract(frameCounter/1.6180339887),1-fract(frameCounter/1.6180339887)), lightSourceColor*1.75, skyGroundCol/30.0);
vec4 VL_Fog = GetVolumetricFog(mat3(gbufferModelView)*viewVector*1024., vec2(fract(frameCounter/1.6180339887),1-fract(frameCounter/1.6180339887)), suncol*1.75, skyGroundCol/30.0);
sky = sky * VL_Fog.a + VL_Fog.rgb / 5.0;