summaryrefslogtreecommitdiff
path: root/gfx/gl/shaders/shadowDynamicPointStencil.gs
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2024-09-02 21:00:41 +0100
committerDan Goodliffe <dan@randomdan.homeip.net>2024-09-02 21:00:41 +0100
commit052b2b49d9bfdaaa7f7c5603fa7c47b881df93c2 (patch)
treee1ee5476434ae0855a4970c10e7e8fc88744b30b /gfx/gl/shaders/shadowDynamicPointStencil.gs
parentUpdate Texture::getSize and ::size to account for the third texture dimension (diff)
downloadilt-052b2b49d9bfdaaa7f7c5603fa7c47b881df93c2.tar.bz2
ilt-052b2b49d9bfdaaa7f7c5603fa7c47b881df93c2.tar.xz
ilt-052b2b49d9bfdaaa7f7c5603fa7c47b881df93c2.zip
Update stencil texture to 2d array
Diffstat (limited to 'gfx/gl/shaders/shadowDynamicPointStencil.gs')
-rw-r--r--gfx/gl/shaders/shadowDynamicPointStencil.gs4
1 files changed, 2 insertions, 2 deletions
diff --git a/gfx/gl/shaders/shadowDynamicPointStencil.gs b/gfx/gl/shaders/shadowDynamicPointStencil.gs
index 2873691..b91937d 100644
--- a/gfx/gl/shaders/shadowDynamicPointStencil.gs
+++ b/gfx/gl/shaders/shadowDynamicPointStencil.gs
@@ -11,7 +11,7 @@ uniform float size;
in ivec3 vworldPos[];
flat out vec3 scale;
-out vec2 texCoord;
+out vec3 texCoord;
layout(points) in;
layout(triangle_strip, max_vertices = 16) out;
@@ -25,7 +25,7 @@ main()
for (int c = 0; c < corners.length(); ++c) {
gl_Position = pos + vec4(scale.xy * corners[c], 0, 0);
gl_Position.z = max(gl_Position.z, -1);
- texCoord = (corners[c] * 0.5) + 0.5;
+ texCoord = vec3((corners[c] * 0.5) + 0.5, 0);
EmitVertex();
}
EndPrimitive();