Skip to main content Link Menu Expand (external link) Document Search Copy Copied
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

  • Enable:
  • Iteration Part: Which component of the iteration vector to use. In most cases this should be X.
    • X:
    • Y:
    • Z:
    • W:
  • Extend: How to handle iteration values outside the 0..(N-1) range.
    • 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

  • definition_in_1: (optional)
    • Coordinate Types: float vec2 vec3
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • definition_in_2: (optional)
    • Coordinate Types: float vec2 vec3
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • definition_in_3: (optional)
    • Coordinate Types: float vec2 vec3
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • definition_in_4: (optional)
    • Coordinate Types: float vec2 vec3
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • definition_in_5: (optional)
    • Coordinate Types: float vec2 vec3
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • definition_in_6: (optional)
    • Coordinate Types: float vec2 vec3
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • definition_in_7: (optional)
    • Coordinate Types: float vec2 vec3
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle
  • definition_in_8: (optional)
    • Coordinate Types: float vec2 vec3
    • Context Types: Context MaterialContext
    • Return Types: float vec4 Sdf Ray Light Particle