MCPcopy Create free account
hub / github.com/Signalsmith-Audio/reverb-example-code / DiffuserEqualLengths

Class DiffuserEqualLengths

reverb-example-code.h:158–180  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

156
157template<int channels=8, int stepCount=4>
158struct DiffuserEqualLengths {
159 using Array = std::array<double, channels>;
160
161 using Step = DiffusionStep<channels>;
162 std::array<Step, stepCount> steps;
163
164 DiffuserEqualLengths(double totalDiffusionMs) {
165 for (auto &step : steps) {
166 step.delayMsRange = totalDiffusionMs/stepCount;
167 }
168 }
169
170 void configure(double sampleRate) {
171 for (auto &step : steps) step.configure(sampleRate);
172 }
173
174 Array process(Array samples) {
175 for (auto &step : steps) {
176 samples = step.process(samples);
177 }
178 return samples;
179 }
180};
181
182template<int channels=8, int stepCount=4>
183struct DiffuserHalfLengths {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected