From 6eca52e4f2ba24621fe4f3c8eabe2c6ad4a1cbb0 Mon Sep 17 00:00:00 2001 From: dev Date: Fri, 30 Jan 2015 17:01:46 -0800 Subject: [PATCH] point light is working with Mac --- libraries/render-utils/src/Light.slh | 32 ++++++++++++---------------- 1 file changed, 14 insertions(+), 18 deletions(-) diff --git a/libraries/render-utils/src/Light.slh b/libraries/render-utils/src/Light.slh index 97fa415a0c..169699b89a 100755 --- a/libraries/render-utils/src/Light.slh +++ b/libraries/render-utils/src/Light.slh @@ -64,15 +64,13 @@ Light getLight() { uniform vec4 lightBuffer[9]; Light getLight() { Light light; - light._transform[0] = lightBuffer[0]; - light._transform[1] = lightBuffer[1]; - light._transform[2] = lightBuffer[2]; - light._transform[3] = lightBuffer[3]; - light._color = lightBuffer[4]; - light._range = lightBuffer[5]; - light._spot = lightBuffer[6]; - light._shadow = lightBuffer[7]; - light._control = lightBuffer[8]; + light._position = lightBuffer[0]; + light._direction = lightBuffer[1]; + light._color = lightBuffer[2]; + light._attenuation = lightBuffer[3]; + light._spot = lightBuffer[4]; + light._shadow = lightBuffer[5]; + light._control = lightBuffer[6]; return light; } @@ -80,15 +78,13 @@ Light getLight() { uniform vec4 lightBuffer[9]; Light getLight() { Light light; - light._transform[0] = lightBuffer[0]; - light._transform[1] = lightBuffer[1]; - light._transform[2] = lightBuffer[2]; - light._transform[3] = lightBuffer[3]; - light._color = lightBuffer[4]; - light._range = lightBuffer[5]; - light._spot = lightBuffer[6]; - light._shadow = lightBuffer[7]; - light._control = lightBuffer[8]; + light._position = lightBuffer[0]; + light._direction = lightBuffer[1]; + light._color = lightBuffer[2]; + light._attenuation = lightBuffer[3]; + light._spot = lightBuffer[4]; + light._shadow = lightBuffer[5]; + light._control = lightBuffer[6]; return light; }