From 972d7260affe7f0d8eebaef609f5576a18f66f73 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Fri, 12 Jan 2024 19:21:37 +0000 Subject: Fix order or multiple to address reversed rotation --- gfx/gl/shaders/spotLight.vs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gfx/gl/shaders') diff --git a/gfx/gl/shaders/spotLight.vs b/gfx/gl/shaders/spotLight.vs index 8023f18..eed8778 100644 --- a/gfx/gl/shaders/spotLight.vs +++ b/gfx/gl/shaders/spotLight.vs @@ -20,8 +20,8 @@ flat out float kq; void main() { - position = modelPos + ivec3(v_position * mat3(model)); - direction = normalize(v_direction * mat3(model)); + position = modelPos + ivec3(mat3(model) * v_position); + direction = normalize(mat3(model) * v_direction); colour = v_colour; kq = v_kq; size = (8000 * sqrt(max(max(colour.r, colour.g), colour.b))) / sqrt(kq); -- cgit v1.2.3