Jump to content
  • Advertisement
Sign in to follow this  

Cascaded shadow map cutting

This topic is 927 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Good day everyone! I am following Nvidia's CSM demo code, I got it working great, but I noticed that if I move a bit far away shadow splits start to work "inverted" ( i.e. not applying a split, but removing it ), here's video ( Gyazo ):



I even made code the same as Nvidia's code, but this artifact won't go away. 

My camera setup:

fov= 65.0f

near = 0.1 ( 1.0 for shadow )

far = 3000


I tried to transpose light view matrix, but it results the same problem.

I am generating "LookAt" matrix using the following code:

mLightView = ncMatrix4x4::LookAt( SVec3(0.0f), SVec3(-DirL.x, -DirL.y, -DirL.z ), SVec3(.0f, 1.0f, 0.0f) ) ;//DirL * dist, Lighttarget, Lightup);

"LookAt" method is fine. Could someone tell me what I am doing wrong if someone faced similar problem?


I can upload the whole code here, but it's 99.9% same as Nvidia's code.

Thanks in advance!


EDIT: As I have noticed, shadow disappears only on first lod:


Edited by NekoCode

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!