mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-22 23:30:14 +00:00
Vulcan Nightmare
Experimentally bringing up vulcan support
This commit is contained in:
parent
863a786c48
commit
83b576e8d9
189 changed files with 12147 additions and 7820 deletions
19
assets/shaders/character_shadow.frag.glsl
Normal file
19
assets/shaders/character_shadow.frag.glsl
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
#version 450
|
||||
|
||||
layout(set = 1, binding = 0) uniform sampler2D uTexture;
|
||||
|
||||
layout(set = 1, binding = 1) uniform ShadowParams {
|
||||
int alphaTest;
|
||||
int colorKeyBlack;
|
||||
};
|
||||
|
||||
layout(location = 0) in vec2 TexCoord;
|
||||
|
||||
void main() {
|
||||
vec4 texColor = texture(uTexture, TexCoord);
|
||||
if (alphaTest != 0 && texColor.a < 0.5) discard;
|
||||
if (colorKeyBlack != 0) {
|
||||
float lum = dot(texColor.rgb, vec3(0.299, 0.587, 0.114));
|
||||
if (lum < 0.12) discard;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue