MCPcopy Create free account
hub / github.com/csound/csound / init

Method init

Opcodes/pvsops.cpp:180–207  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

178 }
179
180 int init() {
181 pars = inargs[4];
182 fils = inargs[5];
183 if (pars > fils)
184 std::swap(pars, fils);
185 if (pars > 1) {
186 pars = rpow2(pars);
187 fils = rpow2(fils) * 2;
188 ffts = pars * 2;
189 fwd = csound->fft_setup(ffts, FFT_FWD);
190 inv = csound->fft_setup(ffts, FFT_INV);
191 out.allocate(csound, ffts);
192 insp.allocate(csound, fils);
193 irsp.allocate(csound, fils);
194 saved.allocate(csound, pars);
195 ir.allocate(csound, fils);
196 in.allocate(csound, fils);
197 itnsp = insp.begin();
198 itrsp = irsp.begin();
199 n = 0;
200 } else {
201 ir.allocate(csound, fils);
202 in.allocate(csound, fils);
203 }
204 itn = in.begin();
205 itr = ir.begin();
206 return OK;
207 }
208
209 int pconv() {
210 csnd::AudioSig insig(this, inargs(0));

Callers 2

initMethod · 0.45
initMethod · 0.45

Calls 3

fft_setupMethod · 0.80
allocateMethod · 0.80
beginMethod · 0.45

Tested by

no test coverage detected