Performance: Audio mixer
MEDIUM IMPACT
Audio mixers affect how audio is processed and mixed in real-time, impacting CPU usage and audio latency.
AudioMixer mixer = new AudioMixer(); mixer.AddEffect("Reverb"); // Group audio sources and apply effects once per group instead of individually
AudioMixer mixer = new AudioMixer(); mixer.AddEffect("Reverb"); mixer.AddEffect("Echo"); mixer.AddEffect("Distortion"); // Apply effects to every audio source individually
| Pattern | CPU Usage | Latency | Audio Quality Impact | Verdict |
|---|---|---|---|---|
| Applying many effects per audio source | High | High | Good but costly | [X] Bad |
| Grouping sources and applying effects once | Low | Low | Good balance | [OK] Good |