Vixen
02b45cc4
csharp
public sealed class MixerParameters

Engine-wide parameters, resolved against a mixer and stepped once a frame.

No guide page documents this yet — the page shows what the code says about itself.

Remarks

What a snapshot is not. MixerSnapshots blends to a named state over a duration — discrete destinations, arrived at. This is a continuous dial: rain = 0.4 is a real mix and so is 0.41. Where a snapshot says "the underwater mix", a parameter says "this much underwater", and the difference is whether the transition is a thing that happens or a thing that is being held at a position.

And what a per-voice parameter is not. Everything here is shared by everything routed through it, so it cannot say "this player is underwater and that one is not". That is AudioParameterSheet, attached per sound. The two are deliberately separate types rather than one with a scope flag, because the set of things each can drive has no overlap at all.

Resolved once, applied every frame. Names become bus, send and effect references at construction, and anything that does not resolve is reported rather than thrown — a mixer is content. After that a step is arithmetic and a handful of property writes.

Fields and properties (2)

Methods (6)

  • public MixerParameters(AudioMixer mixer, IReadOnlyList<AudioBusParameterDefinition> definitions, out IReadOnlyList<string> problems)

    Resolves some parameters against a mixer.

  • public int IndexOf(string name)

    Finds a parameter by name.

  • public bool Set(int index, float value)

    Points a parameter at a value.

  • public bool Set(string name, float value)

    Points a parameter at a value, by name.

  • public float ValueOf(int index)

    Where a parameter currently is, which is not always where it was pointed.

  • public void Step(float deltaSeconds)

    Steps every parameter towards its target and pushes the result into the mix.

Used by (6)

  • AudioEngineVixen.Audio
  • AudioReverbZonesVixen.Audio
  • MixControlVixen.Audio
  • MixerParameterTestsVixen.Audio.Tests
  • MusicPlayerVixen.Audio
  • MusicPlayerTestsVixen.Audio.Tests