Original Post
Hi... I have created particle system, which works pretty fine. But I have problem with shadows. I use PSSM (or CSM) and I thought, that with alfa blending i will have in shadow map alfa blended particle. Instead of that, i got in shadow map whole triangle (my partices are made from triangles)
And second problem. If I am too close to particles (in my opinion, if i render first shadowed cascade), I see (instead of sky from skybox or scene) color from device.Clear(ClearFlags.Target | ClearFlags.ZBuffer, System.Drawing.Color.Blue, 1, 0); This is caused by skybox, because skydome is out of view distance. SkyDome is transformed by world matrix Matrix worldMatrix = Matrix.Translation(0, -0.2f, 0) * Matrix.Scaling(100, 100, 100) * Matrix.Translation(this.camera.Position); If I change Scaling I cannot see device background color, but than i can see no terrain :(
So how should I render it all-together (particles, skydome and shadows) ? I render scene this way. ShadowMap { Scene Particles } Shadow - using shadow map { SkyDome Particles Scene } Water reflection - using shadowed scene (i have shadows in my reflection) { SkyDome Particles Scene } Apply Water texture
And second problem. If I am too close to particles (in my opinion, if i render first shadowed cascade), I see (instead of sky from skybox or scene) color from device.Clear(ClearFlags.Target | ClearFlags.ZBuffer, System.Drawing.Color.Blue, 1, 0); This is caused by skybox, because skydome is out of view distance. SkyDome is transformed by world matrix Matrix worldMatrix = Matrix.Translation(0, -0.2f, 0) * Matrix.Scaling(100, 100, 100) * Matrix.Translation(this.camera.Position); If I change Scaling I cannot see device background color, but than i can see no terrain :(
So how should I render it all-together (particles, skydome and shadows) ? I render scene this way. ShadowMap { Scene Particles } Shadow - using shadow map { SkyDome Particles Scene } Water reflection - using shadowed scene (i have shadows in my reflection) { SkyDome Particles Scene } Apply Water texture


