Jump to content

  • Log In with Google      Sign In   
  • Create Account

Awesome job so far everyone! Please give us your feedback on how our article efforts are going. We still need more finished articles for our May contest theme: Remake the Classics

he3117

Member Since 29 Nov 2011
Offline Last Active Today, 03:44 PM
-----

#5007549 Bug in my shadow map

Posted by he3117 on 05 December 2012 - 04:31 PM

Sounds like you're not clearing (setting all values to a clip-far value) your shadow map before rendering.


Finally I found it.:lol: The problem was Zbuffer.It couldn't clear the Zbuffer.
From MSDN:
IDirect3DDevice9::Clear will fail if you:
1-Try to clear either the depth buffer or the stencil buffer of a render target that does not have an attached depth buffer.
2-Try to clear the stencil buffer when the depth buffer does not contain stencil data.

Mine was case 2.


PARTNERS