diff options
Diffstat (limited to 'alc/effects')
-rw-r--r-- | alc/effects/autowah.cpp | 6 | ||||
-rw-r--r-- | alc/effects/compressor.cpp | 4 | ||||
-rw-r--r-- | alc/effects/dedicated.cpp | 8 | ||||
-rw-r--r-- | alc/effects/equalizer.cpp | 6 | ||||
-rw-r--r-- | alc/effects/modulator.cpp | 6 | ||||
-rw-r--r-- | alc/effects/vmorpher.cpp | 6 |
6 files changed, 18 insertions, 18 deletions
diff --git a/alc/effects/autowah.cpp b/alc/effects/autowah.cpp index 50ec0268..f32c69b8 100644 --- a/alc/effects/autowah.cpp +++ b/alc/effects/autowah.cpp @@ -65,7 +65,7 @@ struct AutowahState final : public EffectState { } mEnv[BufferLineSize]; struct { - uint mTargetChannel{INVALID_CHANNEL_INDEX}; + uint mTargetChannel{InvalidChannelIndex}; /* Effect filters' history. */ struct { @@ -110,7 +110,7 @@ void AutowahState::deviceUpdate(const DeviceBase*, const Buffer&) for(auto &chan : mChans) { - chan.mTargetChannel = INVALID_CHANNEL_INDEX; + chan.mTargetChannel = InvalidChannelIndex; chan.mFilter.z1 = 0.0f; chan.mFilter.z2 = 0.0f; chan.mCurrentGain = 0.0f; @@ -175,7 +175,7 @@ void AutowahState::process(const size_t samplesToDo, for(const auto &insamples : samplesIn) { const size_t outidx{chandata->mTargetChannel}; - if(outidx == INVALID_CHANNEL_INDEX) + if(outidx == InvalidChannelIndex) { ++chandata; continue; diff --git a/alc/effects/compressor.cpp b/alc/effects/compressor.cpp index c57bd58c..299394cf 100644 --- a/alc/effects/compressor.cpp +++ b/alc/effects/compressor.cpp @@ -65,7 +65,7 @@ namespace { struct CompressorState final : public EffectState { /* Effect gains for each channel */ struct { - uint mTarget{INVALID_CHANNEL_INDEX}; + uint mTarget{InvalidChannelIndex}; float mGain{1.0f}; } mChans[MaxAmbiChannels]; @@ -168,7 +168,7 @@ void CompressorState::process(const size_t samplesToDo, for(const auto &input : samplesIn) { const size_t outidx{chan->mTarget}; - if(outidx != INVALID_CHANNEL_INDEX) + if(outidx != InvalidChannelIndex) { const float *RESTRICT src{input.data() + base}; float *RESTRICT dst{samplesOut[outidx].data() + base}; diff --git a/alc/effects/dedicated.cpp b/alc/effects/dedicated.cpp index a1c85ecd..e666df9f 100644 --- a/alc/effects/dedicated.cpp +++ b/alc/effects/dedicated.cpp @@ -74,8 +74,8 @@ void DedicatedState::update(const ContextBase*, const EffectSlot *slot, if(slot->EffectType == EffectSlotType::DedicatedLFE) { - const uint idx{target.RealOut ? target.RealOut->ChannelIndex[LFE] : INVALID_CHANNEL_INDEX}; - if(idx != INVALID_CHANNEL_INDEX) + const uint idx{target.RealOut ? target.RealOut->ChannelIndex[LFE] : InvalidChannelIndex}; + if(idx != InvalidChannelIndex) { mOutTarget = target.RealOut->Buffer; mTargetGains[idx] = Gain; @@ -86,8 +86,8 @@ void DedicatedState::update(const ContextBase*, const EffectSlot *slot, /* Dialog goes to the front-center speaker if it exists, otherwise it * plays from the front-center location. */ const uint idx{target.RealOut ? target.RealOut->ChannelIndex[FrontCenter] - : INVALID_CHANNEL_INDEX}; - if(idx != INVALID_CHANNEL_INDEX) + : InvalidChannelIndex}; + if(idx != InvalidChannelIndex) { mOutTarget = target.RealOut->Buffer; mTargetGains[idx] = Gain; diff --git a/alc/effects/equalizer.cpp b/alc/effects/equalizer.cpp index f7e2a071..9d7cccef 100644 --- a/alc/effects/equalizer.cpp +++ b/alc/effects/equalizer.cpp @@ -87,7 +87,7 @@ namespace { struct EqualizerState final : public EffectState { struct { - uint mTargetChannel{INVALID_CHANNEL_INDEX}; + uint mTargetChannel{InvalidChannelIndex}; /* Effect parameters */ BiquadFilter mFilter[4]; @@ -113,7 +113,7 @@ void EqualizerState::deviceUpdate(const DeviceBase*, const Buffer&) { for(auto &e : mChans) { - e.mTargetChannel = INVALID_CHANNEL_INDEX; + e.mTargetChannel = InvalidChannelIndex; std::for_each(std::begin(e.mFilter), std::end(e.mFilter), std::mem_fn(&BiquadFilter::clear)); e.mCurrentGain = 0.0f; @@ -176,7 +176,7 @@ void EqualizerState::process(const size_t samplesToDo, const al::span<const Floa for(const auto &input : samplesIn) { const size_t outidx{chan->mTargetChannel}; - if(outidx != INVALID_CHANNEL_INDEX) + if(outidx != InvalidChannelIndex) { const al::span<const float> inbuf{input.data(), samplesToDo}; DualBiquad{chan->mFilter[0], chan->mFilter[1]}.process(inbuf, buffer.begin()); diff --git a/alc/effects/modulator.cpp b/alc/effects/modulator.cpp index aa0b1f70..79993c0d 100644 --- a/alc/effects/modulator.cpp +++ b/alc/effects/modulator.cpp @@ -84,7 +84,7 @@ struct ModulatorState final : public EffectState { uint mStep{1}; struct { - uint mTargetChannel{INVALID_CHANNEL_INDEX}; + uint mTargetChannel{InvalidChannelIndex}; BiquadFilter mFilter; @@ -106,7 +106,7 @@ void ModulatorState::deviceUpdate(const DeviceBase*, const Buffer&) { for(auto &e : mChans) { - e.mTargetChannel = INVALID_CHANNEL_INDEX; + e.mTargetChannel = InvalidChannelIndex; e.mFilter.clear(); e.mCurrentGain = 0.0f; } @@ -160,7 +160,7 @@ void ModulatorState::process(const size_t samplesToDo, const al::span<const Floa for(const auto &input : samplesIn) { const size_t outidx{chandata->mTargetChannel}; - if(outidx != INVALID_CHANNEL_INDEX) + if(outidx != InvalidChannelIndex) { alignas(16) float temps[MAX_UPDATE_SAMPLES]; diff --git a/alc/effects/vmorpher.cpp b/alc/effects/vmorpher.cpp index 0eb136f9..97267ad9 100644 --- a/alc/effects/vmorpher.cpp +++ b/alc/effects/vmorpher.cpp @@ -143,7 +143,7 @@ struct FormantFilter struct VmorpherState final : public EffectState { struct { - uint mTargetChannel{INVALID_CHANNEL_INDEX}; + uint mTargetChannel{InvalidChannelIndex}; /* Effect parameters */ FormantFilter mFormants[NUM_FILTERS][NUM_FORMANTS]; @@ -231,7 +231,7 @@ void VmorpherState::deviceUpdate(const DeviceBase*, const Buffer&) { for(auto &e : mChans) { - e.mTargetChannel = INVALID_CHANNEL_INDEX; + e.mTargetChannel = InvalidChannelIndex; std::for_each(std::begin(e.mFormants[VOWEL_A_INDEX]), std::end(e.mFormants[VOWEL_A_INDEX]), std::mem_fn(&FormantFilter::clear)); std::for_each(std::begin(e.mFormants[VOWEL_B_INDEX]), std::end(e.mFormants[VOWEL_B_INDEX]), @@ -298,7 +298,7 @@ void VmorpherState::process(const size_t samplesToDo, const al::span<const Float for(const auto &input : samplesIn) { const size_t outidx{chandata->mTargetChannel}; - if(outidx == INVALID_CHANNEL_INDEX) + if(outidx == InvalidChannelIndex) { ++chandata; continue; |