CSM + Slope based Bias + PCF

Hi everyone !

I’ve recently a implemented cascaded shadow map technique but I have some trouble with it when I enable PCF.

My implementation is really basic:
[ul][li]I set the view frustum so that the far plane is tighten to the scene.[]I compute my split based on a “magic” function []I render shadow maps into an array of depth texture[*]I determine the visibility of each pixel based on the shadow map. [/ul][/li]In order to avoid aliasing I add a small constant bias and a slope based bias. The slope based bias is computed using the technique presented here.

Apparently it works fine, as shown on the screenshot:

Full resolution image available here

When I enable PCF, shadows are OK but I get halos around objects, as shown on the screenshot:

Full resolution image available here

I suspect derivatives used for computing the slope based bias to be wrong. But I’m not sure. Does anyone of you as encounter such a trouble ?

Thank you in advance !

BTW, it’s implemented into a deferred pipeline.

The link to your technique does not work.
Maybe unrelated but even in your first screenshot there are pixels of lights in shadows ?

Sorry about the link : here is the correct link

What do you mean ?
[ul][] Pixels in shadow are not totally black ? It’s because I take in account sky’s irradiance with a SH probe.[] Small sparse pixels with bright intensity in shadow ? I don’t know where they come from =/[/ul]