Switch SOP

From TouchDesigner 088 Wiki

05 SwitchSOP.jpg

Summary

The Switch SOP switches between up to 9999 possible inputs. The output of this SOP is specified by the Select Input field. This is useful for switching the output between several inputs depending on the evaluation of an expression placed in the Select Input field.

PythonIcon.png switchSOP_Class

Parameters

Select Input /input - The index of the source to use, where the first source is 0, the second 1, and so on.

Inputs

Multiple SOP inputs - Several SOPs are connected to the input.

Example

Below are two expressions that could be entered in the Select Input field:

  • $F-1 - The first input is selected at frame 1, the second at frame 2, etc.
  • $F > 5 - The first input is selected for the first five frames, then the second for the remaining frames.