rotating a light

dan_e6

26-06-2008 06:54:06

when i create a new light how do i rotate the light itself? there's a light.setdirection and light.direction and light.node.direction stuff but i dont know what to do

jariah

28-06-2008 16:38:39

mlight.SetPosition(x, y, z);//position of the light
mlight.SetDirection(lookatX, lookatY, lookatZ);//position where the light is looking

Hope that helps alittle

Marioko

28-06-2008 17:46:18

i think you can attach the light object to a SceneNode., then only rotate de SceneNode. Mmm this also can be usefull for object that emit lights and are in motion or changing prositions,¿ a moving torch maybe??