mirror of
https://github.com/X0nk/Bliss-Shader.git
synced 2025-06-27 02:32:39 +08:00
accidentally left debug setting enabled. fix naming of filepaths for dimension flags
This commit is contained in:
37
shaders/world0_with_aether_flag/shadow.fsh
Normal file
37
shaders/world0_with_aether_flag/shadow.fsh
Normal file
@ -0,0 +1,37 @@
|
||||
#version 120
|
||||
|
||||
#include "/lib/settings.glsl"
|
||||
|
||||
varying vec4 color;
|
||||
|
||||
varying vec2 texcoord;
|
||||
uniform sampler2D tex;
|
||||
uniform sampler2D noisetex;
|
||||
|
||||
//////////////////////////////VOID MAIN//////////////////////////////
|
||||
//////////////////////////////VOID MAIN//////////////////////////////
|
||||
//////////////////////////////VOID MAIN//////////////////////////////
|
||||
//////////////////////////////VOID MAIN//////////////////////////////
|
||||
//////////////////////////////VOID MAIN//////////////////////////////
|
||||
|
||||
float blueNoise(){
|
||||
return fract(texelFetch2D(noisetex, ivec2(gl_FragCoord.xy)%512, 0).a + 1.0/1.6180339887 );
|
||||
}
|
||||
|
||||
|
||||
void main() {
|
||||
|
||||
vec4 shadowColor = vec4(texture2D(tex,texcoord.xy).rgb * color.rgb, texture2DLod(tex, texcoord.xy, 0).a);
|
||||
|
||||
#ifdef TRANSLUCENT_COLORED_SHADOWS
|
||||
if(shadowColor.a > 0.9999) shadowColor.rgb = vec3(0.0);
|
||||
#endif
|
||||
|
||||
gl_FragData[0] = shadowColor;
|
||||
|
||||
// gl_FragData[0] = vec4(texture2D(tex,texcoord.xy).rgb * color.rgb, texture2DLod(tex, texcoord.xy, 0).a);
|
||||
|
||||
#ifdef Stochastic_Transparent_Shadows
|
||||
if(gl_FragData[0].a < blueNoise()) { discard; return;}
|
||||
#endif
|
||||
}
|
Reference in New Issue
Block a user