I am attempting to create a shadow effect on my scene. I want to draw the entire scene. Save the RGBA values to an array. And save the Depth values to another array. I would then clear the buffers. And draw the scene (without textures, colors etc) from the point of view of the lights in the room and save THERE depth buffer to another array.
Then by compairing the different depth array values, i would darken certain pixels of the RBGA array. To create Shadow effects.
My question is this. What all would i need to do to draw JUST that image to the screen with glDrawPixels? Would I have to clear the buffers again? Or does glDrawPixels simply overwrite what is already in the buffer??