summaryrefslogtreecommitdiff
path: root/gfx/gl/shaders/shadowLandmass.vs
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2024-04-16 00:23:43 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2024-04-16 00:23:43 +0100
commit741bb027df58fd9f30f4d94cdaf2d6416e11e3ee (patch)
tree67a91f8c4f5394df90bf7ce149229bb85389749f /gfx/gl/shaders/shadowLandmass.vs
parentCreate terrain vertices per surface type (diff)
downloadilt-741bb027df58fd9f30f4d94cdaf2d6416e11e3ee.tar.bz2
ilt-741bb027df58fd9f30f4d94cdaf2d6416e11e3ee.tar.xz
ilt-741bb027df58fd9f30f4d94cdaf2d6416e11e3ee.zip
Custom vertex, vertex shader and fragment shader for landmass
Handles global position type, colourBias for surface types
Diffstat (limited to 'gfx/gl/shaders/shadowLandmass.vs')
-rw-r--r--gfx/gl/shaders/shadowLandmass.vs13
1 files changed, 13 insertions, 0 deletions
diff --git a/gfx/gl/shaders/shadowLandmass.vs b/gfx/gl/shaders/shadowLandmass.vs
new file mode 100644
index 0000000..becf142
--- /dev/null
+++ b/gfx/gl/shaders/shadowLandmass.vs
@@ -0,0 +1,13 @@
+#version 330 core
+
+layout(location = 0) in ivec3 position;
+
+uniform ivec3 viewPoint;
+
+out vec4 vworldPos;
+
+void
+main()
+{
+ vworldPos = vec4(position - viewPoint, 1);
+}