Skip to main content
gamedev.net
🔒 Locked

SDK Shadow example and light vector

Started by axelfr74 Jul 5, 2004 at 11:53 AM 4 replies 550+ views
Original Post
axelfr74
axelfr74
Hi, I'm playing with parts of the SDK shadow example in my own app. So far it works. But it seems the light vector is always pointing into the negative Y axes. I that right? How can I change the vector of the light which creates the shadow volume? I can change the light position with no problem..but need to change the light direction vector too. The light needs to point into the Z axes..but I have no idea what to change. Thanks for any help! Axel
axelfr74
axelfr74
*bump* :-)

Is there no way? It would be really helpfull. But I have no idea what to change. There has to be somewhere the vector of the light direction. Maybe in the BuildFromMesh funtion?

Axel
Pipo DeClown
Pipo DeClown
The lightposition is used to calculate the lightdirection, so the light always points to the center of the sphere. You can code a work-around, where you calculate the direction yourself. (So you have to change the asm-shader.. yuck!)
Pipo DeClown
Pipo DeClown
Yeah, it always points to 0,0,0. (At least, that's what I see from the demo)
axelfr74
axelfr74
Aha..thanks. Thats very useless if it is so. :-( Changing the ASM shader..a little bit to much for me.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.