Register  |  FAQ  |  Search  |  Memberlist  |  Usergroups  |  Log in 
Reply to topic
 Dynamic Shadow - source material 
Site Admin

Joined: 25 Dec 2006
Posts: 98
Reply with quote

Source Shadow Material control how to produce the shadow map.
e.g. Use alpha test technic to produce a variegated map to simulate leaves's shadow.

The flow to produce shadow map:

1. Set matrices for rendering (world,view, proj)

2. Clear shadow map with black color

3. Set ColorArg2[0]to TFactor, set ColorOp[0] to SelectArg2

4. Reverse shadow color (ambient color of environment), and attenuate the color value by distance to Light ,then set to TextureFactor

5. if found shadow source material, reset TextureFactor to Light's color (attenuating but no reverse); change ColorOp[0] to Modulate

6. Activate the source shadow material and draw the mobile
View user's profile Send private message Send e-mail
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT  
Page 1 of 1  

 Reply to topic