Jump to content

  • Log In with Google      Sign In   
  • Create Account

Shadow artifacts on plane parallel to light


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
3 replies to this topic

#1 nikitablack   Members   -  Reputation: 612

Like
0Likes
Like

Posted 31 March 2014 - 09:28 AM

Hello. I'm using directional light. And on parallel to light direction plane I have flickering artifacts (in the picture the side of cube is shaded and actually it blinks every frame, so if I move camera a little - different faces shaded differently). I don't want to use any other lightning (lambertian etc) - only pure color + shadows. And to be honest, I can't understand why there're such artifacts. And is there any way to remove shadow aliasing on sphere? I'm working with mobile so I can't afford myself bluring or even pcf.



Sponsor:

#2 kalle_h   Members   -  Reputation: 1568

Like
0Likes
Like

Posted 31 March 2014 - 01:53 PM

Use binary light model so all bakcfaces get full shadow always. color = dot(n, l) > 0 ? color * shadow : 0;



#3 L. Spiro   Crossbones+   -  Reputation: 14272

Like
0Likes
Like

Posted 31 March 2014 - 05:13 PM

And is there any way to remove shadow aliasing on sphere?

You may need to provide an image of what is happening but you should be adding a small offset to the shadow-map test so that the shadow is slightly further back than it actually is.


L. Spiro
It is amazing how often people try to be unique, and yet they are always trying to make others be like them. - L. Spiro 2011
I spent most of my life learning the courage it takes to go out and get what I want. Now that I have it, I am not sure exactly what it is that I want. - L. Spiro 2013
I went to my local Subway once to find some guy yelling at the staff. When someone finally came to take my order and asked, “May I help you?”, I replied, “Yeah, I’ll have one asshole to go.”
L. Spiro Engine: http://lspiroengine.com
L. Spiro Engine Forums: http://lspiroengine.com/forums

#4 nikitablack   Members   -  Reputation: 612

Like
0Likes
Like

Posted 01 April 2014 - 01:32 AM

Oh, sorry, I forgot to attach a picture.

https://dl.dropboxusercontent.com/u/77219109/shadows.png

 

This aliasing on the sphere... I tried different bias values but it still there.

 

@kalle_h, thank you, good approach.


Edited by Volgogradetzzz, 01 April 2014 - 01:32 AM.





Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS