GPU vs CPU Particles ID

Hello and Happy New Year!

I am running an issue when working with GPU vs CPU.
When I am using attribute reader with Particle ID or Execution Index in CPU it is working as expected.
However, the exact same setup reading attribute By ID or Index is not working as expected when switching to GPU!

I do have the persistent ID check box clicked in the emitter!

Any advise would be great!

2 basic checks first.

  • The source and reader need to have the same sim target, so both gpu in this case.
  • Even if persistent ID’s are turned on, the Particles.ID that generates still needs to be saved. The execution index will not be unique and not be persistent across frames.

Detailing that last point: if that is your issue you’ll want to have a spawn script that selects a source particle through an index, reads the sources Particles.ID and stores it to be used in the update script.


If that isn’t it, we’ll need some more information.
Repro steps.
A description of what goes wrong. (and how it is different from the expected result)
A few screenshots of your setup.

2 Likes