GPU particles wrong collision in tiled enviroment

I know about collision limitations of GPU particles (like they collide only what is rendered), it is not one of those cases. I am heavily using tiled assets, so collision on my map is bunch of boxes that make bigger flat surfaces. Most of GPU particles behave well, but some (like 1% or so) not. When I shoot them above FLAT floor made out of tiles some of them collide with vertical edges of tiled floor, but they are well above floor, and those vertical collision edges are embedded inside floor anyway. When i remove floor tiles everything goes smooth. Also when i removed collision on floor tiles (removed actual mesh collision in its mini editor) I got same errors but in much less cases, (ie above collision less floor, but still made out of colission less tiles).

Hi Nawrot -

Can you provide some screenshots and/or a video of what you are describing?

But to clarify any possible confusion, unless you are using Distance Field Collision, all GPU particles use Scene Depth for collision. They do not in fact read any information from the collision aspect of a mesh. They pull information directly and only from the Scene Depth Buffer and use that to determine if they can calculate collision.

This is why GPU particles will collide with the top of a box until your camera gets to a point where it is below the box top and that top is no longer rendered.

Thank You

Eric Ketchum

Ahh good to know that they do not read actual collision, they just check scene depth. That may be cause of this weird behavior, but to clarify i made 2 movies,one with tiled floor where error is apparent, and second with BSP floor where they behave correctly (they kind of trace all floor tiles).

correct behavior:

bad bad particles:

In both cases i shoot those particles 90 units above floor level, they should collide only at maximum range, there is not that much randomness added to their speed, so they should touch ground next to wall, not right after spawning.

Hey Nawrot -

In the same setup you have for your movies, can you post screenshots of your scene depth buffer?

Also take a look at this sample project I have attached below. Are you able to make adjustments to it to reproduce the issue you are seeing?

Finally what is your Collision Radius Scale and Bias set to in your Particle setup, by default they are 1 and 0 respectively?

Test Project 4.10.2

Thank You

Eric Ketchum

Hi, I sent you PM on forums with link to download whole project. Scene depth buffer looks flat to me, no visible edges on floor.

Hi Nawrot -

What you are experiencing is a result of per-pixel normal calculations used in Scene Depth Collision. So, in fact, it is not the seams of your tileable meshes that are causing the collision but the offset generated by the normal calculation on the pixel level. These calculations occur on Static Meshes and are calculated slightly differently for BSP which is why you are seeing a difference between the two.

There are a few things you can do to help, one of course is to completely remove Normals. Of course you will probably not want to do that but you can adjust the intensity of your normal downward which can help some. You can also decrease the radius Scale in your Collision Module. Doing both of those together and meeting somewhere in the middle can yield better results.

Depending on your intended development platform, you can also switch to using Mesh Distance Fields for Collision on GPU particles which will completely eliminate the calculation that is causing this issue, but will restrict the development to SM5 capable devices (not mobile or OSX).

Thank You -

Eric Ketchum

Ah thanks, so in short i should read more GPU particle documentation.
I set half of those properties in emmiter by fiddling with them, and as result i probably have wrong idea about what they are for or how they work.

This is actually a gotcha moment with GPU particles so it is easily missed in the documentation.

Eric