You are here: Simulation > Particles and Simulations Overview > Point Clouds > CSV Point Cache

CSV Point Cache

The CSV point cache item allows particle data to be stored and read from an external series of CSV (comma-separated value) files. CSV files are plain text files and can be easily created by scripts or from many spreadsheet or database programs. You can also easily save simulation data from Modo directly into a CSV file for later reuse.

Usage

Add a CSV point cache item to the Items list for either reading or writing cache data by clicking Add Item > Particles > Point Clouds > CSV Point Cache. Once added, select the resulting CSV point cache item to make its attributes visible in the Properties viewport.

To save a new CSV point cache sequence from an existing particle simulation follow these steps.

1.   Create the CSV point cache item and click the New Sequence button.

An OS-specific dialog opens, specifying the file name and location (numerals for a sequence are added automatically).

2.   Click Save to close the dialog.

The actual connection to the point cache and the particle simulation is done next in the Schematic viewport. Use the Add Selected button in the viewport to add the proper node, where its output can be connected to the point cache input of the particle simulation item like this.

CSV Cache

Once connected, each time a simulation is evaluated, the files are written (or overwritten as the case may be. To keep the files form being overwritten, simply disconnect the CSV point cache item from the particle simulation item. Once disconnected, the particles play back normally in the 3D Viewport when the Timeline is played or scrubbed.

To load an existing CSV point cache, do the following:

1.   Create the CSV point cache item and use the Browse button to locate a saved sequence.
2.   In the OS-specific dialog, specify the first file in a series for a sequence. Once the file is selected press Open to load.

When the Timeline is played or scrubbed, the particle sequence plays in the 3D Viewport.

For static points in a still image, specify the particular file in the series (if necessary) and set the Type as Static Points. Once the point cache is loaded, it can be assigned as a point source.

CSV PAnel

Option

Description

Name

Displays the current force item name. To change it, click on the field and type in the new name.

CSV Cache

Filename Pattern

A file path for a single CSV file, or for a sequence of CSV files. If it's a sequence, then the pattern must contain [####], where the number of # characters indicates the number of digits in the frame number.

Browse

Opens an OS-specific dialog allowing you to locate an existing saved CSV file or sequence for playback. Once selected, click the Open button to load the cached data.

New Sequence

Allows you to define a new CSV sequence for saving cached data to. The particle simulation item needs to be connected to the CSV item in the Schematic view prior to running a simulation.

Type

Indicates how the pattern is used:

Static Points: Read the pattern as a single file for all time.

Sequence: Substitute a number into the pattern to find the file for a specific time.

Sequence with Range: Uses the Start and End values to limit the range of the sequence.

 

Start/End

Start is the minimum frame number for a range sequence. End is the maximum frame number for a range sequence.

Offset

Used to offset the sequence relative to the Timeline. If set to 10, the sequence starts to play back at frame 10.

Size

Determines the pixel display size of the particles within the 3D Viewport.

Color

Allows you to define the display color of the particles in the 3D Viewport. This option can be very helpful in differentiating particles from those that are part of a different simulation.

TIP:  Modo normally saves cached simulation data internally to the saved scene file. CSV point cache files are a great way to externalize particle simulation data, keeping Modo scene files small.