   Orthographic Shadows Problem
  Hi There,I am currently implementing exterior shadow mapping for a scene.  I've got it up and running with perspective shadow projection, and want to change this to orthographic (directional - for the sun).My problem is with setting up the ortho projectrion matrix.I have a light class, that computes the projection, view, and texture matrix for the shadow every scene.  The matrices are then used for rendering the depth from the lights view, and the shadow matrix is then passed to the shader for rendering the multitexture shadows.I am getting some nasty results, at the moment, such as white screen.How do I setup and store the projection and modelview matrices, so i can just use it like a perspective shadowmap?   
  The ONLY thing you have to do to change your shadows from using spotlight to directional, is setting up an orthogonal projection matrix for the light camera.I used this:D3DXMatrixOrthoLH(&matProj, 5.0f, 5.0f, 0.0f, DEPTH_RANGE);5.0/5.0 specify the square size of the box (it will be the shadow's area of influence). The two other floats are near and far view.You can look up the function in the MSDN, the full implementation is listed there, if you want to know what it does (or want to implement it yourself).Then you simply replace the old light projection matrix with this one. Nothing else! Don't mess around with making orthogonal view matrices etc. this alone will do the trick, and the code you made for spotlight should work unmodified (except this matrix).   ;  cheers