# jME3 Special Effects Overview

jME3 supports several types of special effects: Post-Processor Filters, SceneProcessors, and Particle Emitters (also known as particle systems). This list contains screenshots and links to sample code that demonstrates how to add the effect to a scene.

## Sample Code

- There is one `com.jme3.effect.ParticleEmitter` class for all Particle Systems.
- There is one `com.jme3.post.FilterPostProcessor` class and several `com.jme3.post.filters.*` classes (all Filters have `*Filter` in their names).
- There are several `SceneProcessor` classes in various packages, including e.g. `com.jme3.shadow.*` and `com.jme3.water.*` (SceneProcessor have `*Processor` or `*Renderer` in their names).

### Particle Emitter

    public class MyGame extends SimpleApplication {
      public void simpleInitApp() {
        ParticleEmitter pm = new ParticleEmitter("my particle effect", Type.Triangle, 60);
        Material pmMat = new Material(assetManager, "Common/MatDefs/Misc/Particle.j3md");
        pmMat.setTexture("Texture", assetManager.loadTexture("Effects/spark.png"));
        pm.setMaterial(pmMat);
        pm.setImagesX(1);
        pm.setImagesY(1);
        rootNode.attachChild(pm); // attach one or more emitters to any node
      }
    }

### Scene Processor

    public class MyGame extends SimpleApplication {
        private BasicShadowRenderer bsr;

        public void simpleInitApp() {
            bsr = new BasicShadowRenderer(assetManager, 1024);
            bsr.setDirection(new Vector3f(.3f, -0.5f, -0.5f));
            viewPort.addProcessor(bsr); // add one or more sceneprocessor to viewport
        }

### Post-Processor Filter

    public class MyGame extends SimpleApplication {
        private FilterPostProcessor fpp; // one FilterPostProcessor per app
        private SomeFilter sf;           // one or more Filters per app

        public void simpleInitApp() {
            fpp = new FilterPostProcessor(assetManager);
            viewPort.addProcessor(fpp); // add one FilterPostProcessor to viewPort

            sf = new SomeFilter();
            fpp.addFilter(sf);  // add one or more Filters to FilterPostProcessor
        }

## Water

The jMonkeyEngine's "SeaMonkey" WaterFilter simulates ocean waves, foam, including cool underwater caustics. Use the SimpleWaterProcessor (SceneProcessor) for small, limited bodies of water, such as puddles, drinking troughs, pools, fountains.

See also the
announcement with video.

- ??? SimpleWaterProcessor (SceneProcessor)
- ??? SimpleWaterProcessor (SceneProcessor)

- ??? WaterFilter
- ??? WaterFilter

## Environment Effects

### Depth of Field Blur

- ??? DepthOfFieldFilter

### Fog

- ??? FogFilter

### Light Scattering

- ??? LightScatteringFilter

### Vegetation

- Contribution: Grass System
- Contribution:

## Light and Shadows

### Bloom and Glow

- More details: Bloom and Glow ??? BloomFilter

### Light

- ??? DirectionalLight, PointLight
- ??? DirectionalLight, PointLight
- ??? .j3o scene
- More details: Light and Shadow

### Shadow

- ??? BasicShadowRenderer (SceneProcessor)
- ??? PssmShadowRenderer (SceneProcessor), also known as Parallel-Split Shadow Mapping (PSSM).
- ,
  ??? SSAOFilter, also known as Screen-Space Ambient Occlusion shadows (SSOA).
- ??? SSAOFilter, also known as Screen-Space Ambient Occlusion shadows (SSOA), plus transparancy
- More details: Light and Shadow

## Special: Glass, Metal, Dissolve, Toon

### Toon Effect

- ??? CartoonEdgeFilter
- ??? CartoonEdgeFilter

### Fade in / Fade out

- Fade ??? FadeFilter

### User Contributed

ShaderBlow - GLSL Shader Library

- LightBlow Shader ??? blend material texture maps
- FakeParticleBlow Shader ??? jet, fire effect
- ToonBlow Shader ??? Toon Shading, toon edges
- Dissolve Shader ??? Scifi teleportation/dissolve effect
- MatCap Shader ??? Gold, metals, glass, toons???!
- Glass Shader ??? Glass
- Force Shield Shader ??? Scifi impact-on-force-field effect
- SimpleSprite Shader ??? Animated textures
- SimpleSpriteParticle Shader ??? Sprite library
- MovingTexture Shader ??? Animated cloud/mist texture
- SoftParticles Shader ??? Fire, clouds, smoke etc
- Displace Shader ??? Deformation effect: Ripple, wave, pulse, swell!

Thanks for your awesome contributions! Keep them coming!

## Particle Emitters: Explosions, Fire, Smoke

Particle emitter effects are highly configurable and can have any texture. They can simulate smoke, dust, leaves, meteors, snowflakes, mosquitos, fire, explosions, clusters, embers, sparks???

- ??? debris, flame, flash, shockwave, smoke, sparks
- ??? cluster of points
- ??? dust, smoke

See also:

- Particle Emitters
- Bloom and Glow

documentation, effect, light, water

view online version