Why is "2d" (sprites, particles) so much slower than 3d (point cloud)?

Hi everyone,

Recently I have been playing with (large numbers of) particles. I noticed that FPS drop quickly for relaitvely, well, not too high numbers. :open_mouth:

Here are some observations. The numbers (particle/sprite count) are derived from visual inspection, when FPS consistently stayed below 60 but above 50. All playgrounds just display stuff (no updates, fancy effects or anything).

I do not get these numbers. The 3d point cloud is up to an order of magnitude faster? Even GPU particles lose big times?

I do realise that the numbers are strongly dependent on hardware. But I would expect the relations remain roughly the same. So that the conclusion is 2d is considerably slower than 3d? Is this expected?

If that is an accurate conclusion, then if I can replicate a ParticleSystem effect with a PointCloud, then always use PointCloud? Similarly, if I can replicate a ParticleSystem effect with Sprites but not with a PointCloud, then always use Sprites?

Best wishes
Joe

1 Like

Particle system render instanced quads with screen alignment done in the vertex shader.
Pointcloud is (just) a position in space and GPU takes care of the rest.

The amount of data needed in 1 case Vs the other is important.

This makes a substancial performance difference at the end. I’m pretty sure there are other differences on the CPU side but I don’t know how they impact framerate.

Shaders seems similar between Particle system and sprites and only 1 drawcall in both case. Difference must reside in CPU code.

What drives adoption of 1 system over the other is features. Point cloud has limitation on the size of the quad size in pixels and it’s not dynamic!

2 Likes

Particle (unless using GPU particles) are entirely animated CPU side too. Point clouds are not animated. Just a buffer being rendered.

2 Likes

Ah that is it. Thanks guys! :smiley: My test setup was too minmal :upside_down_face:

The moment I add an update function to the PointCloud, the frame rate implodes. But adding a ShaderMaterial and doing the same updates in the VertexShader did not impact FPS. Interesting stuff!

2 Likes