17 lines
413 B
GLSL
17 lines
413 B
GLSL
#import "Common/ShaderLib/GLSLCompat.glsllib"
|
|
|
|
uniform sampler2D m_LeafMap;
|
|
uniform float m_AlphaDiscardThreshold;
|
|
varying vec2 texCoord;
|
|
|
|
void main() {
|
|
#ifdef HAS_LEAFMAP
|
|
float alpha = texture2D(m_LeafMap, texCoord).a;
|
|
if (alpha < m_AlphaDiscardThreshold) {
|
|
discard;
|
|
}
|
|
#endif
|
|
|
|
// Wir schreiben nur die Tiefe, die Farbe ist egal.
|
|
gl_FragColor = vec4(1.0);
|
|
} |