...
 
Commits (2)
......@@ -4,6 +4,7 @@
*.kdev4
*-svg/
*-mdoc/
*.vst/
FAUST/*.cpp
FAUST/build/
FAUST/recordings/
......
chair = library("chair.lib");
import("stdfaust.lib");
declare options "[midi:on]";
delay = hslider("delay[midi:ctrl 11]",0.5,0.0000001,1,0.0000001) : si.smoo;
decay = hslider("decay[midi:ctrl 12]",0.5,0,1,0.001) : si.smoo;
psi = hslider("psi[midi:ctrl 13]",0.5,0.0001,1,0.00001) : si.smoo;
pricess =
chair.dc_offset :
// 1. DC as an envelope
// 2. Clean signal
// We'll take the output of the 2nd outlet unchanged all the way down to the last sum;
// and work on the signal on the 1st bus
(fi.lowpass(1, 20),_) :
(* (0.5),_) :
(+ (2.947),_) :
// This is where the magic happens.
// What is delread in pd is this loop ( ... ~ _ ) in faust
// plus a de.delay or its interpolated counterpart de.fdalay.
// The opening braces is the beginning of the loop
// and the ~-Symbol is forking the signal to feed it back as an additional input to the block.
((no.noise:fi.lowpass(1,2000): * (10.5)), (no.noise:fi.lowpass(1,100): + (1) : * (0.75)),_,_) :
((_,chair.x,_,_) :
(chair.x,_,_,_) :
(_,chair.x,_,_) :
(chair.allp,_,_) :
(((0.5, 2.2, _) : chair.allp),_,_) :
(((0.14, 2.5, _) : chair.allp),_,_) :
(((1, 4, _) : chair.allp),_,_) :
(fi.lowpass(1,7000),_,_) :
(fi.highpass(1,200),_,_) :
(* (-1),_,_) :
(* (0.99),_,_) :
(chair.x,(_<:(_,_))) :
(_,+,_) :
//de.fdelay4(ma.SR/5),_) ~ _ : (!,_);
de.delay(ma.SR/5),_) ~ _ : (!,_);
process =
//chair.dc_offset : (_, 4 * ma.SR / 1000, _ ) :
//(chair.allp);
chair.dc_offset :
chair.udn(delay, decay, _ * psi);
prociss =
chair.dc_offset : chair.allp(_, delay, decay, psi);
chair = library("chair.lib");
import("stdfaust.lib");
declare options "[midi:on]";
delay = hslider("delay[midi:ctrl 11]",0.5,0.0000001,1,0.0000001) : si.smoo;
decay = hslider("decay[midi:ctrl 12]",0.5,0,1,0.001) : si.smoo;
theta = hslider("theta[midi:ctrl 13]",0.5,0.0001,1,0.00001) : si.smoo;
// udn(deltime, theta, gfactor)
// Two inputs, one for each of the delaylines.
// In this case the dc-offset is feeding the second delay,
// which can be seen as the imaginary part of the signal.
// In this patch the delay lies between 0 and 5 milliseconds,
// but the maxdelay time for the udn in the chair.lib
// is set to 20 hundrets of a second.
// In applications where memory matters,
// this value might want to be changed in the library.
process = chair.dc_offset : chair.udn(delay, theta, decay);
......@@ -7,6 +7,11 @@ ctl0 = hslider("delay[midi:ctrl 11]",0.5,0.0000001,1,0.0000001) : si.smoo;
ctl1 = hslider("decay[midi:ctrl 12]",0.5,0,1,0.001) : si.smoo;
ctl2 = hslider("psi[midi:ctrl 13]",0.5,0.0001,1,0.00001) : si.smoo;
// allp(gfactor, psi, deltime) =
// Here, the input will go to both delaylines.
process =
// allp(decay, gfactor, deltime)
chair.dc_offset : (_* ctl0, _) : chair.allp(ctl1, ctl2);
//chair.dc_offset : (_* ctl0, _) : chair.allp(ctl1, ctl2);
chair.dc_offset : (!,_) :
(ctl0, _) :
((fi.lowpass(1, 20) * 0.5) + 1.0, _) :
chair.allp(ctl1, ctl2);
......@@ -5,6 +5,7 @@ declare options "[midi:on]";
delay = hslider("delay[midi:ctrl 11]",0.5,0.0000001,1,0.0000001) : si.smoo;
decay = hslider("decay[midi:ctrl 12]",0.5,0,1,0.001) : si.smoo;
psi = hslider("psi[midi:ctrl 13]",0.5,0.0001,1,0.00001) : si.smoo;
theta = hslider("theta[midi:ctrl 13]",0.5,0.0001,1,0.00001) : si.smoo;
process = chair.udn(delay, decay, psi);
// This is the
process = chair.schmalfuss(delay, theta, decay);
chair = library("chair.lib");
import("stdfaust.lib");
declare options "[midi:on]";
ctl0 = hslider("delay[midi:ctrl 11]",0.5,0.0000001,1,0.0000001) : si.smoo;
ctl1 = hslider("decay[midi:ctrl 12]",0.1,0,1,0.001) : si.smoo;
ctl2 = hslider("psi[midi:ctrl 13]",0.5,0.0001,1,0.00001) : si.smoo;
noise1 =
(no.noise : fi.lowpass(1, 2000) : + (10.5));
noise2 =
(no.noise : fi.lowpass(1, 100) : + (1) : * (0.75));
mainDecay =
((1 - pow(ctl1, 3)) * 0.275 ) + 0.7;
noise3 =
(no.noise : fi.lowpass(1, 500) : * (mainDecay/100));
//
most(mainDtime) =
(
_<:(_,_) :
( +, _ :
(
// allp(gfactor, psi, deltime) =
chair.schmalfuss(1, noise2, noise1) :
chair.schmalfuss(1, 0.5, 2.2) :
chair.schmalfuss(1, 0.12, 2.5) :
chair.schmalfuss(1, 0, noise3) :
fi.lowpass(1, 7000) : fi.highpass(1, 200) :
(* (-1)) :
max(-1) : min(1) :
(* ( mainDecay ))),_ :
+
) ~ de.delay(ma.SR/5, mainDtime * 5 * ma.SR/10)
);
process =
chair.dc_offset :
((fi.lowpass(1, 20) * 0.5) + 2.5, _) :
most;
......@@ -15,7 +15,7 @@ graphics: $(svg)
standalones: $(jconsole)
clean:
rm -Rf *~ $(svg) $(jconsole)
rm -Rf *~ $(svg) $(jconsole) faust.*
%-svg: %.dsp
faust2svg $<
......@@ -26,7 +26,7 @@ clean:
install:
install -d $(DESTDIR)
install $(jconsole) $(DESTDIR)
rm $(jconsole)
# rm $(jconsole)
#%.cpp %-svg: %.dsp
# faust -xml -svg -sd -a puredata.cpp $< -o $@
......
......@@ -10,31 +10,65 @@ hp_row(n) = fi.highpass(1, 4) : hp_row(n-1);
// is providing two signals:
// 1. DC as an envelope
// 2. Clean signal
dc_offset = _ <: (_,_): (_, (hp_row(4))):
(_,(_<:(_,_))):
((-:fi.lowpass(1, 100) * 25),_);
dc_offset =
_ <: (_,_) :
(_, (hp_row(4))) :
(_,(_<:(_,_))) :
((- : fi.lowpass(1, 100) * 25),_);
x = (_,_)<:(!,_,_,!);
g(x) =
(x, _, x, _, x, _, x,_) : (*,*,*,*);
mx(psi,damp) =
(cos(psi),_, sin(psi) * (-1),_, sin(psi),_, cos(psi),_) : (*,*,*,*) : g(damp);
mx(theta,damp) =
(cos(theta),_, sin(theta) * (-1),_, sin(theta),_, cos(theta),_) : (*,*,*,*) : g(damp);
udn(deltime, decay, gfactor) =
// We need several of these.
// They differ in the organisation of the inputs and outputs,
// not in what they are doing.
mx0(theta,damp) =
(
cos(theta * ma.PI * 2),_,
sin(theta * ma.PI * 2),_,
sin(theta * ma.PI * 2) * (-1),_,
cos(theta * ma.PI * 2),_
) : (*,*,*,*) : g(damp);
schmalfuss(deltime, theta, gfactor) =
// This delayline only processes the "imaginary" part of the signal
(_<:(_,_)) :
(((_,x,_) :
mx0((theta),(1-(gfactor/10))) : (+,+)) ~
(de.delay(ma.SR/5, deltime * 5 * ma.SR/1000) <: (_,_))) :
(!,_);
udn(deltime, theta, gfactor) =
// Two inputs, one for each of the delaylines.
((_,x,_) : (+,+) : (_,_) <: mx((gfactor * ma.PI),(1-(decay/10))) : (+,+)) ~
// This is the unitary delay network as discribed in
// "Infuriating nonlinear reverbarator" by Miller Puckette (ICMC 2011)
((_,x,_) : (+,+) : (_,_) <: mx((theta * ma.PI),(1-(gfactor/10))) : (+,+)) ~
(de.delay(ma.SR/5, deltime * 5 * ma.SR/1000),de.delay(ma.SR/5, deltime * 5 * ma.SR/1000)) : + ;
allp(decay, gfactor, deltime) =
allp(gfactor, theta, deltime) =
// Here, the input will go to both delaylines.
(_<:(_,_)) :
(((_,x,_) : (+,+) : (_,_) <: mx((gfactor * ma.PI),(1-(decay/10))) : (+,+)) ~
(((_,x,_) : (+,+) : (_,_) <: mx((theta * ma.PI),(1-(gfactor/10))) : (+,+)) ~
(de.delay(ma.SR/5, deltime * 5 * ma.SR/1000), de.delay(ma.SR/5, deltime * 5 * ma.SR/1000))) :
//(fi.allpassn(5, (-0.1,0.1,-0.1,0.1,-0.11)), fi.allpassn(5, (0.1,-0.1,0.1,-0.1,0.1))) :
+ ;
allp1d(gfactor, theta, deltime) =
// Here, the input will go to both delaylines
// and they are added to one delay
// which might not actually make sense :-/
(_<:(_,_)) :
(((_,x,_) : (+,+) : (_,_) <: mx((theta * ma.PI),(1-(gfactor/10))) : (+,+)) ~
( + : de.delay(ma.SR/5, deltime * 5 * ma.SR/1000) : (_<:(_,_)))) :
//(fi.allpassn(5, (-0.1,0.1,-0.1,0.1,-0.11)), fi.allpassn(5, (0.1,-0.1,0.1,-0.1,0.1))) :
+ ;
// This is still here because it was a lot of work :_(
allp0 =
(_,_,_) :
((_<:(_,_)),_,_) :
......