[Csnd] filters doc
Date | 2023-07-14 20:35 |
From | Raoul MEGELAS |
Subject | [Csnd] filters doc |
Hello all, in nreverb i see 2 filters tables F71 and F72. is there a doc for these differents parameters of each filter? Thanks in advance. Bests. Raoul MEGELAS Csound mailing list Csound@listserv.heanet.ie https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted here |
Date | 2023-07-14 22:42 |
From | ST Music |
Subject | Re: [Csnd] filters doc |
On Fri, Jul 14, 2023, 3:35 p.m. Raoul MEGELAS <rmgls2943@gmail.com> wrote: Hello all, |
Date | 2023-07-15 07:56 |
From | Raoul MEGELAS |
Subject | Re: [Csnd] filters doc |
Hi Scott, i am trying to understand each parameter of f71 and f72 that is why i asked, i have already read the doc here, where i found these 2 examples. But thanks for the link, and Bests. Raoul CSOUND IS the best tool
|
Date | 2023-07-15 20:36 |
From | Oeyvind Brandtsegg |
Subject | Re: [Csnd] filters doc |
All good. See: ifnCombs - function table with inumCombs comb filter time values, followed the same number of gain values. The ftable should not be rescaled (use negative fgen number). Positive time values are in seconds. The time values are converted internally into number of samples, then set to the next greater prime number. If the time is negative, it is interpreted directly as time in sample frames, and no processing is done (except negation). New in Csound version 4.09 So the first comb filter in the example has 1116 samples delay and a gain of 0.8 f71 0 16 -2 -1116 -1188 -1277 -1356 -1422 -1491 -1557 -1617 0.8 0.79 0.78 0.77 0.76 0.75 0.74 0.73 Øyvind lør. 15. jul. 2023, 08:56 skrev Raoul MEGELAS <rmgls2943@gmail.com>:
|
Date | 2023-07-15 20:42 |
From | ST Music |
Subject | Re: [Csnd] filters doc |
Hi Raoul,
Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here
Well, Oyvind answered just as I wrote this but in case it adds any clarification: f71 and f72 are function table statements: The table numbers are arbitrary, they could have been f1 and f2. The table values only affect the delay loop times and amplitudes for the comb and allpass filters. Looking at f71: p1 (71) is the table number p2 (0) is the time at which ftable is generated p3 (16) is the size of the table; how many points or values are in the table (f71 will have 16 values). These values begin at p5. Since inumCombs is 8 there should be 16 values, 8 each for the comb filter delay times and amplitudes p4 (-2) is the type of table, referred to as a GEN routine. f71 & f72 are GEN02: p4 is specified as a negative number (-2) so that the 16 values (p5 thru p20) are not re-scaled (normalized to between 0 - 1) p13 thru p12 are the amplitude values of the comb filter delays The comb filters are essentially lowpass filtered delays that will continue to loop (feedback) for the ktime value of nreverb. The khdif value of nreverb will determine how much the lowpass filter affects the delay loop. Comb filters are partially explained here: f72 is the same as f71 but sets the delay times & amplitude for the allpass filters For example: <CsoundSynthesizer> <CsOptions> ; Select audio/midi flags here according to platform ; Audio out Audio in No messages -odac -iadc -d ;;;RT audio I/O ; For Non-realtime ouput leave only the line below: ; -o nreverb_ftable.wav -W ;;; for file output any platform </CsOptions> <CsInstruments> ; Initialize the global variables. sr = 44100 kr = 4410 ksmps = 10 nchnls = 1 0dbfs = 1 instr 1 a1 = vco2:a(linseg(0, .003, .8, .1, 0), 220) a2 nreverb a1, 10.5, .75, 0, 1, 71, 1, 72 out a1 + a2 * .4 endin </CsInstruments> <CsScore> f71 0 2 -2 -22050 .8 f72 0 2 -2 -5512 .7 i1 0 4 i. + . i. + . i. + 11 e </CsScore> </CsoundSynthesizer> Here only 1 delay time value (p5) and 1 amplitude (p6) are used for the comb & allpass filter values (f71 & f72) since inumCombs and inumAlpas are set at 1 for nreverb. Since the project sr is 44100, a delay value of -22050 samples is 1/2 of a second, -5512 is approx. 1/8 of a sec. Those values make the delay (echo) very obvious but will sound less like reverb. The filtered delays will continue to loop (feedback) for krvt which is 10.5 seconds. Since the allpass filters run in series after the comb filters there will be a longer pause between the first note played and the first audible delay. There is an article which discusses the basis of the reverb design here: Perhaps some of this is redundant, if so I apologize. Best, Scott On Sat, Jul 15, 2023, 2:56 a.m. Raoul MEGELAS <rmgls2943@gmail.com> wrote:
|
Date | 2023-07-16 07:39 |
From | Raoul MEGELAS |
Subject | Re: [Csnd] filters doc |
Hi Scott, really appreciated, this is clear, and detailed: exactly what i needed. Thanks. all the best Raoul
|
Date | 2023-07-16 07:43 |
From | Raoul MEGELAS |
Subject | Re: [Csnd] filters doc |
Hello, i understand better now. and i see than i must add a bandpass filter to this example. Thanks to you for clarification. Bests Raoul MEGELAS
|