diff options
author | Chris Robinson <[email protected]> | 2023-01-05 01:47:55 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2023-01-05 01:47:55 -0800 |
commit | 23c8a35505fe6ab7a5c87754911a133b23ac75cf (patch) | |
tree | d36b9dabb413680d8074f3e8aad0084691d20813 /core/mixer.h | |
parent | 58a18ab3c0126337d17939b5060fce28a39b8cf1 (diff) |
Add and use mixers that process one input and output channel
Diffstat (limited to 'core/mixer.h')
-rw-r--r-- | core/mixer.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/core/mixer.h b/core/mixer.h index 9ed1f5b3..aa7597bb 100644 --- a/core/mixer.h +++ b/core/mixer.h @@ -24,6 +24,14 @@ inline void MixSamples(const al::span<const float> InSamples, const size_t Counter, const size_t OutPos) { MixSamplesOut(InSamples, OutBuffer, CurrentGains, TargetGains, Counter, OutPos); } +/* Mixer functions that handle one input and one output channel. */ +using MixerOneFunc = void(*)(const al::span<const float> InSamples, float *OutBuffer, + float &CurrentGain, const float TargetGain, const size_t Counter); + +extern MixerOneFunc MixSamplesOne; +inline void MixSamples(const al::span<const float> InSamples, float *OutBuffer, float &CurrentGain, + const float TargetGain, const size_t Counter) +{ MixSamplesOne(InSamples, OutBuffer, CurrentGain, TargetGain, Counter); } /** |