clang-tidy: Apply modernize-avoid-c-arrays everywhere (#6564)

Co-authored-by: Dominic Clark <mrdomclark@gmail.com>
Co-authored-by: Hyunjin Song <tteu.ingog@gmail.com>
This commit is contained in:
saker
2022-12-30 17:18:14 -05:00
committed by GitHub
parent edd759b511
commit a876cf9d00
54 changed files with 369 additions and 366 deletions

View File

@@ -105,17 +105,17 @@ bool DynProcEffect::processAudioBuffer( sampleFrame * _buf,
// variables for effect
int i = 0;
float sm_peak[2] = { 0.0f, 0.0f };
auto sm_peak = std::array{0.0f, 0.0f};
float gain;
double out_sum = 0.0;
const float d = dryLevel();
const float w = wetLevel();
const int stereoMode = m_dpControls.m_stereomodeModel.value();
const float inputGain = m_dpControls.m_inputModel.value();
const float outputGain = m_dpControls.m_outputModel.value();
const float * samples = m_dpControls.m_wavegraphModel.samples();
// debug code
@@ -143,7 +143,7 @@ bool DynProcEffect::processAudioBuffer( sampleFrame * _buf,
for( fpp_t f = 0; f < _frames; ++f )
{
double s[2] = { _buf[f][0], _buf[f][1] };
auto s = std::array{_buf[f][0], _buf[f][1]};
// apply input gain
s[0] *= inputGain;
@@ -211,7 +211,7 @@ bool DynProcEffect::processAudioBuffer( sampleFrame * _buf,
gain = samples[199];
};
s[i] *= gain;
s[i] *= gain;
s[i] /= sm_peak[i];
}
}