quakeforge/libs/video/renderer/vulkan/shader/alias_shadow.vert
Bill Currie 8c03ed8be5 [vulkan] Start work on shadows
This gets the shaders needed for creating shadow maps, and the changes
to the lighting pipeline for binding the shadow maps, but no generation
or reading is done yet. It feels like parts of various systems are
getting a little big for their britches and I need to do an audit of
various things.
2021-04-24 10:40:39 +09:00

23 lines
445 B
GLSL

#version 450
layout (push_constant) uniform PushConstants {
mat4 Model;
float blend;
};
layout (location = 0) in vec4 vertexa;
layout (location = 1) in vec3 normala;
layout (location = 2) in vec4 vertexb;
layout (location = 3) in vec3 normalb;
layout (location = 0) out int InstanceIndex;
void
main (void)
{
vec4 vertex;
vertex = mix (vertexa, vertexb, blend);
gl_Position = Model * vertex;
InstanceIndex = gl_InstanceIndex;
}