Shadows Problem

Hi guys, I’m Brigaele and I apologize for my English…
I just joined to jMonkey forum and I don’t know how it work.
As you read in title: i have some problem with the shadows…
there a video link of my problem.

And I want obtain some in the dynamic shadows result like in Phong Light:

I hope that someone can help me … I’m desperate. XD

If you are referring to the artifacting in the self-shadowing, the only way to minimize this is to increase the size of your shadow map or use the post-process versions of the shadow renderers (which should apply some form of convolution or blurring to help minimize the effect) or both.

EDIT: Though, keep in mind that this is noticeable in most games. Skyrim is a great example… awesome graphics… terrible shadows… but the end result is still great.

Hi, thanks for reply. :slight_smile: Yes I’m referring to the artifacting… But I have just post-processing version…
Here the code:
[java]
viewPort.setBackgroundColor(new ColorRGBA(0.7f, 0.8f, 1f, 1f));

DirectionalLight sun = new DirectionalLight();
Vector3f lightDir = new Vector3f(-0.12f, -0.3729129f, 0.74847335f);
sun.setDirection(lightDir);
sun.setColor(new ColorRGBA(1.0f, 0.9f, 0.8f, 1.0f).multLocal(2.8f));
rootNode.addLight(sun);

DirectionalLightShadowFilter dlsf = new DirectionalLightShadowFilter(assetManager, SHADOWMAP_SIZE, 4);
dlsf.setLight(sun);
dlsf.setLambda(0.35f);
dlsf.setShadowIntensity(0.55f);
dlsf.setShadowZExtend(500);
dlsf.setShadowCompareMode(CompareMode.Hardware);
dlsf.setEdgeFilteringMode(EdgeFilteringMode.Nearest);
dlsf.setEnabled(true);

FilterPostProcessor fpp = new FilterPostProcessor(assetManager);

Vector3f lightPos = lightDir.multLocal(-3000);

LightScatteringFilter filter = new LightScatteringFilter(lightPos);
LightScatteringUI ui = new LightScatteringUI(inputManager, filter);

fpp.addFilter(filter);
fpp.addFilter(dlsf);

viewPort.addProcessor(fpp);
[/java]

SHADOWMAP_SIZE = 4056;
Did I had everything I could to improve the self-shading?

EDIT: eheheh, yes. :slight_smile: