|
Light problems
Hi.
I have this annoying problem, I have created 2 textured quads to act somewhat like a floor and ceiling, everything works fine until I add lighting then the quads wont show up, I have tried to add other objects to my scene and they turn up just fine so I have no clue what could be the problem.
heres some of my code:
I hope this is just some newbie error and that i can get it out of the way as fast as possible!
thanks in advance
Edited by - Load Runner on December 20, 2001 4:58:50 PM
Romance is dead,it was bougth by Disney and Hallmark and sold to the public in small portions.
I havent messed with lighting a whole lot yet, but when you declare the lights position:
float LightPosition[] = {0.0f, 0.0f, 1.0f, 1.0f};
the fourth parameter tells whether the light is directional or positional. A 0.0f means it is directional (like the sun), and anything else means it is positional, so try declaring the lights direction as well. Try changing the fourth parameter to 0.0f and see if it lights up both the ceiling and the floor.
I''m not sure if it will light them both up, but worth a try.
float LightPosition[] = {0.0f, 0.0f, 1.0f, 1.0f};
the fourth parameter tells whether the light is directional or positional. A 0.0f means it is directional (like the sun), and anything else means it is positional, so try declaring the lights direction as well. Try changing the fourth parameter to 0.0f and see if it lights up both the ceiling and the floor.
I''m not sure if it will light them both up, but worth a try.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement