Visual Effects: Lesson 08: Using Depth Buffer Collisions with GPU Particles - Epic Wiki
# Visual Effects: Lesson 08: Using Depth Buffer Collisions with GPU Particles
# Depth Buffer Module Setup and controls
GPU Particles support Depth Buffer Collision, using the Collision (Scene Depth) Module in Cascade.
Let’s add a Depth Buffer module to any translucent particle system you may have available from the previous lessons. I am using a spark emitter I have around from another project.
Depth buffer collision is only supported for translucent materials, masked and opaque materials contribute to the buffer and cannot collide with it.
The module is fairly straight forward, and each option has well written descriptions of what the feature does.
Resillience – controls how bouncy the particle is. This can be mapped to a uniform distribution for variation.
You can see the difference in response between these two images. Note the difference in the Max field changes from 1, which is very bouncy, to .1 which nearly sticks to the surface.
Friction – Controls how much particles will grip or slide when colliding with a surface.
In the first image you can see the particles have a tendency to clump up near the point of contact with the surface which is tilted at ~30 degree angle. In the second image the lower friction allows the particles to maintain more of their original velocity and slide more easily.
Radius Scale - offsets your particles from the surface with which they are colliding. This is a good way to offset larger sprites if, for example, you are unhappy with surface interpenetration.
It is important to keep in mind that the collision of a particle is based on its radius, or rather its size, so changes to Size and Radius Scale can both affect the offset between a particle and surface. In the following examples, you can see how increasing size also increases the offset, making the particles further from the surface despite having the same Radius Scale.
Size 2.0 Radius Scale 10
Size 30 Radius Scale 10
All Translucent GPU particles with the Depth Buffer Module applied will show this type of behavior when colliding with Opaque or Masked materials.
If you want to see the surfaces Particles will collide against, and how the surface normal impacts evaluation use the Buffer Visualization tool
Retrieved from "https://wiki.unrealengine.com/index.php?title=Visual_Effects:_Lesson_08:_Using_Depth_Buffer_Collisions_with_GPU_Particles&oldid=11790"