summaryrefslogtreecommitdiff
path: root/gfx/gl/shaders/shadowDynamicPointInst.vs
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2023-04-23 21:46:21 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2023-04-26 00:07:19 +0100
commite751ab465bbbf1365ec6e108c64dafd03ce42f1d (patch)
treed0c6dc9cd16ea6cdedc89e575af7b012d935d4cb /gfx/gl/shaders/shadowDynamicPointInst.vs
parentHandle rendering of RailVehicles through RailVehicleClass instancing (diff)
downloadilt-e751ab465bbbf1365ec6e108c64dafd03ce42f1d.tar.bz2
ilt-e751ab465bbbf1365ec6e108c64dafd03ce42f1d.tar.xz
ilt-e751ab465bbbf1365ec6e108c64dafd03ce42f1d.zip
Pop and complete instanced shadow support
Diffstat (limited to 'gfx/gl/shaders/shadowDynamicPointInst.vs')
-rw-r--r--gfx/gl/shaders/shadowDynamicPointInst.vs13
1 files changed, 13 insertions, 0 deletions
diff --git a/gfx/gl/shaders/shadowDynamicPointInst.vs b/gfx/gl/shaders/shadowDynamicPointInst.vs
new file mode 100644
index 0000000..eb7313a
--- /dev/null
+++ b/gfx/gl/shaders/shadowDynamicPointInst.vs
@@ -0,0 +1,13 @@
+#version 330 core
+
+include(`meshIn.glsl')
+layout(location = 5) in mat4 model;
+
+uniform mat4 viewProjection;
+
+void
+main()
+{
+ gl_Position = viewProjection * model * vec4(position, 1.0);
+ gl_Position.z = max(gl_Position.z, -1);
+}