Caching Particles

The ParticleCache node allows you to store the geometry simulation for a particle system to file. It can then be read back in different sessions of Nuke or on different machines without the need for recalculation.

This allows a particle system to be produced by an artist and then used by a render farm without recalculation, speeding up render times.

Note:  The ParticleCache node doesn't replace the particle system. It just stores the simulation to disk and still relies on the particle system being connected in the same way with the same inputs. If anything in the particle system changes, the ParticleCache node detects this and shows an error to alert you to changes that have potentially been made upstream without your knowledge.

To cache your particle simulation:

1.   Once you are happy with your particle simulation, select Particles > ParticleCache to create a ParticleCache node.
2.   Place the ParticleCache node at the bottom of a single particle system or multiple merged particle systems.

Note:  You cannot place a ParticleCache node in the middle of a string of particle nodes or beneath a Scene node connected to two separate particle streams.

3.   In the ParticleCache properties, click the folder icon next to the file field and navigate to the directory where you want to cache the particle simulation. After the directory path, enter a name for the cache files and include the frame number variable (for example, ####) in the name. Click Open.

ParticleCache uses the .nkpc file extension.

Note:  ParticleCache may need to render up to 100 sub-frames. To account for this, it adds decimals to the file name's frame number. For example, if the file name in the file field is particle_cache.####.nkpc, ParticleCache may generate files called particle_cache.0001.01.nkpc, particle_cache.0001.02.nkpc, and so on.

4.   If you have nodes downstream that generate motion blur, the particle system may need to request frames outside the normal frame range. If this is the case, increase the padding value in the ParticleCache properties to set the number of extra frames added to the start and end of the ParticleCache render.
5.   Click Render.

ParticleCache renders your particle simulation out to file frame by frame.

6.   To use the cache data, enable read from file.

If you get a "Particle cache data not found" error, return to step 4 and increase the padding value.