PDA

View Full Version : help with shadows



ricfow
08-17-2004, 04:23 AM
Hi,
i'm trying to implement the shadows volume approach in my application. Lesson 27 of
nehe was my base code. In my scenes i have
a ground, buildings (objects) and a light (sun).
The problem is that the shadows are not
appearing correctly. Look to this image to
make clear my problem.
http://www.dt.fee.unicamp.br/~ricfow/problem.jpg
The green part is the background and that shadow should not appear there.

helps will be very welcome,
thanks,
ricfow

dorbie
08-17-2004, 08:51 AM
You need to cap the shadow volume, and make sure it isn't clipped at the far plane. Just extrude enough to reach past the building.

ricfow
08-18-2004, 05:17 AM
Me again,
I tried to make shorters extrusions,
see this sequence:
http://www.dt.fee.unicamp.br/~ricfow/screen1.jpg
http://www.dt.fee.unicamp.br/~ricfow/screen2.jpg
http://www.dt.fee.unicamp.br/~ricfow/screen3.jpg
but (like the pictures show) the problem
continues,
shouldn't the shadows only appear over the ground (base circle)?
maybe the nehe lesson 27 code only works fine
if the scene is indoor.

thanks,
[],
ricfow