• Maps the minimal set of texture reads to derive the next state of values from a past state of values they depend upon.

    Parameters

    • maps: {
          derives: any;
          passes: array<array<number>>;
          textures: array<array<number>>;
          valueToTexture: array<number>;
      } = {}

      How values are grouped per-texture per-pass per-step. See mapGroups.

      • derives: any

        How the next output state values derive from any past input values. If given no derives, or a falsey-non-integer, no samples are mapped, to is returned unchanged.

      • passes: array<array<number>>

        Textures grouped into passes. See mapGroups.

      • textures: array<array<number>>

        Values grouped into textures. See mapGroups.

      • valueToTexture: array<number>

        Inverse map from each value index to the data texture index containing it.

    • Optionalto: any = maps

      The object to store the result in; maps if not given.

    Returns any

    to The given to object, with resulting maps added for any given maps.derives.

    mapGroups