rusting_engine 2.7.0

Vulkan 3D game engine with GPU-accelerated physics for massive physics-heavy scenes
1
2
3
4
5
6
7
8
9
10
11
12
#version 450
// Alpha-tested shadow casters: Mask materials cast through the holes in
// their base color texture, like the scene pass discards them.
layout(location = 0) in vec2 v_uv;
layout(location = 1) in float v_alpha;
layout(location = 2) flat in float v_cutoff;
layout(set = 1, binding = 0) uniform sampler2D base_color_texture;
void main() {
    if (v_alpha * texture(base_color_texture, v_uv).a < v_cutoff) {
        discard;
    }
}