...
 
Commits (3)
chair = library("chair.lib");
de = library("delays.lib");
fi = library("filters.lib");
no = library("noises.lib");
ma = library("maths.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 :
......@@ -38,5 +40,8 @@ pricess =
de.delay(ma.SR/5),_) ~ _ : (!,_);
process =
chair.dc_offset : (_, 4 * ma.SR / 1000, _ ) :
(chair.allp);
//chair.dc_offset : (_, 4 * ma.SR / 1000, _ ) :
//(chair.allp);
chair.dc_offset :
chair.udn(delay, decay, _ * psi);
......@@ -3,16 +3,8 @@ chair = library("chair.lib");
import("stdfaust.lib");
declare options "[midi:on]";
g(x) =
(x, _, x, _, x, _, x,_) : (*,*,*,*);
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;
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;
mx(psi,damp) =
(cos(psi),_, sin(psi) * (-1),_, sin(psi),_, cos(psi),_) : (*,*,*,*) : g(damp);
process =
((_,chair.x,_) : (+,+) : (_,_) <: mx((ctl2 * ma.PI),(1-(ctl1/10))) : (+,+)) ~
(de.delay(ma.SR/5, ctl0*5*ma.SR/1000),de.delay(ma.SR/5, 5*ma.SR/1000)) ;
process = chair.udn(delay, decay, psi);
chair = library("chair.lib");
import("stdfaust.lib");
declare options "[midi:on]";
g(x) =
(x, _, x, _, x, _, x,_) : (*,*,*,*);
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;
mx(psi,damp) =
(cos(psi),_, sin(psi) * (-1),_, sin(psi),_, cos(psi),_) : (*,*,*,*) : g(damp);
process =
((_,chair.x,_) : (+,+) : (_,_) <: mx((ctl2 * ma.PI),(1-(ctl1/10))) : (+,+)) ~
(de.delay(ma.SR/5, ctl0*5*ma.SR/1000),de.delay(ma.SR/5, 5*ma.SR/1000)) ;
#sources = *.dsp
#svg : $(sources)
# faust -svg $< > /dev/null
dspsrc := $(wildcard *.dsp)
cppsrc := $(dspsrc:.dsp=.cpp)
#plugins := $(dspsrc:%.dsp=%~.pd_linux)
svg := $(dspsrc:.dsp=-svg)
jconsole := $(dspsrc:.dsp=)
#xml := $(dspsrc:.dsp=.dsp.xml)
#pd := $(dspsrc:.dsp=.pd)
#jackconsole : %.cpp
# faust -a jack-console.cpp -o 01.percussion-snare.cpp 01.percussion-snare.dsp
# g++ -lpthread `pkg-config --cflags --libs jack` -Wfatal-errors -O3 -mfpmath=sse -msse -msse2 -msse3 -ffast-math 01.percussion-snare.cpp -o 01.percussion-snare-jackconsole
# g++ -lpthread `pkg-config --cflags --libs jack` -Wfatal-errors -O3 -mfpmath=sse -msse -msse2 -msse3 -ffast-math $< -o $@
# install -d build
# install 01.percussion-snare-jackconsole build/01.percussion-snare-jackconsole
# rm 01.percussion-snare-jackconsole
all: $(jconsole) $(svg)
#%.cpp : $(sources)
# faust -a jack-console.cpp -o $@.cpp $<
graphics: $(svg)
#oldsvg : 01.percussion-snare.dsp
# faust -svg 01.percussion-snare.dsp > /dev/null
jackconsole : 02.unitary-delay-network
faust2jackconsole -midi $<.dsp
standalones: $(jconsole)
clean:
rm -f *.cpp
rm -rf *-svg
rm -rf *-mdoc
rm -Rf *~ $(svg) $(jconsole)
%-svg: %.dsp
faust2svg $<
% : %.dsp
faust2jackconsole $<
#%.cpp %-svg: %.dsp
# faust -xml -svg -sd -a puredata.cpp $< -o $@
#%~.pd_linux: %.cpp
# g++ -shared -fPIC -Dmydsp=$(@:%~.pd_linux=%) -o $@ $<
#%.pd: %.dsp.xml
# faust2pd -s $<
fi = library("filters.lib");
de = library("delays.lib");
ma = library("maths.lib");
import("stdfaust.lib");
// as we need lots of filters in a row
// we make use of fausts rewriting rules
......@@ -18,6 +16,16 @@ dc_offset = _ <: (_,_): (_, (hp_row(4))):
x = (_,_)<:(!,_,_,!);
g(x) =
(x, _, x, _, x, _, x,_) : (*,*,*,*);
mx(psi,damp) =
(cos(psi),_, sin(psi) * (-1),_, sin(psi),_, cos(psi),_) : (*,*,*,*) : g(damp);
udn(deltime, decay, gfactor) =
((_,x,_) : (+,+) : (_,_) <: mx((gfactor * ma.PI),(1-(decay/10))) : (+,+)) ~
(de.delay(ma.SR/5, deltime*5*ma.SR/1000),de.delay(ma.SR/5, 5*ma.SR/1000)) ;
allp =
(_,_,_) :
((_<:(_,_)),_,_) :
......