mathias_123

01-20-2002, 03:48 AM

Hi,

I've just bought the OpenGL-Superbible, perhaps someone has it, too, so he might understand better my problem.

In this book is an example how to make shadows. It works by calculating a matrix based on three points that define a plane on which the shadow will fall, and a vector that includes the vertices of the lightsource.

With the resulting matrix the current matrix is multiplied, and then the objects can be drawn flat and in black, as if they were shadows.

The problem is, that the projection of the shadows is on the whole plane, defined by the three points. But I want the shadows only to be drawn on the polygon, that defines the ground.

I hope someone could understand me,

bye

mace

I've just bought the OpenGL-Superbible, perhaps someone has it, too, so he might understand better my problem.

In this book is an example how to make shadows. It works by calculating a matrix based on three points that define a plane on which the shadow will fall, and a vector that includes the vertices of the lightsource.

With the resulting matrix the current matrix is multiplied, and then the objects can be drawn flat and in black, as if they were shadows.

The problem is, that the projection of the shadows is on the whole plane, defined by the three points. But I want the shadows only to be drawn on the polygon, that defines the ground.

I hope someone could understand me,

bye

mace