Creating a Spot Light

Started by
10 comments, last by csuguy 15 years, 5 months ago
Quote:Original post by csuguy
hm... I can't seem to get the glRotatef to work correctly on it, but the glTranslatef works perfectly, I can make it zip all around my scene... wdf...


you have to rotate before and translate after in that order.

glTranslate.....
glRotate........

if its not the confusing order of the stack, i absolutely have no idea,
i use light shaders instead and before i was calculating coords myself instead of using translate n rotate.

Advertisement
No, I've got that in the right order. I actually have all the settings good now and it rotates around, I think I just need to fine tune my rotation algorithm 'cus I can't seem to get it to point straight down.

How do you do light shaders?

This topic is closed to new replies.

Advertisement