iterationSwitch

iterationSwitch

Switches between inputs based on the iteration value provided by a downstream operator.

Only connected inputs are considered, and they are renumbered to skip over any missing ones. So if only 2 and 4 are connected, they are treated as 1 and 2.

Iteration values are rounded to the nearest integer (after the Extend mode is applied to handle values outside the expected range from 0 to the number of connected inputs minus 1.

Parameters

Name Description Regular Handling Read-Only Handling
Enable
Iteration Part

Which component of the iteration vector to use. In most cases this should be X.

Semi-Baked Semi-Baked
  • X:
  • Y:
  • Z:
  • W:
Extend

How to handle iteration values outside the 0..(N-1) range.

Semi-Baked Semi-Baked
  • Clamp: Clamp iteration to 0..(N-1) range.
  • Loop: Loop from 0 to N-1.
  • Zig-Zag: Zig-zag back and forth between 0 and N-1.

Inputs

  • Input 1: (optional)
    • Coordinate Types: float vec2 vec3 vec4
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • Input 2: (optional)
    • Coordinate Types: float vec2 vec3 vec4
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • Input 3: (optional)
    • Coordinate Types: float vec2 vec3 vec4
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • Input 4: (optional)
    • Coordinate Types: float vec2 vec3 vec4
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • Input 5: (optional)
    • Coordinate Types: float vec2 vec3 vec4
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • Input 6: (optional)
    • Coordinate Types: float vec2 vec3 vec4
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • Input 7: (optional)
    • Coordinate Types: float vec2 vec3 vec4
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • Input 8: (optional)
    • Coordinate Types: float vec2 vec3 vec4
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle