Sign in to follow this  

How to interactively modify shadow mapping in RenderMonkey?

Recommended Posts

Hi, I'm trying to make a simple prototype shadow mapping in RenderMonkey, that is simple enough for me to understand (all samples I have found on the net make blurred, tricky shadow maps, and for the first step, I wanted one that is the simplest possible variant). - I can post the shaders if someone is interested. Now here is my problem: I have two passes. The first one renders the shadow map using the World-View-Projection matrix of the light being the camera. I can fill in this matrix by hand, or I can use a camera, and using a predefined matrix, I can get the values automatically. Then, in the second pass, I need two WVP matrices: one for my real camera, and one for the "light-camera". If I use a predefined WVP matrix, then it will give the values of my real camera, so I don't have the light WVP. If I reference the light-camera, then my predefined matrix will have the light WVP, but then, I don;t have the camera WVP. I cannot reference a matrix in another pass, and I cannot even copy the values of a predefined matrix into a non-oredefined one, just by hand, one by one. This is what I am forced to do now, but I'm wondrring if there is an easier solution. Thanks for your help, Peter

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this