-- | Sc3 Ugen bindings (auto-generated).
module Sound.Sc3.Ugen.Bindings.Db where

import Sound.Sc3.Common.Enum
import Sound.Sc3.Common.Envelope
import Sound.Sc3.Common.Rate
import Sound.Sc3.Common.Uid
import Sound.Sc3.Common.Unsafe

import Sound.Sc3.Ugen.Primitive
import Sound.Sc3.Ugen.Ugen
import Sound.Sc3.Ugen.Util

{- | Apply a binary operation to the values of an input Ugen

 BinaryOpUgen [InitialisationRate,ControlRate,AudioRate,DemandRate] a=0 b=0;    FILTER: TRUE
-}
binaryOpUgen :: Ugen -> Ugen -> Ugen
binaryOpUgen :: Ugen -> Ugen -> Ugen
binaryOpUgen Ugen
a Ugen
b = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate, Rate
DemandRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1]) String
"BinaryOpUGen" [Ugen
a, Ugen
b] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Apply a unary operation to the values of an input ugen

 UnaryOpUgen [InitialisationRate,ControlRate,AudioRate,DemandRate] a=0;    FILTER: TRUE
-}
unaryOpUgen :: Ugen -> Ugen
unaryOpUgen :: Ugen -> Ugen
unaryOpUgen Ugen
a = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate, Rate
DemandRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"UnaryOpUGen" [Ugen
a] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Audio to control rate converter.

 A2K [ControlRate] in=0
-}
a2k :: Ugen -> Ugen
a2k :: Ugen -> Ugen
a2k Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"A2K" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | FIXME: APF purpose.

 APF [ControlRate,AudioRate] in=0 freq=440 radius=0.8;    FILTER: TRUE
-}
apf :: Ugen -> Ugen -> Ugen -> Ugen
apf :: Ugen -> Ugen -> Ugen -> Ugen
apf Ugen
in_ Ugen
freq Ugen
radius = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"APF" [Ugen
in_, Ugen
freq, Ugen
radius] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Schroeder allpass delay line with cubic interpolation.

 AllpassC [ControlRate,AudioRate] in=0 maxdelaytime=0.2 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
allpassC :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
allpassC :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
allpassC Ugen
in_ Ugen
maxdelaytime Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"AllpassC" [Ugen
in_, Ugen
maxdelaytime, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Schroeder allpass delay line with linear interpolation.

 AllpassL [ControlRate,AudioRate] in=0 maxdelaytime=0.2 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
allpassL :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
allpassL :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
allpassL Ugen
in_ Ugen
maxdelaytime Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"AllpassL" [Ugen
in_, Ugen
maxdelaytime, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Schroeder allpass delay line with no interpolation.

 AllpassN [ControlRate,AudioRate] in=0 maxdelaytime=0.2 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
allpassN :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
allpassN :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
allpassN Ugen
in_ Ugen
maxdelaytime Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"AllpassN" [Ugen
in_, Ugen
maxdelaytime, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Basic psychoacoustic amplitude compensation.

 AmpComp [InitialisationRate,ControlRate,AudioRate] freq=0 root=0 exp=0.3333
-}
ampComp :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
ampComp :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
ampComp Rate
rate Ugen
freq Ugen
root Ugen
exp_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"AmpComp" [Ugen
freq, Ugen
root, Ugen
exp_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Basic psychoacoustic amplitude compensation (ANSI A-weighting curve).

 AmpCompA [InitialisationRate,ControlRate,AudioRate] freq=1000 root=0 minAmp=0.32 rootAmp=1
-}
ampCompA :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
ampCompA :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
ampCompA Rate
rate Ugen
freq Ugen
root Ugen
minAmp Ugen
rootAmp = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"AmpCompA" [Ugen
freq, Ugen
root, Ugen
minAmp, Ugen
rootAmp] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Amplitude follower

 Amplitude [ControlRate,AudioRate] in=0 attackTime=0.01 releaseTime=0.01
-}
amplitude :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
amplitude :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
amplitude Rate
rate Ugen
in_ Ugen
attackTime Ugen
releaseTime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Amplitude" [Ugen
in_, Ugen
attackTime, Ugen
releaseTime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | All Pass Filter

 BAllPass [AudioRate] in=0 freq=1200 rq=1;    FILTER: TRUE
-}
bAllPass :: Ugen -> Ugen -> Ugen -> Ugen
bAllPass :: Ugen -> Ugen -> Ugen -> Ugen
bAllPass Ugen
in_ Ugen
freq Ugen
rq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BAllPass" [Ugen
in_, Ugen
freq, Ugen
rq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Band Pass Filter

 BBandPass [AudioRate] in=0 freq=1200 bw=1;    FILTER: TRUE
-}
bBandPass :: Ugen -> Ugen -> Ugen -> Ugen
bBandPass :: Ugen -> Ugen -> Ugen -> Ugen
bBandPass Ugen
in_ Ugen
freq Ugen
bw = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BBandPass" [Ugen
in_, Ugen
freq, Ugen
bw] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Band reject filter

 BBandStop [AudioRate] in=0 freq=1200 bw=1;    FILTER: TRUE
-}
bBandStop :: Ugen -> Ugen -> Ugen -> Ugen
bBandStop :: Ugen -> Ugen -> Ugen -> Ugen
bBandStop Ugen
in_ Ugen
freq Ugen
bw = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BBandStop" [Ugen
in_, Ugen
freq, Ugen
bw] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | 12db/oct rolloff - 2nd order resonant  Hi Pass Filter

 BHiPass [AudioRate] in=0 freq=1200 rq=1;    FILTER: TRUE
-}
bHiPass :: Ugen -> Ugen -> Ugen -> Ugen
bHiPass :: Ugen -> Ugen -> Ugen -> Ugen
bHiPass Ugen
in_ Ugen
freq Ugen
rq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BHiPass" [Ugen
in_, Ugen
freq, Ugen
rq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Hi Shelf

 BHiShelf [AudioRate] in=0 freq=1200 rs=1 db=0;    FILTER: TRUE
-}
bHiShelf :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bHiShelf :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bHiShelf Ugen
in_ Ugen
freq Ugen
rs Ugen
db = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BHiShelf" [Ugen
in_, Ugen
freq, Ugen
rs, Ugen
db] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | 12db/oct rolloff - 2nd order resonant Low Pass Filter

 BLowPass [AudioRate] in=0 freq=1200 rq=1;    FILTER: TRUE
-}
bLowPass :: Ugen -> Ugen -> Ugen -> Ugen
bLowPass :: Ugen -> Ugen -> Ugen -> Ugen
bLowPass Ugen
in_ Ugen
freq Ugen
rq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BLowPass" [Ugen
in_, Ugen
freq, Ugen
rq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Low Shelf

 BLowShelf [AudioRate] in=0 freq=1200 rs=1 db=0;    FILTER: TRUE
-}
bLowShelf :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bLowShelf :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bLowShelf Ugen
in_ Ugen
freq Ugen
rs Ugen
db = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BLowShelf" [Ugen
in_, Ugen
freq, Ugen
rs, Ugen
db] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | 2nd order Butterworth bandpass filter.

 BPF [ControlRate,AudioRate] in=0 freq=440 rq=1;    FILTER: TRUE
-}
bpf :: Ugen -> Ugen -> Ugen -> Ugen
bpf :: Ugen -> Ugen -> Ugen -> Ugen
bpf Ugen
in_ Ugen
freq Ugen
rq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BPF" [Ugen
in_, Ugen
freq, Ugen
rq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Two zero fixed midpass.

 BPZ2 [ControlRate,AudioRate] in=0;    FILTER: TRUE
-}
bpz2 :: Ugen -> Ugen
bpz2 :: Ugen -> Ugen
bpz2 Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BPZ2" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Parametric equalizer

 BPeakEQ [AudioRate] in=0 freq=1200 rq=1 db=0;    FILTER: TRUE
-}
bPeakEQ :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bPeakEQ :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bPeakEQ Ugen
in_ Ugen
freq Ugen
rq Ugen
db = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BPeakEQ" [Ugen
in_, Ugen
freq, Ugen
rq, Ugen
db] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | 2nd order Butterworth band reject filter.

 BRF [ControlRate,AudioRate] in=0 freq=440 rq=1;    FILTER: TRUE
-}
brf :: Ugen -> Ugen -> Ugen -> Ugen
brf :: Ugen -> Ugen -> Ugen -> Ugen
brf Ugen
in_ Ugen
freq Ugen
rq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BRF" [Ugen
in_, Ugen
freq, Ugen
rq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Two zero fixed midcut.

 BRZ2 [ControlRate,AudioRate] in=0;    FILTER: TRUE
-}
brz2 :: Ugen -> Ugen
brz2 :: Ugen -> Ugen
brz2 Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"BRZ2" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Stereo signal balancer

 Balance2 [ControlRate,AudioRate] left=0 right=0 pos=0 level=1;    FILTER: TRUE
-}
balance2 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
balance2 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
balance2 Ugen
left Ugen
right Ugen
pos Ugen
level = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1]) String
"Balance2" [Ugen
left, Ugen
right, Ugen
pos, Ugen
level] Maybe [Ugen]
forall a. Maybe a
Nothing Int
2 (Int -> Special
Special Int
0) UgenId
NoId

{- | physical model of bouncing object

 Ball [ControlRate,AudioRate] in=0 g=1 damp=0 friction=0.01
-}
ball :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
ball :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
ball Rate
rate Ugen
in_ Ugen
g Ugen
damp Ugen
friction_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Ball" [Ugen
in_, Ugen
g, Ugen
damp, Ugen
friction_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Autocorrelation beat tracker

 BeatTrack [ControlRate] chain=0 lock=0
-}
beatTrack :: Rate -> Ugen -> Ugen -> Ugen
beatTrack :: Rate -> Ugen -> Ugen -> Ugen
beatTrack Rate
rate Ugen
chain Ugen
lock = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"BeatTrack" [Ugen
chain, Ugen
lock] Maybe [Ugen]
forall a. Maybe a
Nothing Int
4 (Int -> Special
Special Int
0) UgenId
NoId

{- | Template matching beat tracker

 BeatTrack2 [ControlRate] busindex=0 numfeatures=0 windowsize=2 phaseaccuracy=0.02 lock=0 weightingscheme=0
-}
beatTrack2 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
beatTrack2 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
beatTrack2 Rate
rate Ugen
busindex Ugen
numfeatures Ugen
windowsize Ugen
phaseaccuracy Ugen
lock Ugen
weightingscheme = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"BeatTrack2" [Ugen
busindex, Ugen
numfeatures, Ugen
windowsize, Ugen
phaseaccuracy, Ugen
lock, Ugen
weightingscheme] Maybe [Ugen]
forall a. Maybe a
Nothing Int
6 (Int -> Special
Special Int
0) UgenId
NoId

{- | 2D Ambisonic B-format panner.

 BiPanB2 [ControlRate,AudioRate] inA=0 inB=0 azimuth=0 gain=1
-}
biPanB2 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
biPanB2 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
biPanB2 Rate
rate Ugen
inA Ugen
inB Ugen
azimuth Ugen
gain = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"BiPanB2" [Ugen
inA, Ugen
inB, Ugen
azimuth, Ugen
gain] Maybe [Ugen]
forall a. Maybe a
Nothing Int
3 (Int -> Special
Special Int
0) UgenId
NoId

{- | Band limited impulse oscillator.

 Blip [ControlRate,AudioRate] freq=440 numharm=200
-}
blip :: Rate -> Ugen -> Ugen -> Ugen
blip :: Rate -> Ugen -> Ugen -> Ugen
blip Rate
rate Ugen
freq Ugen
numharm = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Blip" [Ugen
freq, Ugen
numharm] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | (Undocumented class)

 BlockSize [InitialisationRate]
-}
blockSize :: Ugen
blockSize :: Ugen
blockSize = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"BlockSize" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Brown Noise.

 BrownNoise [ControlRate,AudioRate] ;    NONDET
-}
brownNoiseId :: ID a => a -> Rate -> Ugen
brownNoiseId :: forall a. ID a => a -> Rate -> Ugen
brownNoiseId a
z Rate
rate = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"BrownNoise" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of BrownNoise.
brownNoiseM :: Uid m => Rate -> m Ugen
brownNoiseM :: forall (m :: * -> *). Uid m => Rate -> m Ugen
brownNoiseM = (Int -> Rate -> Ugen) -> Fn1 Rate (m Ugen)
forall (m :: * -> *) a b. Uid m => (Int -> Fn1 a b) -> Fn1 a (m b)
liftUid1 Int -> Rate -> Ugen
forall a. ID a => a -> Rate -> Ugen
brownNoiseId

-- | Unsafe variant of BrownNoise.
brownNoise :: Rate -> Ugen
brownNoise :: Rate -> Ugen
brownNoise = (Rate -> IO Ugen) -> Rate -> Ugen
forall a r. (a -> IO r) -> a -> r
liftUnsafe1 Rate -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> m Ugen
brownNoiseM

{- | Buffer based all pass delay line with cubic interpolation.

 BufAllpassC [AudioRate] buf=0 in=0 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
bufAllpassC :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufAllpassC :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufAllpassC Ugen
buf Ugen
in_ Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"BufAllpassC" [Ugen
buf, Ugen
in_, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer based all pass delay line with linear interpolation.

 BufAllpassL [AudioRate] buf=0 in=0 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
bufAllpassL :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufAllpassL :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufAllpassL Ugen
buf Ugen
in_ Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"BufAllpassL" [Ugen
buf, Ugen
in_, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer based all pass delay line with no interpolation.

 BufAllpassN [AudioRate] buf=0 in=0 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
bufAllpassN :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufAllpassN :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufAllpassN Ugen
buf Ugen
in_ Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"BufAllpassN" [Ugen
buf, Ugen
in_, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Current number of channels of soundfile in buffer.

 BufChannels [InitialisationRate,ControlRate] bufnum=0
-}
bufChannels :: Rate -> Ugen -> Ugen
bufChannels :: Rate -> Ugen -> Ugen
bufChannels Rate
rate Ugen
bufnum = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"BufChannels" [Ugen
bufnum] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer based comb delay line with cubic interpolation.

 BufCombC [AudioRate] buf=0 in=0 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
bufCombC :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufCombC :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufCombC Ugen
buf Ugen
in_ Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"BufCombC" [Ugen
buf, Ugen
in_, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer based comb delay line with linear interpolation.

 BufCombL [AudioRate] buf=0 in=0 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
bufCombL :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufCombL :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufCombL Ugen
buf Ugen
in_ Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"BufCombL" [Ugen
buf, Ugen
in_, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer based comb delay line with no interpolation.

 BufCombN [AudioRate] buf=0 in=0 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
bufCombN :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufCombN :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
bufCombN Ugen
buf Ugen
in_ Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"BufCombN" [Ugen
buf, Ugen
in_, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer based simple delay line with cubic interpolation.

 BufDelayC [ControlRate,AudioRate] buf=0 in=0 delaytime=0.2;    FILTER: TRUE
-}
bufDelayC :: Ugen -> Ugen -> Ugen -> Ugen
bufDelayC :: Ugen -> Ugen -> Ugen -> Ugen
bufDelayC Ugen
buf Ugen
in_ Ugen
delaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"BufDelayC" [Ugen
buf, Ugen
in_, Ugen
delaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer based simple delay line with linear interpolation.

 BufDelayL [ControlRate,AudioRate] buf=0 in=0 delaytime=0.2;    FILTER: TRUE
-}
bufDelayL :: Ugen -> Ugen -> Ugen -> Ugen
bufDelayL :: Ugen -> Ugen -> Ugen -> Ugen
bufDelayL Ugen
buf Ugen
in_ Ugen
delaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"BufDelayL" [Ugen
buf, Ugen
in_, Ugen
delaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer based simple delay line with no interpolation.

 BufDelayN [ControlRate,AudioRate] buf=0 in=0 delaytime=0.2;    FILTER: TRUE
-}
bufDelayN :: Ugen -> Ugen -> Ugen -> Ugen
bufDelayN :: Ugen -> Ugen -> Ugen -> Ugen
bufDelayN Ugen
buf Ugen
in_ Ugen
delaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"BufDelayN" [Ugen
buf, Ugen
in_, Ugen
delaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Current duration of soundfile in buffer.

 BufDur [InitialisationRate,ControlRate] bufnum=0
-}
bufDur :: Rate -> Ugen -> Ugen
bufDur :: Rate -> Ugen -> Ugen
bufDur Rate
rate Ugen
bufnum = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"BufDur" [Ugen
bufnum] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Current number of frames allocated in the buffer.

 BufFrames [InitialisationRate,ControlRate] bufnum=0
-}
bufFrames :: Rate -> Ugen -> Ugen
bufFrames :: Rate -> Ugen -> Ugen
bufFrames Rate
rate Ugen
bufnum = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"BufFrames" [Ugen
bufnum] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer rate scaling in respect to server samplerate.

 BufRateScale [InitialisationRate,ControlRate] bufnum=0
-}
bufRateScale :: Rate -> Ugen -> Ugen
bufRateScale :: Rate -> Ugen -> Ugen
bufRateScale Rate
rate Ugen
bufnum = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"BufRateScale" [Ugen
bufnum] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer reading oscillator.

 BufRd [ControlRate,AudioRate] bufnum=0 phase=0 loop=1 interpolation=2;    NC INPUT: True, ENUMERATION INPUTS: 2=Loop, 3=Interpolation
-}
bufRd :: Int -> Rate -> Ugen -> Ugen -> Loop Ugen -> Interpolation Ugen -> Ugen
bufRd :: Int
-> Rate -> Ugen -> Ugen -> Loop Ugen -> Interpolation Ugen -> Ugen
bufRd Int
numChannels Rate
rate Ugen
bufnum Ugen
phase Loop Ugen
loop Interpolation Ugen
interpolation = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"BufRd" [Ugen
bufnum, Ugen
phase, (Loop Ugen -> Ugen
forall t. Num t => Loop t -> t
from_loop Loop Ugen
loop), (Interpolation Ugen -> Ugen
forall t. Num t => Interpolation t -> t
from_interpolation Interpolation Ugen
interpolation)] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer sample rate.

 BufSampleRate [InitialisationRate,ControlRate] bufnum=0
-}
bufSampleRate :: Rate -> Ugen -> Ugen
bufSampleRate :: Rate -> Ugen -> Ugen
bufSampleRate Rate
rate Ugen
bufnum = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"BufSampleRate" [Ugen
bufnum] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Current number of samples in buffer.

 BufSamples [InitialisationRate,ControlRate] bufnum=0
-}
bufSamples :: Rate -> Ugen -> Ugen
bufSamples :: Rate -> Ugen -> Ugen
bufSamples Rate
rate Ugen
bufnum = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"BufSamples" [Ugen
bufnum] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Buffer writing oscillator.

 BufWr [ControlRate,AudioRate] bufnum=0 phase=0 loop=1 *inputArray=0;    MCE=1, FILTER: TRUE, REORDERS INPUTS: [3,0,1,2], ENUMERATION INPUTS: 2=Loop
-}
bufWr :: Ugen -> Ugen -> Loop Ugen -> Ugen -> Ugen
bufWr :: Ugen -> Ugen -> Loop Ugen -> Ugen -> Ugen
bufWr Ugen
bufnum Ugen
phase Loop Ugen
loop Ugen
inputArray = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
3]) String
"BufWr" [Ugen
bufnum, Ugen
phase, (Loop Ugen -> Ugen
forall t. Num t => Loop t -> t
from_loop Loop Ugen
loop)] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
inputArray]) Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Chorusing wavetable oscillator.

 COsc [ControlRate,AudioRate] bufnum=0 freq=440 beats=0.5
-}
cOsc :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
cOsc :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
cOsc Rate
rate Ugen
bufnum Ugen
freq Ugen
beats = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"COsc" [Ugen
bufnum, Ugen
freq, Ugen
beats] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Test for infinity, not-a-number, and denormals

 CheckBadValues [ControlRate,AudioRate] in=0 id=0 post=2;    FILTER: TRUE
-}
checkBadValues :: Ugen -> Ugen -> Ugen -> Ugen
checkBadValues :: Ugen -> Ugen -> Ugen -> Ugen
checkBadValues Ugen
in_ Ugen
id_ Ugen
post = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"CheckBadValues" [Ugen
in_, Ugen
id_, Ugen
post] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Clip a signal outside given thresholds.

 Clip [InitialisationRate,ControlRate,AudioRate] in=0 lo=0 hi=1;    FILTER: TRUE
-}
clip :: Ugen -> Ugen -> Ugen -> Ugen
clip :: Ugen -> Ugen -> Ugen -> Ugen
clip Ugen
in_ Ugen
lo Ugen
hi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Clip" [Ugen
in_, Ugen
lo, Ugen
hi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Clip Noise.

 ClipNoise [ControlRate,AudioRate] ;    NONDET
-}
clipNoiseId :: ID a => a -> Rate -> Ugen
clipNoiseId :: forall a. ID a => a -> Rate -> Ugen
clipNoiseId a
z Rate
rate = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"ClipNoise" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of ClipNoise.
clipNoiseM :: Uid m => Rate -> m Ugen
clipNoiseM :: forall (m :: * -> *). Uid m => Rate -> m Ugen
clipNoiseM = (Int -> Rate -> Ugen) -> Fn1 Rate (m Ugen)
forall (m :: * -> *) a b. Uid m => (Int -> Fn1 a b) -> Fn1 a (m b)
liftUid1 Int -> Rate -> Ugen
forall a. ID a => a -> Rate -> Ugen
clipNoiseId

-- | Unsafe variant of ClipNoise.
clipNoise :: Rate -> Ugen
clipNoise :: Rate -> Ugen
clipNoise = (Rate -> IO Ugen) -> Rate -> Ugen
forall a r. (a -> IO r) -> a -> r
liftUnsafe1 Rate -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> m Ugen
clipNoiseM

{- | Statistical gate.

 CoinGate [ControlRate,AudioRate] prob=0 in=0;    FILTER: TRUE, NONDET
-}
coinGateId :: ID a => a -> Ugen -> Ugen -> Ugen
coinGateId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
coinGateId a
z Ugen
prob Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"CoinGate" [Ugen
prob, Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of CoinGate.
coinGateM :: Uid m => Ugen -> Ugen -> m Ugen
coinGateM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
coinGateM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
coinGateId

-- | Unsafe variant of CoinGate.
coinGate :: Ugen -> Ugen -> Ugen
coinGate :: Ugen -> Ugen -> Ugen
coinGate = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
coinGateM

{- | Comb delay line with cubic interpolation.

 CombC [ControlRate,AudioRate] in=0 maxdelaytime=0.2 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
combC :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
combC :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
combC Ugen
in_ Ugen
maxdelaytime Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"CombC" [Ugen
in_, Ugen
maxdelaytime, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Comb delay line with linear interpolation.

 CombL [ControlRate,AudioRate] in=0 maxdelaytime=0.2 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
combL :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
combL :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
combL Ugen
in_ Ugen
maxdelaytime Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"CombL" [Ugen
in_, Ugen
maxdelaytime, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Comb delay line with no interpolation.

 CombN [ControlRate,AudioRate] in=0 maxdelaytime=0.2 delaytime=0.2 decaytime=1;    FILTER: TRUE
-}
combN :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
combN :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
combN Ugen
in_ Ugen
maxdelaytime Ugen
delaytime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"CombN" [Ugen
in_, Ugen
maxdelaytime, Ugen
delaytime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Compressor, expander, limiter, gate, ducker

 Compander [AudioRate] in=0 control=0 thresh=0.5 slopeBelow=1 slopeAbove=1 clampTime=0.01 relaxTime=0.1;    FILTER: TRUE
-}
compander :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
compander :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
compander Ugen
in_ Ugen
control_ Ugen
thresh Ugen
slopeBelow Ugen
slopeAbove Ugen
clampTime Ugen
relaxTime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Compander" [Ugen
in_, Ugen
control_, Ugen
thresh, Ugen
slopeBelow, Ugen
slopeAbove, Ugen
clampTime, Ugen
relaxTime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Compressor, expander, limiter, gate, ducker.

 CompanderD [AudioRate] in=0 thresh=0.5 slopeBelow=1 slopeAbove=1 clampTime=0.01 relaxTime=0.01
-}
companderD :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
companderD :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
companderD Rate
rate Ugen
in_ Ugen
thresh Ugen
slopeBelow Ugen
slopeAbove Ugen
clampTime Ugen
relaxTime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"CompanderD" [Ugen
in_, Ugen
thresh, Ugen
slopeBelow, Ugen
slopeAbove, Ugen
clampTime, Ugen
relaxTime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Duration of one block

 ControlDur [InitialisationRate]
-}
controlDur :: Ugen
controlDur :: Ugen
controlDur = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"ControlDur" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Server control rate.

 ControlRate [InitialisationRate]
-}
controlRate :: Ugen
controlRate :: Ugen
controlRate = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"ControlRate" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Real-time convolver.

 Convolution [AudioRate] in=0 kernel=0 framesize=512
-}
convolution :: Ugen -> Ugen -> Ugen -> Ugen
convolution :: Ugen -> Ugen -> Ugen -> Ugen
convolution Ugen
in_ Ugen
kernel Ugen
framesize = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"Convolution" [Ugen
in_, Ugen
kernel, Ugen
framesize] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Real-time fixed kernel convolver.

 Convolution2 [AudioRate] in=0 kernel=0 trigger=0 framesize=2048
-}
convolution2 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
convolution2 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
convolution2 Ugen
in_ Ugen
kernel Ugen
trigger Ugen
framesize = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"Convolution2" [Ugen
in_, Ugen
kernel, Ugen
trigger, Ugen
framesize] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Real-time convolver with linear interpolation

 Convolution2L [AudioRate] in=0 kernel=0 trigger=0 framesize=2048 crossfade=1
-}
convolution2L :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
convolution2L :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
convolution2L Rate
rate Ugen
in_ Ugen
kernel Ugen
trigger Ugen
framesize Ugen
crossfade = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Convolution2L" [Ugen
in_, Ugen
kernel, Ugen
trigger, Ugen
framesize, Ugen
crossfade] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Time based convolver.

 Convolution3 [ControlRate,AudioRate] in=0 kernel=0 trigger=0 framesize=2048
-}
convolution3 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
convolution3 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
convolution3 Rate
rate Ugen
in_ Ugen
kernel Ugen
trigger Ugen
framesize = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Convolution3" [Ugen
in_, Ugen
kernel, Ugen
trigger, Ugen
framesize] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Chaotic noise function.

 Crackle [ControlRate,AudioRate] chaosParam=1.5
-}
crackle :: Rate -> Ugen -> Ugen
crackle :: Rate -> Ugen -> Ugen
crackle Rate
rate Ugen
chaosParam = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Crackle" [Ugen
chaosParam] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Cusp map chaotic generator

 CuspL [AudioRate] freq=22050 a=1 b=1.9 xi=0
-}
cuspL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
cuspL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
cuspL Rate
rate Ugen
freq Ugen
a Ugen
b Ugen
xi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"CuspL" [Ugen
freq, Ugen
a, Ugen
b, Ugen
xi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Cusp map chaotic generator

 CuspN [AudioRate] freq=22050 a=1 b=1.9 xi=0
-}
cuspN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
cuspN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
cuspN Rate
rate Ugen
freq Ugen
a Ugen
b Ugen
xi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"CuspN" [Ugen
freq, Ugen
a, Ugen
b, Ugen
xi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Create a constant amplitude signal

 DC [ControlRate,AudioRate] in=0
-}
dc :: Rate -> Ugen -> Ugen
dc :: Rate -> Ugen -> Ugen
dc Rate
rate Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"DC" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Demand rate brownian movement generator.

 Dbrown [DemandRate] length=100000000 lo=0 hi=1 step=0.01;    REORDERS INPUTS: [1,2,3,0], DEMAND/NONDET
-}
dbrownId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dbrownId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dbrownId a
z Ugen
length_ Ugen
lo Ugen
hi Ugen
step = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dbrown" [Ugen
length_, Ugen
lo, Ugen
hi, Ugen
step] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dbrown.
dbrownM :: Uid m => Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
dbrownM :: forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
dbrownM = (Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn4 Ugen Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d e.
Uid m =>
(Int -> Fn4 a b c d e) -> Fn4 a b c d (m e)
liftUid4 Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dbrownId

-- | Unsafe variant of Dbrown.
dbrown :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dbrown :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dbrown = (Ugen -> Ugen -> Ugen -> Ugen -> IO Ugen)
-> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c d r.
(a -> b -> c -> d -> IO r) -> a -> b -> c -> d -> r
liftUnsafe4 Ugen -> Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
dbrownM

{- | Buffer read demand ugen

 Dbufrd [DemandRate] bufnum=0 phase=0 loop=1;    ENUMERATION INPUTS: 2=Loop, DEMAND/NONDET
-}
dbufrdId :: ID a => a -> Ugen -> Ugen -> Loop Ugen -> Ugen
dbufrdId :: forall a. ID a => a -> Ugen -> Ugen -> Loop Ugen -> Ugen
dbufrdId a
z Ugen
bufnum Ugen
phase Loop Ugen
loop = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dbufrd" [Ugen
bufnum, Ugen
phase, (Loop Ugen -> Ugen
forall t. Num t => Loop t -> t
from_loop Loop Ugen
loop)] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dbufrd.
dbufrdM :: Uid m => Ugen -> Ugen -> Loop Ugen -> m Ugen
dbufrdM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Loop Ugen -> m Ugen
dbufrdM = (Int -> Ugen -> Ugen -> Loop Ugen -> Ugen)
-> Fn3 Ugen Ugen (Loop Ugen) (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Loop Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Loop Ugen -> Ugen
dbufrdId

-- | Unsafe variant of Dbufrd.
dbufrd :: Ugen -> Ugen -> Loop Ugen -> Ugen
dbufrd :: Ugen -> Ugen -> Loop Ugen -> Ugen
dbufrd = (Ugen -> Ugen -> Loop Ugen -> IO Ugen)
-> Ugen -> Ugen -> Loop Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Loop Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Loop Ugen -> m Ugen
dbufrdM

{- | Buffer write demand ugen

 Dbufwr [DemandRate] bufnum=0 phase=0 input=0 loop=1;    REORDERS INPUTS: [2,0,1,3], ENUMERATION INPUTS: 3=Loop, DEMAND/NONDET
-}
dbufwrId :: ID a => a -> Ugen -> Ugen -> Ugen -> Loop Ugen -> Ugen
dbufwrId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Loop Ugen -> Ugen
dbufwrId a
z Ugen
bufnum Ugen
phase Ugen
input Loop Ugen
loop = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dbufwr" [Ugen
bufnum, Ugen
phase, Ugen
input, (Loop Ugen -> Ugen
forall t. Num t => Loop t -> t
from_loop Loop Ugen
loop)] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dbufwr.
dbufwrM :: Uid m => Ugen -> Ugen -> Ugen -> Loop Ugen -> m Ugen
dbufwrM :: forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Loop Ugen -> m Ugen
dbufwrM = (Int -> Ugen -> Ugen -> Ugen -> Loop Ugen -> Ugen)
-> Fn4 Ugen Ugen Ugen (Loop Ugen) (m Ugen)
forall (m :: * -> *) a b c d e.
Uid m =>
(Int -> Fn4 a b c d e) -> Fn4 a b c d (m e)
liftUid4 Int -> Ugen -> Ugen -> Ugen -> Loop Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Loop Ugen -> Ugen
dbufwrId

-- | Unsafe variant of Dbufwr.
dbufwr :: Ugen -> Ugen -> Ugen -> Loop Ugen -> Ugen
dbufwr :: Ugen -> Ugen -> Ugen -> Loop Ugen -> Ugen
dbufwr = (Ugen -> Ugen -> Ugen -> Loop Ugen -> IO Ugen)
-> Ugen -> Ugen -> Ugen -> Loop Ugen -> Ugen
forall a b c d r.
(a -> b -> c -> d -> IO r) -> a -> b -> c -> d -> r
liftUnsafe4 Ugen -> Ugen -> Ugen -> Loop Ugen -> IO Ugen
forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Loop Ugen -> m Ugen
dbufwrM

{- | Constrain a demand-rate stream to a given sum

 Dconst [DemandRate] sum=0 in=0 tolerance=0.001;    DEMAND/NONDET
-}
dconstId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dconstId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dconstId a
z Ugen
sum_ Ugen
in_ Ugen
tolerance = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dconst" [Ugen
sum_, Ugen
in_, Ugen
tolerance] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dconst.
dconstM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dconstM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dconstM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dconstId

-- | Unsafe variant of Dconst.
dconst :: Ugen -> Ugen -> Ugen -> Ugen
dconst :: Ugen -> Ugen -> Ugen -> Ugen
dconst = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dconstM

{- | Exponential decay

 Decay [ControlRate,AudioRate] in=0 decayTime=1;    FILTER: TRUE
-}
decay :: Ugen -> Ugen -> Ugen
decay :: Ugen -> Ugen -> Ugen
decay Ugen
in_ Ugen
decayTime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Decay" [Ugen
in_, Ugen
decayTime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Exponential decay

 Decay2 [ControlRate,AudioRate] in=0 attackTime=0.01 decayTime=1;    FILTER: TRUE
-}
decay2 :: Ugen -> Ugen -> Ugen -> Ugen
decay2 :: Ugen -> Ugen -> Ugen -> Ugen
decay2 Ugen
in_ Ugen
attackTime Ugen
decayTime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Decay2" [Ugen
in_, Ugen
attackTime, Ugen
decayTime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | 2D Ambisonic B-format decoder.

 DecodeB2 [ControlRate,AudioRate] w=0 x=0 y=0 orientation=0.5;    NC INPUT: True, FILTER: TRUE
-}
decodeB2 :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
decodeB2 :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
decodeB2 Int
numChannels Ugen
w Ugen
x Ugen
y Ugen
orientation = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1, Int
2]) String
"DecodeB2" [Ugen
w, Ugen
x, Ugen
y, Ugen
orientation] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Convert signal to modal pitch.

 DegreeToKey [ControlRate,AudioRate] bufnum=0 in=0 octave=12;    FILTER: TRUE
-}
degreeToKey :: Ugen -> Ugen -> Ugen -> Ugen
degreeToKey :: Ugen -> Ugen -> Ugen -> Ugen
degreeToKey Ugen
bufnum Ugen
in_ Ugen
octave = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"DegreeToKey" [Ugen
bufnum, Ugen
in_, Ugen
octave] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Tap a delay line from a DelTapWr Ugen

 DelTapRd [ControlRate,AudioRate] buffer=0 phase=0 delTime=0 interp=1;    FILTER: TRUE
-}
delTapRd :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
delTapRd :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
delTapRd Ugen
buffer Ugen
phase Ugen
delTime Ugen
interp = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"DelTapRd" [Ugen
buffer, Ugen
phase, Ugen
delTime, Ugen
interp] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Write to a buffer for a DelTapRd Ugen

 DelTapWr [ControlRate,AudioRate] buffer=0 in=0;    FILTER: TRUE
-}
delTapWr :: Ugen -> Ugen -> Ugen
delTapWr :: Ugen -> Ugen -> Ugen
delTapWr Ugen
buffer Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"DelTapWr" [Ugen
buffer, Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Single sample delay.

 Delay1 [ControlRate,AudioRate] in=0;    FILTER: TRUE
-}
delay1 :: Ugen -> Ugen
delay1 :: Ugen -> Ugen
delay1 Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Delay1" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Two sample delay.

 Delay2 [ControlRate,AudioRate] in=0;    FILTER: TRUE
-}
delay2 :: Ugen -> Ugen
delay2 :: Ugen -> Ugen
delay2 Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Delay2" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Simple delay line with cubic interpolation.

 DelayC [ControlRate,AudioRate] in=0 maxdelaytime=0.2 delaytime=0.2;    FILTER: TRUE
-}
delayC :: Ugen -> Ugen -> Ugen -> Ugen
delayC :: Ugen -> Ugen -> Ugen -> Ugen
delayC Ugen
in_ Ugen
maxdelaytime Ugen
delaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"DelayC" [Ugen
in_, Ugen
maxdelaytime, Ugen
delaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Simple delay line with linear interpolation.

 DelayL [ControlRate,AudioRate] in=0 maxdelaytime=0.2 delaytime=0.2;    FILTER: TRUE
-}
delayL :: Ugen -> Ugen -> Ugen -> Ugen
delayL :: Ugen -> Ugen -> Ugen -> Ugen
delayL Ugen
in_ Ugen
maxdelaytime Ugen
delaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"DelayL" [Ugen
in_, Ugen
maxdelaytime, Ugen
delaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Simple delay line with no interpolation.

 DelayN [ControlRate,AudioRate] in=0 maxdelaytime=0.2 delaytime=0.2;    FILTER: TRUE
-}
delayN :: Ugen -> Ugen -> Ugen -> Ugen
delayN :: Ugen -> Ugen -> Ugen -> Ugen
delayN Ugen
in_ Ugen
maxdelaytime Ugen
delaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"DelayN" [Ugen
in_, Ugen
maxdelaytime, Ugen
delaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Demand results from demand rate Ugens.

 Demand [ControlRate,AudioRate] trig=0 reset=0 *demandUgens=0;    MCE=1, FILTER: TRUE
-}
demand :: Ugen -> Ugen -> Ugen -> Ugen
demand :: Ugen -> Ugen -> Ugen -> Ugen
demand Ugen
trig_ Ugen
reset Ugen
demandUgens = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Demand" [Ugen
trig_, Ugen
reset] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
demandUgens]) ([Ugen] -> Int
forall a. [a] -> Int
forall (t :: * -> *) a. Foldable t => t a -> Int
length (Ugen -> [Ugen]
mceChannels Ugen
demandUgens) Int -> Int -> Int
forall a. Num a => a -> a -> a
+ Int
0) (Int -> Special
Special Int
0) UgenId
NoId

{- | Demand rate envelope generator

 DemandEnvGen [ControlRate,AudioRate] level=0 dur=0 shape=1 curve=0 gate=1 reset=1 levelScale=1 levelBias=0 timeScale=1 doneAction=0;    ENUMERATION INPUTS: 9=DoneAction
-}
demandEnvGen :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> DoneAction Ugen -> Ugen
demandEnvGen :: Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> DoneAction Ugen
-> Ugen
demandEnvGen Rate
rate Ugen
level Ugen
dur Ugen
shape Ugen
curve Ugen
gate_ Ugen
reset Ugen
levelScale Ugen
levelBias Ugen
timeScale DoneAction Ugen
doneAction = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"DemandEnvGen" [Ugen
level, Ugen
dur, Ugen
shape, Ugen
curve, Ugen
gate_, Ugen
reset, Ugen
levelScale, Ugen
levelBias, Ugen
timeScale, (DoneAction Ugen -> Ugen
forall t. Num t => DoneAction t -> t
from_done_action DoneAction Ugen
doneAction)] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Search a buffer for a value

 DetectIndex [ControlRate,AudioRate] bufnum=0 in=0;    FILTER: TRUE
-}
detectIndex :: Ugen -> Ugen -> Ugen
detectIndex :: Ugen -> Ugen -> Ugen
detectIndex Ugen
bufnum Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"DetectIndex" [Ugen
bufnum, Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Detect when input falls below an amplitude threshold

 DetectSilence [ControlRate,AudioRate] in=0 amp=0.0001 time=0.1 doneAction=0;    FILTER: TRUE, ENUMERATION INPUTS: 3=DoneAction
-}
detectSilence :: Ugen -> Ugen -> Ugen -> DoneAction Ugen -> Ugen
detectSilence :: Ugen -> Ugen -> Ugen -> DoneAction Ugen -> Ugen
detectSilence Ugen
in_ Ugen
amp Ugen
time DoneAction Ugen
doneAction = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"DetectSilence" [Ugen
in_, Ugen
amp, Ugen
time, (DoneAction Ugen -> Ugen
forall t. Num t => DoneAction t -> t
from_done_action DoneAction Ugen
doneAction)] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Demand rate geometric series Ugen.

 Dgeom [DemandRate] length=100000000 start=1 grow=2;    REORDERS INPUTS: [1,2,0], DEMAND/NONDET
-}
dgeomId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dgeomId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dgeomId a
z Ugen
length_ Ugen
start Ugen
grow = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dgeom" [Ugen
length_, Ugen
start, Ugen
grow] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dgeom.
dgeomM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dgeomM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dgeomM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dgeomId

-- | Unsafe variant of Dgeom.
dgeom :: Ugen -> Ugen -> Ugen -> Ugen
dgeom :: Ugen -> Ugen -> Ugen -> Ugen
dgeom = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dgeomM

{- | Demand rate brownian movement generator.

 Dibrown [DemandRate] length=100000000 lo=0 hi=1 step=0.01;    REORDERS INPUTS: [1,2,3,0], DEMAND/NONDET
-}
dibrownId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dibrownId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dibrownId a
z Ugen
length_ Ugen
lo Ugen
hi Ugen
step = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dibrown" [Ugen
length_, Ugen
lo, Ugen
hi, Ugen
step] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dibrown.
dibrownM :: Uid m => Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
dibrownM :: forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
dibrownM = (Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn4 Ugen Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d e.
Uid m =>
(Int -> Fn4 a b c d e) -> Fn4 a b c d (m e)
liftUid4 Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dibrownId

-- | Unsafe variant of Dibrown.
dibrown :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dibrown :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dibrown = (Ugen -> Ugen -> Ugen -> Ugen -> IO Ugen)
-> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c d r.
(a -> b -> c -> d -> IO r) -> a -> b -> c -> d -> r
liftUnsafe4 Ugen -> Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
dibrownM

{- | Stream in audio from a file.

 DiskIn [AudioRate] bufnum=0 loop=0;    NC INPUT: True, ENUMERATION INPUTS: 1=Loop
-}
diskIn :: Int -> Ugen -> Loop Ugen -> Ugen
diskIn :: Int -> Ugen -> Loop Ugen -> Ugen
diskIn Int
numChannels Ugen
bufnum Loop Ugen
loop = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"DiskIn" [Ugen
bufnum, (Loop Ugen -> Ugen
forall t. Num t => Loop t -> t
from_loop Loop Ugen
loop)] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Record to a soundfile to disk.

 DiskOut [AudioRate] bufnum=0 *channelsArray=0;    MCE=1
-}
diskOut :: Ugen -> Ugen -> Ugen
diskOut :: Ugen -> Ugen -> Ugen
diskOut Ugen
bufnum Ugen
input = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"DiskOut" [Ugen
bufnum] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
input]) Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Demand rate white noise random generator.

 Diwhite [DemandRate] length=100000000 lo=0 hi=1;    REORDERS INPUTS: [1,2,0], DEMAND/NONDET
-}
diwhiteId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
diwhiteId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
diwhiteId a
z Ugen
length_ Ugen
lo Ugen
hi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Diwhite" [Ugen
length_, Ugen
lo, Ugen
hi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Diwhite.
diwhiteM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
diwhiteM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
diwhiteM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
diwhiteId

-- | Unsafe variant of Diwhite.
diwhite :: Ugen -> Ugen -> Ugen -> Ugen
diwhite :: Ugen -> Ugen -> Ugen -> Ugen
diwhite = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
diwhiteM

{- | Monitors another Ugen to see when it is finished

 Done [ControlRate] src=0
-}
done :: Ugen -> Ugen
done :: Ugen -> Ugen
done Ugen
src = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"Done" [Ugen
src] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Print the current output value of a demand rate Ugen

 Dpoll [DemandRate] in=0 label=0 run=1 trigid=-1;    DEMAND/NONDET
-}
dpollId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dpollId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dpollId a
z Ugen
in_ Ugen
label_ Ugen
run Ugen
trigid = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dpoll" [Ugen
in_, Ugen
label_, Ugen
run, Ugen
trigid] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dpoll.
dpollM :: Uid m => Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
dpollM :: forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
dpollM = (Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn4 Ugen Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d e.
Uid m =>
(Int -> Fn4 a b c d e) -> Fn4 a b c d (m e)
liftUid4 Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dpollId

-- | Unsafe variant of Dpoll.
dpoll :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dpoll :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
dpoll = (Ugen -> Ugen -> Ugen -> Ugen -> IO Ugen)
-> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c d r.
(a -> b -> c -> d -> IO r) -> a -> b -> c -> d -> r
liftUnsafe4 Ugen -> Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
dpollM

{- | Demand rate random sequence generator.

 Drand [DemandRate] repeats=1 *list=0;    MCE=1, REORDERS INPUTS: [1,0], DEMAND/NONDET
-}
drandId :: ID a => a -> Ugen -> Ugen -> Ugen
drandId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
drandId a
z Ugen
repeats Ugen
list_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Drand" [Ugen
repeats] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
list_]) Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Drand.
drandM :: Uid m => Ugen -> Ugen -> m Ugen
drandM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
drandM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
drandId

-- | Unsafe variant of Drand.
drand :: Ugen -> Ugen -> Ugen
drand :: Ugen -> Ugen -> Ugen
drand = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
drandM

{- | demand rate reset

 Dreset [DemandRate] in=0 reset=0;    DEMAND/NONDET
-}
dresetId :: ID a => a -> Ugen -> Ugen -> Ugen
dresetId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
dresetId a
z Ugen
in_ Ugen
reset = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dreset" [Ugen
in_, Ugen
reset] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dreset.
dresetM :: Uid m => Ugen -> Ugen -> m Ugen
dresetM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dresetM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
dresetId

-- | Unsafe variant of Dreset.
dreset :: Ugen -> Ugen -> Ugen
dreset :: Ugen -> Ugen -> Ugen
dreset = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dresetM

{- | Demand rate sequence generator.

 Dseq [DemandRate] repeats=1 *list=0;    MCE=1, REORDERS INPUTS: [1,0], DEMAND/NONDET
-}
dseqId :: ID a => a -> Ugen -> Ugen -> Ugen
dseqId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
dseqId a
z Ugen
repeats Ugen
list_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dseq" [Ugen
repeats] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
list_]) Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dseq.
dseqM :: Uid m => Ugen -> Ugen -> m Ugen
dseqM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dseqM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
dseqId

-- | Unsafe variant of Dseq.
dseq :: Ugen -> Ugen -> Ugen
dseq :: Ugen -> Ugen -> Ugen
dseq = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dseqM

{- | Demand rate sequence generator.

 Dser [DemandRate] repeats=1 *list=0;    MCE=1, REORDERS INPUTS: [1,0], DEMAND/NONDET
-}
dserId :: ID a => a -> Ugen -> Ugen -> Ugen
dserId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
dserId a
z Ugen
repeats Ugen
list_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dser" [Ugen
repeats] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
list_]) Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dser.
dserM :: Uid m => Ugen -> Ugen -> m Ugen
dserM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dserM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
dserId

-- | Unsafe variant of Dser.
dser :: Ugen -> Ugen -> Ugen
dser :: Ugen -> Ugen -> Ugen
dser = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dserM

{- | Demand rate arithmetic series Ugen.

 Dseries [DemandRate] length=100000000 start=1 step=1;    REORDERS INPUTS: [1,2,0], DEMAND/NONDET
-}
dseriesId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dseriesId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dseriesId a
z Ugen
length_ Ugen
start Ugen
step = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dseries" [Ugen
length_, Ugen
start, Ugen
step] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dseries.
dseriesM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dseriesM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dseriesM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dseriesId

-- | Unsafe variant of Dseries.
dseries :: Ugen -> Ugen -> Ugen -> Ugen
dseries :: Ugen -> Ugen -> Ugen -> Ugen
dseries = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dseriesM

{- | Demand rate random sequence generator

 Dshuf [DemandRate] repeats=1 *list=0;    MCE=1, REORDERS INPUTS: [1,0], DEMAND/NONDET
-}
dshufId :: ID a => a -> Ugen -> Ugen -> Ugen
dshufId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
dshufId a
z Ugen
repeats Ugen
list_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dshuf" [Ugen
repeats] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
list_]) Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dshuf.
dshufM :: Uid m => Ugen -> Ugen -> m Ugen
dshufM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dshufM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
dshufId

-- | Unsafe variant of Dshuf.
dshuf :: Ugen -> Ugen -> Ugen
dshuf :: Ugen -> Ugen -> Ugen
dshuf = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dshufM

{- | Demand rate input replicator

 Dstutter [DemandRate] n=0 in=0;    DEMAND/NONDET
-}
dstutterId :: ID a => a -> Ugen -> Ugen -> Ugen
dstutterId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
dstutterId a
z Ugen
n Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dstutter" [Ugen
n, Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dstutter.
dstutterM :: Uid m => Ugen -> Ugen -> m Ugen
dstutterM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dstutterM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
dstutterId

-- | Unsafe variant of Dstutter.
dstutter :: Ugen -> Ugen -> Ugen
dstutter :: Ugen -> Ugen -> Ugen
dstutter = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dstutterM

{- | Demand rate generator for embedding different inputs

 Dswitch [DemandRate] index=0 *list=0;    MCE=1, REORDERS INPUTS: [1,0], DEMAND/NONDET
-}
dswitchId :: ID a => a -> Ugen -> Ugen -> Ugen
dswitchId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
dswitchId a
z Ugen
index_ Ugen
list_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dswitch" [Ugen
index_] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
list_]) Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dswitch.
dswitchM :: Uid m => Ugen -> Ugen -> m Ugen
dswitchM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dswitchM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
dswitchId

-- | Unsafe variant of Dswitch.
dswitch :: Ugen -> Ugen -> Ugen
dswitch :: Ugen -> Ugen -> Ugen
dswitch = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dswitchM

{- | Demand rate generator for switching between inputs.

 Dswitch1 [DemandRate] index=0 *list=0;    MCE=1, REORDERS INPUTS: [1,0], DEMAND/NONDET
-}
dswitch1Id :: ID a => a -> Ugen -> Ugen -> Ugen
dswitch1Id :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
dswitch1Id a
z Ugen
index_ Ugen
list_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dswitch1" [Ugen
index_] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
list_]) Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dswitch1.
dswitch1M :: Uid m => Ugen -> Ugen -> m Ugen
dswitch1M :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dswitch1M = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
dswitch1Id

-- | Unsafe variant of Dswitch1.
dswitch1 :: Ugen -> Ugen -> Ugen
dswitch1 :: Ugen -> Ugen -> Ugen
dswitch1 = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dswitch1M

{- | Return the same unique series of values for several demand streams

 Dunique [DemandRate] source=0 maxBufferSize=1024 protected=1;    DEMAND/NONDET
-}
duniqueId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
duniqueId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
duniqueId a
z Ugen
source Ugen
maxBufferSize Ugen
protected = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dunique" [Ugen
source, Ugen
maxBufferSize, Ugen
protected] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dunique.
duniqueM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
duniqueM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
duniqueM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
duniqueId

-- | Unsafe variant of Dunique.
dunique :: Ugen -> Ugen -> Ugen -> Ugen
dunique :: Ugen -> Ugen -> Ugen -> Ugen
dunique = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
duniqueM

{- | Random impulses.

 Dust [ControlRate,AudioRate] density=0;    NONDET
-}
dustId :: ID a => a -> Rate -> Ugen -> Ugen
dustId :: forall a. ID a => a -> Rate -> Ugen -> Ugen
dustId a
z Rate
rate Ugen
density = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Dust" [Ugen
density] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dust.
dustM :: Uid m => Rate -> Ugen -> m Ugen
dustM :: forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
dustM = (Int -> Rate -> Ugen -> Ugen) -> Fn2 Rate Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Rate -> Ugen -> Ugen
forall a. ID a => a -> Rate -> Ugen -> Ugen
dustId

-- | Unsafe variant of Dust.
dust :: Rate -> Ugen -> Ugen
dust :: Rate -> Ugen -> Ugen
dust = (Rate -> Ugen -> IO Ugen) -> Rate -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Rate -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
dustM

{- | Random impulses.

 Dust2 [ControlRate,AudioRate] density=0;    NONDET
-}
dust2Id :: ID a => a -> Rate -> Ugen -> Ugen
dust2Id :: forall a. ID a => a -> Rate -> Ugen -> Ugen
dust2Id a
z Rate
rate Ugen
density = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Dust2" [Ugen
density] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dust2.
dust2M :: Uid m => Rate -> Ugen -> m Ugen
dust2M :: forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
dust2M = (Int -> Rate -> Ugen -> Ugen) -> Fn2 Rate Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Rate -> Ugen -> Ugen
forall a. ID a => a -> Rate -> Ugen -> Ugen
dust2Id

-- | Unsafe variant of Dust2.
dust2 :: Rate -> Ugen -> Ugen
dust2 :: Rate -> Ugen -> Ugen
dust2 = (Rate -> Ugen -> IO Ugen) -> Rate -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Rate -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
dust2M

{- | Demand results from demand rate Ugens.

 Duty [ControlRate,AudioRate] dur=1 reset=0 doneAction=0 level=1;    REORDERS INPUTS: [0,1,3,2], ENUMERATION INPUTS: 2=DoneAction
-}
duty :: Rate -> Ugen -> Ugen -> DoneAction Ugen -> Ugen -> Ugen
duty :: Rate -> Ugen -> Ugen -> DoneAction Ugen -> Ugen -> Ugen
duty Rate
rate Ugen
dur Ugen
reset DoneAction Ugen
doneAction Ugen
level = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Duty" [Ugen
dur, Ugen
reset, (DoneAction Ugen -> Ugen
forall t. Num t => DoneAction t -> t
from_done_action DoneAction Ugen
doneAction), Ugen
level] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Demand rate white noise random generator.

 Dwhite [DemandRate] length=100000000 lo=0 hi=1;    REORDERS INPUTS: [1,2,0], DEMAND/NONDET
-}
dwhiteId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dwhiteId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dwhiteId a
z Ugen
length_ Ugen
lo Ugen
hi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dwhite" [Ugen
length_, Ugen
lo, Ugen
hi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dwhite.
dwhiteM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dwhiteM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dwhiteM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dwhiteId

-- | Unsafe variant of Dwhite.
dwhite :: Ugen -> Ugen -> Ugen -> Ugen
dwhite :: Ugen -> Ugen -> Ugen -> Ugen
dwhite = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dwhiteM

{-
-- | Demand rate weighted random sequence generator
--
--  Dwrand [DemandRate] repeats=1 weights=0 *list=0;    MCE=1, REORDERS INPUTS: [2,1,0], DEMAND/NONDET
dwrandId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
dwrandId z repeats weights list_ = mkUgen Nothing [DemandRate] (Left DemandRate) "Dwrand" [repeats,weights] (Just [list_]) 1 (Special 0) (toUid z)

-- | Monad variant of Dwrand.
dwrandM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
dwrandM = liftUid3 dwrandId

-- | Unsafe variant of Dwrand.
dwrand ::  Ugen -> Ugen -> Ugen -> Ugen
dwrand = liftUnsafe3 dwrandM
-}

{- | Demand rate random sequence generator.

 Dxrand [DemandRate] repeats=1 *list=0;    MCE=1, REORDERS INPUTS: [1,0], DEMAND/NONDET
-}
dxrandId :: ID a => a -> Ugen -> Ugen -> Ugen
dxrandId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
dxrandId a
z Ugen
repeats Ugen
list_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
DemandRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
DemandRate) String
"Dxrand" [Ugen
repeats] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
list_]) Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Dxrand.
dxrandM :: Uid m => Ugen -> Ugen -> m Ugen
dxrandM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dxrandM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
dxrandId

-- | Unsafe variant of Dxrand.
dxrand :: Ugen -> Ugen -> Ugen
dxrand :: Ugen -> Ugen -> Ugen
dxrand = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
dxrandM

{- | Envelope generator

 EnvGen [ControlRate,AudioRate] gate=1 levelScale=1 levelBias=0 timeScale=1 doneAction=0 *envelope=0;    MCE=1, REORDERS INPUTS: [5,0,1,2,3,4], ENUMERATION INPUTS: 4=DoneAction, 5=Envelope
-}
envGen :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> DoneAction Ugen -> Envelope Ugen -> Ugen
envGen :: Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> DoneAction Ugen
-> Envelope Ugen
-> Ugen
envGen Rate
rate Ugen
gate_ Ugen
levelScale Ugen
levelBias Ugen
timeScale DoneAction Ugen
doneAction Envelope Ugen
envelope_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"EnvGen" [Ugen
gate_, Ugen
levelScale, Ugen
levelBias, Ugen
timeScale, (DoneAction Ugen -> Ugen
forall t. Num t => DoneAction t -> t
from_done_action DoneAction Ugen
doneAction)] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [(Envelope Ugen -> Ugen
envelope_to_ugen Envelope Ugen
envelope_)]) Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Exponential single random number generator.

 ExpRand [InitialisationRate] lo=0.01 hi=1;    NONDET
-}
expRandId :: ID a => a -> Ugen -> Ugen -> Ugen
expRandId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
expRandId a
z Ugen
lo Ugen
hi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"ExpRand" [Ugen
lo, Ugen
hi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of ExpRand.
expRandM :: Uid m => Ugen -> Ugen -> m Ugen
expRandM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
expRandM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
expRandId

-- | Unsafe variant of ExpRand.
expRand :: Ugen -> Ugen -> Ugen
expRand :: Ugen -> Ugen -> Ugen
expRand = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
expRandM

{- | Feedback sine with chaotic phase indexing

 FBSineC [AudioRate] freq=22050 im=1 fb=0.1 a=1.1 c=0.5 xi=0.1 yi=0.1
-}
fbSineC :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
fbSineC :: Rate
-> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
fbSineC Rate
rate Ugen
freq Ugen
im Ugen
fb Ugen
a Ugen
c Ugen
xi Ugen
yi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"FBSineC" [Ugen
freq, Ugen
im, Ugen
fb, Ugen
a, Ugen
c, Ugen
xi, Ugen
yi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Feedback sine with chaotic phase indexing

 FBSineL [AudioRate] freq=22050 im=1 fb=0.1 a=1.1 c=0.5 xi=0.1 yi=0.1
-}
fbSineL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
fbSineL :: Rate
-> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
fbSineL Rate
rate Ugen
freq Ugen
im Ugen
fb Ugen
a Ugen
c Ugen
xi Ugen
yi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"FBSineL" [Ugen
freq, Ugen
im, Ugen
fb, Ugen
a, Ugen
c, Ugen
xi, Ugen
yi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Feedback sine with chaotic phase indexing

 FBSineN [AudioRate] freq=22050 im=1 fb=0.1 a=1.1 c=0.5 xi=0.1 yi=0.1
-}
fbSineN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
fbSineN :: Rate
-> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
fbSineN Rate
rate Ugen
freq Ugen
im Ugen
fb Ugen
a Ugen
c Ugen
xi Ugen
yi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"FBSineN" [Ugen
freq, Ugen
im, Ugen
fb, Ugen
a, Ugen
c, Ugen
xi, Ugen
yi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Fast Fourier Transform

 FFT [ControlRate] buffer=0 in=0 hop=0.5 wintype=0 active=1 winsize=0
-}
fft :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
fft :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
fft Ugen
buffer Ugen
in_ Ugen
hop Ugen
wintype Ugen
active Ugen
winsize = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"FFT" [Ugen
buffer, Ugen
in_, Ugen
hop, Ugen
wintype, Ugen
active, Ugen
winsize] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | First order filter section.

 FOS [ControlRate,AudioRate] in=0 a0=0 a1=0 b1=0;    FILTER: TRUE
-}
fos :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
fos :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
fos Ugen
in_ Ugen
a0 Ugen
a1 Ugen
b1 = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"FOS" [Ugen
in_, Ugen
a0, Ugen
a1, Ugen
b1] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Fast sine oscillator.

 FSinOsc [ControlRate,AudioRate] freq=440 iphase=0
-}
fSinOsc :: Rate -> Ugen -> Ugen -> Ugen
fSinOsc :: Rate -> Ugen -> Ugen -> Ugen
fSinOsc Rate
rate Ugen
freq Ugen
iphase = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"FSinOsc" [Ugen
freq, Ugen
iphase] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Fold a signal outside given thresholds.

 Fold [InitialisationRate,ControlRate,AudioRate] in=0 lo=0 hi=1;    FILTER: TRUE
-}
fold :: Ugen -> Ugen -> Ugen -> Ugen
fold :: Ugen -> Ugen -> Ugen -> Ugen
fold Ugen
in_ Ugen
lo Ugen
hi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Fold" [Ugen
in_, Ugen
lo, Ugen
hi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Formant oscillator

 Formant [AudioRate] fundfreq=440 formfreq=1760 bwfreq=880
-}
formant :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
formant :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
formant Rate
rate Ugen
fundfreq Ugen
formfreq Ugen
bwfreq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Formant" [Ugen
fundfreq, Ugen
formfreq, Ugen
bwfreq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | FOF-like filter.

 Formlet [ControlRate,AudioRate] in=0 freq=440 attacktime=1 decaytime=1;    FILTER: TRUE
-}
formlet :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
formlet :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
formlet Ugen
in_ Ugen
freq Ugen
attacktime Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Formlet" [Ugen
in_, Ugen
freq, Ugen
attacktime, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | When triggered, frees a node.

 Free [ControlRate] trig=0 id=0;    FILTER: TRUE
-}
free :: Ugen -> Ugen -> Ugen
free :: Ugen -> Ugen -> Ugen
free Ugen
trig_ Ugen
id_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Free" [Ugen
trig_, Ugen
id_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | When triggered, free enclosing synth.

 FreeSelf [ControlRate] in=0
-}
freeSelf :: Ugen -> Ugen
freeSelf :: Ugen -> Ugen
freeSelf Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"FreeSelf" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Free the enclosing synth when a Ugen is finished

 FreeSelfWhenDone [ControlRate] src=0
-}
freeSelfWhenDone :: Ugen -> Ugen
freeSelfWhenDone :: Ugen -> Ugen
freeSelfWhenDone Ugen
src = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"FreeSelfWhenDone" [Ugen
src] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | A reverb

 FreeVerb [AudioRate] in=0 mix=0.33 room=0.5 damp=0.5;    FILTER: TRUE
-}
freeVerb :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
freeVerb :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
freeVerb Ugen
in_ Ugen
mix Ugen
room Ugen
damp = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"FreeVerb" [Ugen
in_, Ugen
mix, Ugen
room, Ugen
damp] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | A two-channel reverb

 FreeVerb2 [AudioRate] in=0 in2=0 mix=0.33 room=0.5 damp=0.5;    FILTER: TRUE
-}
freeVerb2 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
freeVerb2 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
freeVerb2 Ugen
in_ Ugen
in2 Ugen
mix Ugen
room Ugen
damp = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"FreeVerb2" [Ugen
in_, Ugen
in2, Ugen
mix, Ugen
room, Ugen
damp] Maybe [Ugen]
forall a. Maybe a
Nothing Int
2 (Int -> Special
Special Int
0) UgenId
NoId

{- | Frequency Shifter.

 FreqShift [AudioRate] in=0 freq=0 phase=0
-}
freqShift :: Ugen -> Ugen -> Ugen -> Ugen
freqShift :: Ugen -> Ugen -> Ugen -> Ugen
freqShift Ugen
in_ Ugen
freq Ugen
phase = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"FreqShift" [Ugen
in_, Ugen
freq, Ugen
phase] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | A two-channel reverb

 GVerb [AudioRate] in=0 roomsize=10 revtime=3 damping=0.5 inputbw=0.5 spread=15 drylevel=1 earlyreflevel=0.7 taillevel=0.5 maxroomsize=300;    FILTER: TRUE
-}
gVerb :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
gVerb :: Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
gVerb Ugen
in_ Ugen
roomsize Ugen
revtime Ugen
damping Ugen
inputbw Ugen
spread Ugen
drylevel Ugen
earlyreflevel Ugen
taillevel Ugen
maxroomsize = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"GVerb" [Ugen
in_, Ugen
roomsize, Ugen
revtime, Ugen
damping, Ugen
inputbw, Ugen
spread, Ugen
drylevel, Ugen
earlyreflevel, Ugen
taillevel, Ugen
maxroomsize] Maybe [Ugen]
forall a. Maybe a
Nothing Int
2 (Int -> Special
Special Int
0) UgenId
NoId

{- | Gate or hold.

 Gate [ControlRate,AudioRate] in=0 trig=0;    FILTER: TRUE
-}
gate :: Ugen -> Ugen -> Ugen
gate :: Ugen -> Ugen -> Ugen
gate Ugen
in_ Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Gate" [Ugen
in_, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Gingerbreadman map chaotic generator

 GbmanL [AudioRate] freq=22050 xi=1.2 yi=2.1
-}
gbmanL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
gbmanL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
gbmanL Rate
rate Ugen
freq Ugen
xi Ugen
yi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"GbmanL" [Ugen
freq, Ugen
xi, Ugen
yi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Gingerbreadman map chaotic generator

 GbmanN [AudioRate] freq=22050 xi=1.2 yi=2.1
-}
gbmanN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
gbmanN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
gbmanN Rate
rate Ugen
freq Ugen
xi Ugen
yi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"GbmanN" [Ugen
freq, Ugen
xi, Ugen
yi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Dynamic stochastic synthesis generator.

 Gendy1 [ControlRate,AudioRate] ampdist=1 durdist=1 adparam=1 ddparam=1 minfreq=440 maxfreq=660 ampscale=0.5 durscale=0.5 initCPs=12 knum=0;    NONDET
-}
gendy1Id :: ID a => a -> Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
gendy1Id :: forall a.
ID a =>
a
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
gendy1Id a
z Rate
rate Ugen
ampdist Ugen
durdist Ugen
adparam Ugen
ddparam Ugen
minfreq Ugen
maxfreq Ugen
ampscale Ugen
durscale Ugen
initCPs Ugen
knum = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Gendy1" [Ugen
ampdist, Ugen
durdist, Ugen
adparam, Ugen
ddparam, Ugen
minfreq, Ugen
maxfreq, Ugen
ampscale, Ugen
durscale, Ugen
initCPs, Ugen
knum] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Gendy1.
gendy1M :: Uid m => Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
gendy1M :: forall (m :: * -> *).
Uid m =>
Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> m Ugen
gendy1M = (Int
 -> Rate
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen)
-> Fn11
     Rate Ugen Ugen Ugen Ugen Ugen Ugen Ugen Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d e f g h i j k l.
Uid m =>
(Int -> Fn11 a b c d e f g h i j k l)
-> Fn11 a b c d e f g h i j k (m l)
liftUid11 Int
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
forall a.
ID a =>
a
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
gendy1Id

-- | Unsafe variant of Gendy1.
gendy1 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
gendy1 :: Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
gendy1 = (Rate
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> IO Ugen)
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
forall a b c d e f g h i j k r.
(a -> b -> c -> d -> e -> f -> g -> h -> i -> j -> k -> IO r)
-> a -> b -> c -> d -> e -> f -> g -> h -> i -> j -> k -> r
liftUnsafe11 Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> IO Ugen
forall (m :: * -> *).
Uid m =>
Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> m Ugen
gendy1M

{- | Dynamic stochastic synthesis generator.

 Gendy2 [ControlRate,AudioRate] ampdist=1 durdist=1 adparam=1 ddparam=1 minfreq=440 maxfreq=660 ampscale=0.5 durscale=0.5 initCPs=12 knum=0 a=1.17 c=0.31;    NONDET
-}
gendy2Id :: ID a => a -> Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
gendy2Id :: forall a.
ID a =>
a
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
gendy2Id a
z Rate
rate Ugen
ampdist Ugen
durdist Ugen
adparam Ugen
ddparam Ugen
minfreq Ugen
maxfreq Ugen
ampscale Ugen
durscale Ugen
initCPs Ugen
knum Ugen
a Ugen
c = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Gendy2" [Ugen
ampdist, Ugen
durdist, Ugen
adparam, Ugen
ddparam, Ugen
minfreq, Ugen
maxfreq, Ugen
ampscale, Ugen
durscale, Ugen
initCPs, Ugen
knum, Ugen
a, Ugen
c] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

{-
-- | Monad variant of Gendy2.
gendy2M :: Uid m => Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
gendy2M = liftUid13 gendy2Id

-- | Unsafe variant of Gendy2.
gendy2 ::  Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
gendy2 = liftUnsafe13 gendy2M
-}

{- | Dynamic stochastic synthesis generator.

 Gendy3 [ControlRate,AudioRate] ampdist=1 durdist=1 adparam=1 ddparam=1 freq=440 ampscale=0.5 durscale=0.5 initCPs=12 knum=0;    NONDET
-}
gendy3Id :: ID a => a -> Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
gendy3Id :: forall a.
ID a =>
a
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
gendy3Id a
z Rate
rate Ugen
ampdist Ugen
durdist Ugen
adparam Ugen
ddparam Ugen
freq Ugen
ampscale Ugen
durscale Ugen
initCPs Ugen
knum = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Gendy3" [Ugen
ampdist, Ugen
durdist, Ugen
adparam, Ugen
ddparam, Ugen
freq, Ugen
ampscale, Ugen
durscale, Ugen
initCPs, Ugen
knum] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Gendy3.
gendy3M :: Uid m => Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
gendy3M :: forall (m :: * -> *).
Uid m =>
Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> m Ugen
gendy3M = (Int
 -> Rate
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen)
-> Fn10 Rate Ugen Ugen Ugen Ugen Ugen Ugen Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d e f g h i j k.
Uid m =>
(Int -> Fn10 a b c d e f g h i j k)
-> Fn10 a b c d e f g h i j (m k)
liftUid10 Int
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
forall a.
ID a =>
a
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
gendy3Id

-- | Unsafe variant of Gendy3.
gendy3 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
gendy3 :: Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
gendy3 = (Rate
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> IO Ugen)
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
forall a b c d e f g h i j r.
(a -> b -> c -> d -> e -> f -> g -> h -> i -> j -> IO r)
-> a -> b -> c -> d -> e -> f -> g -> h -> i -> j -> r
liftUnsafe10 Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> IO Ugen
forall (m :: * -> *).
Uid m =>
Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> m Ugen
gendy3M

{- | Granular synthesis with sound stored in a buffer

 GrainBuf [AudioRate] trigger=0 dur=1 sndbuf=0 rate=1 pos=0 interp=2 pan=0 envbufnum=-1 maxGrains=512;    NC INPUT: True
-}
grainBuf :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
grainBuf :: Int
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
grainBuf Int
numChannels Ugen
trigger Ugen
dur Ugen
sndbuf Ugen
rate_ Ugen
pos Ugen
interp Ugen
pan Ugen
envbufnum Ugen
maxGrains = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"GrainBuf" [Ugen
trigger, Ugen
dur, Ugen
sndbuf, Ugen
rate_, Ugen
pos, Ugen
interp, Ugen
pan, Ugen
envbufnum, Ugen
maxGrains] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Granular synthesis with frequency modulated sine tones

 GrainFM [AudioRate] trigger=0 dur=1 carfreq=440 modfreq=200 index=1 pan=0 envbufnum=-1 maxGrains=512;    NC INPUT: True
-}
grainFM :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
grainFM :: Int
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
grainFM Int
numChannels Ugen
trigger Ugen
dur Ugen
carfreq Ugen
modfreq Ugen
index_ Ugen
pan Ugen
envbufnum Ugen
maxGrains = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"GrainFM" [Ugen
trigger, Ugen
dur, Ugen
carfreq, Ugen
modfreq, Ugen
index_, Ugen
pan, Ugen
envbufnum, Ugen
maxGrains] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Granulate an input signal

 GrainIn [AudioRate] trigger=0 dur=1 in=0 pan=0 envbufnum=-1 maxGrains=512;    NC INPUT: True
-}
grainIn :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
grainIn :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
grainIn Int
numChannels Ugen
trigger Ugen
dur Ugen
in_ Ugen
pan Ugen
envbufnum Ugen
maxGrains = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"GrainIn" [Ugen
trigger, Ugen
dur, Ugen
in_, Ugen
pan, Ugen
envbufnum, Ugen
maxGrains] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Granular synthesis with sine tones

 GrainSin [AudioRate] trigger=0 dur=1 freq=440 pan=0 envbufnum=-1 maxGrains=512;    NC INPUT: True
-}
grainSin :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
grainSin :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
grainSin Int
numChannels Ugen
trigger Ugen
dur Ugen
freq Ugen
pan Ugen
envbufnum Ugen
maxGrains = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"GrainSin" [Ugen
trigger, Ugen
dur, Ugen
freq, Ugen
pan, Ugen
envbufnum, Ugen
maxGrains] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Gray Noise.

 GrayNoise [ControlRate,AudioRate] ;    NONDET
-}
grayNoiseId :: ID a => a -> Rate -> Ugen
grayNoiseId :: forall a. ID a => a -> Rate -> Ugen
grayNoiseId a
z Rate
rate = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"GrayNoise" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of GrayNoise.
grayNoiseM :: Uid m => Rate -> m Ugen
grayNoiseM :: forall (m :: * -> *). Uid m => Rate -> m Ugen
grayNoiseM = (Int -> Rate -> Ugen) -> Fn1 Rate (m Ugen)
forall (m :: * -> *) a b. Uid m => (Int -> Fn1 a b) -> Fn1 a (m b)
liftUid1 Int -> Rate -> Ugen
forall a. ID a => a -> Rate -> Ugen
grayNoiseId

-- | Unsafe variant of GrayNoise.
grayNoise :: Rate -> Ugen
grayNoise :: Rate -> Ugen
grayNoise = (Rate -> IO Ugen) -> Rate -> Ugen
forall a r. (a -> IO r) -> a -> r
liftUnsafe1 Rate -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> m Ugen
grayNoiseM

{- | 2nd order Butterworth highpass filter.

 HPF [ControlRate,AudioRate] in=0 freq=440;    FILTER: TRUE
-}
hpf :: Ugen -> Ugen -> Ugen
hpf :: Ugen -> Ugen -> Ugen
hpf Ugen
in_ Ugen
freq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"HPF" [Ugen
in_, Ugen
freq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Two point difference filter

 HPZ1 [ControlRate,AudioRate] in=0;    FILTER: TRUE
-}
hpz1 :: Ugen -> Ugen
hpz1 :: Ugen -> Ugen
hpz1 Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"HPZ1" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Two zero fixed midcut.

 HPZ2 [ControlRate,AudioRate] in=0;    FILTER: TRUE
-}
hpz2 :: Ugen -> Ugen
hpz2 :: Ugen -> Ugen
hpz2 Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"HPZ2" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Scrambled value with a hash function.

 Hasher [ControlRate,AudioRate] in=0;    FILTER: TRUE
-}
hasher :: Ugen -> Ugen
hasher :: Ugen -> Ugen
hasher Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Hasher" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Henon map chaotic generator

 HenonC [AudioRate] freq=22050 a=1.4 b=0.3 x0=0 x1=0
-}
henonC :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
henonC :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
henonC Rate
rate Ugen
freq Ugen
a Ugen
b Ugen
x0 Ugen
x1 = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"HenonC" [Ugen
freq, Ugen
a, Ugen
b, Ugen
x0, Ugen
x1] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Henon map chaotic generator

 HenonL [AudioRate] freq=22050 a=1.4 b=0.3 x0=0 x1=0
-}
henonL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
henonL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
henonL Rate
rate Ugen
freq Ugen
a Ugen
b Ugen
x0 Ugen
x1 = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"HenonL" [Ugen
freq, Ugen
a, Ugen
b, Ugen
x0, Ugen
x1] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Henon map chaotic generator

 HenonN [AudioRate] freq=22050 a=1.4 b=0.3 x0=0 x1=0
-}
henonN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
henonN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
henonN Rate
rate Ugen
freq Ugen
a Ugen
b Ugen
x0 Ugen
x1 = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"HenonN" [Ugen
freq, Ugen
a, Ugen
b, Ugen
x0, Ugen
x1] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Applies the Hilbert transform to an input signal.

 Hilbert [AudioRate] in=0;    FILTER: TRUE
-}
hilbert :: Ugen -> Ugen
hilbert :: Ugen -> Ugen
hilbert Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Hilbert" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
2 (Int -> Special
Special Int
0) UgenId
NoId

{- | Envelope generator for polling values from an Env

 IEnvGen [ControlRate,AudioRate] index=0 *envelope=0;    MCE=1, REORDERS INPUTS: [1,0], ENUMERATION INPUTS: 1=IEnvelope
-}
iEnvGen :: Rate -> Ugen -> Envelope Ugen -> Ugen
iEnvGen :: Rate -> Ugen -> Envelope Ugen -> Ugen
iEnvGen Rate
rate Ugen
index_ Envelope Ugen
envelope_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"IEnvGen" [Ugen
index_] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [(Envelope Ugen -> Ugen
envelope_to_ienvgen_ugen Envelope Ugen
envelope_)]) Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Inverse Fast Fourier Transform

 IFFT [ControlRate,AudioRate] buffer=0 wintype=0 winsize=0
-}
ifft :: Ugen -> Ugen -> Ugen -> Ugen
ifft :: Ugen -> Ugen -> Ugen -> Ugen
ifft Ugen
buffer Ugen
wintype Ugen
winsize = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"IFFT" [Ugen
buffer, Ugen
wintype, Ugen
winsize] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Single integer random number generator.

 iRand [InitialisationRate] lo=0 hi=127;    NONDET
-}
iRandId :: ID a => a -> Ugen -> Ugen -> Ugen
iRandId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
iRandId a
z Ugen
lo Ugen
hi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"IRand" [Ugen
lo, Ugen
hi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of irand.
iRandM :: Uid m => Ugen -> Ugen -> m Ugen
iRandM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
iRandM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
iRandId

-- | Unsafe variant of irand.
iRand :: Ugen -> Ugen -> Ugen
iRand :: Ugen -> Ugen -> Ugen
iRand = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
iRandM

{- | Impulse oscillator.

 Impulse [ControlRate,AudioRate] freq=440 phase=0
-}
impulse :: Rate -> Ugen -> Ugen -> Ugen
impulse :: Rate -> Ugen -> Ugen -> Ugen
impulse Rate
rate Ugen
freq Ugen
phase = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Impulse" [Ugen
freq, Ugen
phase] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Read a signal from a bus.

 In [ControlRate,AudioRate] bus=0;    NC INPUT: True
-}
in' :: Int -> Rate -> Ugen -> Ugen
in' :: Int -> Rate -> Ugen -> Ugen
in' Int
numChannels Rate
rate Ugen
bus = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"In" [Ugen
bus] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Read signal from a bus with a current or one cycle old timestamp.

 InFeedback [AudioRate] bus=0;    NC INPUT: True
-}
inFeedback :: Int -> Ugen -> Ugen
inFeedback :: Int -> Ugen -> Ugen
inFeedback Int
numChannels Ugen
bus = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"InFeedback" [Ugen
bus] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Tests if a signal is within a given range.

 InRange [InitialisationRate,ControlRate,AudioRate] in=0 lo=0 hi=1;    FILTER: TRUE
-}
inRange :: Ugen -> Ugen -> Ugen -> Ugen
inRange :: Ugen -> Ugen -> Ugen -> Ugen
inRange Ugen
in_ Ugen
lo Ugen
hi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"InRange" [Ugen
in_, Ugen
lo, Ugen
hi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Test if a point is within a given rectangle.

 InRect [ControlRate,AudioRate] x=0 y=0 rect=0
-}
inRect :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
inRect :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
inRect Rate
rate Ugen
x Ugen
y Ugen
rect = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"InRect" [Ugen
x, Ugen
y, Ugen
rect] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Generate a trigger anytime a bus is set.

 InTrig [ControlRate] bus=0;    NC INPUT: True
-}
inTrig :: Int -> Ugen -> Ugen
inTrig :: Int -> Ugen -> Ugen
inTrig Int
numChannels Ugen
bus = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"InTrig" [Ugen
bus] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Index into a table with a signal

 Index [ControlRate,AudioRate] bufnum=0 in=0;    FILTER: TRUE
-}
index :: Ugen -> Ugen -> Ugen
index :: Ugen -> Ugen -> Ugen
index Ugen
bufnum Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"Index" [Ugen
bufnum, Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Finds the (lowest) point in the Buffer at which the input signal lies in-between the two values

 IndexInBetween [ControlRate,AudioRate] bufnum=0 in=0;    FILTER: TRUE
-}
indexInBetween :: Ugen -> Ugen -> Ugen
indexInBetween :: Ugen -> Ugen -> Ugen
indexInBetween Ugen
bufnum Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"IndexInBetween" [Ugen
bufnum, Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Index into a table with a signal, linear interpolated

 IndexL [ControlRate,AudioRate] bufnum=0 in=0;    FILTER: TRUE
-}
indexL :: Ugen -> Ugen -> Ugen
indexL :: Ugen -> Ugen -> Ugen
indexL Ugen
bufnum Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"IndexL" [Ugen
bufnum, Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Base class for info ugens

 InfoUgenBase [InitialisationRate]
-}
infoUgenBase :: Rate -> Ugen
infoUgenBase :: Rate -> Ugen
infoUgenBase Rate
rate = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"InfoUgenBase" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | A leaky integrator.

 Integrator [ControlRate,AudioRate] in=0 coef=1;    FILTER: TRUE
-}
integrator :: Ugen -> Ugen -> Ugen
integrator :: Ugen -> Ugen -> Ugen
integrator Ugen
in_ Ugen
coef = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Integrator" [Ugen
in_, Ugen
coef] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Control to audio rate converter.

 K2A [AudioRate] in=0
-}
k2a :: Ugen -> Ugen
k2a :: Ugen -> Ugen
k2a Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"K2A" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Respond to the state of a key

 KeyState [ControlRate] keycode=0 minval=0 maxval=1 lag=0.2
-}
keyState :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
keyState :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
keyState Rate
rate Ugen
keycode Ugen
minval Ugen
maxval Ugen
lag_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"KeyState" [Ugen
keycode, Ugen
minval, Ugen
maxval, Ugen
lag_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Key tracker

 KeyTrack [ControlRate] chain=0 keydecay=2 chromaleak=0.5
-}
keyTrack :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
keyTrack :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
keyTrack Rate
rate Ugen
chain Ugen
keydecay Ugen
chromaleak = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"KeyTrack" [Ugen
chain, Ugen
keydecay, Ugen
chromaleak] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Sine oscillator bank

 Klang [AudioRate] freqscale=1 freqoffset=0 *specificationsArrayRef=0;    MCE=1, REORDERS INPUTS: [2,0,1]
-}
klang :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
klang :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
klang Rate
rate Ugen
freqscale Ugen
freqoffset Ugen
specificationsArrayRef = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Klang" [Ugen
freqscale, Ugen
freqoffset] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
specificationsArrayRef]) Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Bank of resonators

 Klank [AudioRate] input=0 freqscale=1 freqoffset=0 decayscale=1 *specificationsArrayRef=0;    MCE=1, FILTER: TRUE, REORDERS INPUTS: [4,0,1,2,3]
-}
klank :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
klank :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
klank Ugen
input Ugen
freqscale Ugen
freqoffset Ugen
decayscale Ugen
specificationsArrayRef = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Klank" [Ugen
input, Ugen
freqscale, Ugen
freqoffset, Ugen
decayscale] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
specificationsArrayRef]) Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Clipped noise

 LFClipNoise [ControlRate,AudioRate] freq=500;    NONDET
-}
lfClipNoiseId :: ID a => a -> Rate -> Ugen -> Ugen
lfClipNoiseId :: forall a. ID a => a -> Rate -> Ugen -> Ugen
lfClipNoiseId a
z Rate
rate Ugen
freq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFClipNoise" [Ugen
freq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of LFClipNoise.
lfClipNoiseM :: Uid m => Rate -> Ugen -> m Ugen
lfClipNoiseM :: forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfClipNoiseM = (Int -> Rate -> Ugen -> Ugen) -> Fn2 Rate Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Rate -> Ugen -> Ugen
forall a. ID a => a -> Rate -> Ugen -> Ugen
lfClipNoiseId

-- | Unsafe variant of LFClipNoise.
lfClipNoise :: Rate -> Ugen -> Ugen
lfClipNoise :: Rate -> Ugen -> Ugen
lfClipNoise = (Rate -> Ugen -> IO Ugen) -> Rate -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Rate -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfClipNoiseM

{- | A sine like shape made of two cubic pieces

 LFCub [ControlRate,AudioRate] freq=440 iphase=0
-}
lfCub :: Rate -> Ugen -> Ugen -> Ugen
lfCub :: Rate -> Ugen -> Ugen -> Ugen
lfCub Rate
rate Ugen
freq Ugen
iphase = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFCub" [Ugen
freq, Ugen
iphase] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Dynamic clipped noise

 LFDClipNoise [ControlRate,AudioRate] freq=500;    NONDET
-}
lfdClipNoiseId :: ID a => a -> Rate -> Ugen -> Ugen
lfdClipNoiseId :: forall a. ID a => a -> Rate -> Ugen -> Ugen
lfdClipNoiseId a
z Rate
rate Ugen
freq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFDClipNoise" [Ugen
freq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of LFDClipNoise.
lfdClipNoiseM :: Uid m => Rate -> Ugen -> m Ugen
lfdClipNoiseM :: forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfdClipNoiseM = (Int -> Rate -> Ugen -> Ugen) -> Fn2 Rate Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Rate -> Ugen -> Ugen
forall a. ID a => a -> Rate -> Ugen -> Ugen
lfdClipNoiseId

-- | Unsafe variant of LFDClipNoise.
lfdClipNoise :: Rate -> Ugen -> Ugen
lfdClipNoise :: Rate -> Ugen -> Ugen
lfdClipNoise = (Rate -> Ugen -> IO Ugen) -> Rate -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Rate -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfdClipNoiseM

{- | Dynamic step noise

 LFDNoise0 [ControlRate,AudioRate] freq=500;    NONDET
-}
lfdNoise0Id :: ID a => a -> Rate -> Ugen -> Ugen
lfdNoise0Id :: forall a. ID a => a -> Rate -> Ugen -> Ugen
lfdNoise0Id a
z Rate
rate Ugen
freq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFDNoise0" [Ugen
freq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of LFDNoise0.
lfdNoise0M :: Uid m => Rate -> Ugen -> m Ugen
lfdNoise0M :: forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfdNoise0M = (Int -> Rate -> Ugen -> Ugen) -> Fn2 Rate Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Rate -> Ugen -> Ugen
forall a. ID a => a -> Rate -> Ugen -> Ugen
lfdNoise0Id

-- | Unsafe variant of LFDNoise0.
lfdNoise0 :: Rate -> Ugen -> Ugen
lfdNoise0 :: Rate -> Ugen -> Ugen
lfdNoise0 = (Rate -> Ugen -> IO Ugen) -> Rate -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Rate -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfdNoise0M

{- | Dynamic ramp noise

 LFDNoise1 [ControlRate,AudioRate] freq=500;    NONDET
-}
lfdNoise1Id :: ID a => a -> Rate -> Ugen -> Ugen
lfdNoise1Id :: forall a. ID a => a -> Rate -> Ugen -> Ugen
lfdNoise1Id a
z Rate
rate Ugen
freq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFDNoise1" [Ugen
freq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of LFDNoise1.
lfdNoise1M :: Uid m => Rate -> Ugen -> m Ugen
lfdNoise1M :: forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfdNoise1M = (Int -> Rate -> Ugen -> Ugen) -> Fn2 Rate Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Rate -> Ugen -> Ugen
forall a. ID a => a -> Rate -> Ugen -> Ugen
lfdNoise1Id

-- | Unsafe variant of LFDNoise1.
lfdNoise1 :: Rate -> Ugen -> Ugen
lfdNoise1 :: Rate -> Ugen -> Ugen
lfdNoise1 = (Rate -> Ugen -> IO Ugen) -> Rate -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Rate -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfdNoise1M

{- | Dynamic cubic noise

 LFDNoise3 [ControlRate,AudioRate] freq=500;    NONDET
-}
lfdNoise3Id :: ID a => a -> Rate -> Ugen -> Ugen
lfdNoise3Id :: forall a. ID a => a -> Rate -> Ugen -> Ugen
lfdNoise3Id a
z Rate
rate Ugen
freq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFDNoise3" [Ugen
freq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of LFDNoise3.
lfdNoise3M :: Uid m => Rate -> Ugen -> m Ugen
lfdNoise3M :: forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfdNoise3M = (Int -> Rate -> Ugen -> Ugen) -> Fn2 Rate Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Rate -> Ugen -> Ugen
forall a. ID a => a -> Rate -> Ugen -> Ugen
lfdNoise3Id

-- | Unsafe variant of LFDNoise3.
lfdNoise3 :: Rate -> Ugen -> Ugen
lfdNoise3 :: Rate -> Ugen -> Ugen
lfdNoise3 = (Rate -> Ugen -> IO Ugen) -> Rate -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Rate -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfdNoise3M

{- | Gaussian function oscillator

 LFGauss [ControlRate,AudioRate] duration=1 width=0.1 iphase=0 loop=1 doneAction=0;    ENUMERATION INPUTS: 3=Loop, 4=DoneAction
-}
lfGauss :: Rate -> Ugen -> Ugen -> Ugen -> Loop Ugen -> DoneAction Ugen -> Ugen
lfGauss :: Rate
-> Ugen -> Ugen -> Ugen -> Loop Ugen -> DoneAction Ugen -> Ugen
lfGauss Rate
rate Ugen
duration Ugen
width Ugen
iphase Loop Ugen
loop DoneAction Ugen
doneAction = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFGauss" [Ugen
duration, Ugen
width, Ugen
iphase, (Loop Ugen -> Ugen
forall t. Num t => Loop t -> t
from_loop Loop Ugen
loop), (DoneAction Ugen -> Ugen
forall t. Num t => DoneAction t -> t
from_done_action DoneAction Ugen
doneAction)] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Step noise

 LFNoise0 [ControlRate,AudioRate] freq=500;    NONDET
-}
lfNoise0Id :: ID a => a -> Rate -> Ugen -> Ugen
lfNoise0Id :: forall a. ID a => a -> Rate -> Ugen -> Ugen
lfNoise0Id a
z Rate
rate Ugen
freq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFNoise0" [Ugen
freq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of LFNoise0.
lfNoise0M :: Uid m => Rate -> Ugen -> m Ugen
lfNoise0M :: forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfNoise0M = (Int -> Rate -> Ugen -> Ugen) -> Fn2 Rate Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Rate -> Ugen -> Ugen
forall a. ID a => a -> Rate -> Ugen -> Ugen
lfNoise0Id

-- | Unsafe variant of LFNoise0.
lfNoise0 :: Rate -> Ugen -> Ugen
lfNoise0 :: Rate -> Ugen -> Ugen
lfNoise0 = (Rate -> Ugen -> IO Ugen) -> Rate -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Rate -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfNoise0M

{- | Ramp noise

 LFNoise1 [ControlRate,AudioRate] freq=500;    NONDET
-}
lfNoise1Id :: ID a => a -> Rate -> Ugen -> Ugen
lfNoise1Id :: forall a. ID a => a -> Rate -> Ugen -> Ugen
lfNoise1Id a
z Rate
rate Ugen
freq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFNoise1" [Ugen
freq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of LFNoise1.
lfNoise1M :: Uid m => Rate -> Ugen -> m Ugen
lfNoise1M :: forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfNoise1M = (Int -> Rate -> Ugen -> Ugen) -> Fn2 Rate Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Rate -> Ugen -> Ugen
forall a. ID a => a -> Rate -> Ugen -> Ugen
lfNoise1Id

-- | Unsafe variant of LFNoise1.
lfNoise1 :: Rate -> Ugen -> Ugen
lfNoise1 :: Rate -> Ugen -> Ugen
lfNoise1 = (Rate -> Ugen -> IO Ugen) -> Rate -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Rate -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfNoise1M

{- | Quadratic noise.

 LFNoise2 [ControlRate,AudioRate] freq=500;    NONDET
-}
lfNoise2Id :: ID a => a -> Rate -> Ugen -> Ugen
lfNoise2Id :: forall a. ID a => a -> Rate -> Ugen -> Ugen
lfNoise2Id a
z Rate
rate Ugen
freq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFNoise2" [Ugen
freq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of LFNoise2.
lfNoise2M :: Uid m => Rate -> Ugen -> m Ugen
lfNoise2M :: forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfNoise2M = (Int -> Rate -> Ugen -> Ugen) -> Fn2 Rate Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Rate -> Ugen -> Ugen
forall a. ID a => a -> Rate -> Ugen -> Ugen
lfNoise2Id

-- | Unsafe variant of LFNoise2.
lfNoise2 :: Rate -> Ugen -> Ugen
lfNoise2 :: Rate -> Ugen -> Ugen
lfNoise2 = (Rate -> Ugen -> IO Ugen) -> Rate -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Rate -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> Ugen -> m Ugen
lfNoise2M

{- | Parabolic oscillator

 LFPar [ControlRate,AudioRate] freq=440 iphase=0
-}
lfPar :: Rate -> Ugen -> Ugen -> Ugen
lfPar :: Rate -> Ugen -> Ugen -> Ugen
lfPar Rate
rate Ugen
freq Ugen
iphase = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFPar" [Ugen
freq, Ugen
iphase] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | pulse oscillator

 LFPulse [ControlRate,AudioRate] freq=440 iphase=0 width=0.5
-}
lfPulse :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
lfPulse :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
lfPulse Rate
rate Ugen
freq Ugen
iphase Ugen
width = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFPulse" [Ugen
freq, Ugen
iphase, Ugen
width] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Sawtooth oscillator

 LFSaw [ControlRate,AudioRate] freq=440 iphase=0
-}
lfSaw :: Rate -> Ugen -> Ugen -> Ugen
lfSaw :: Rate -> Ugen -> Ugen -> Ugen
lfSaw Rate
rate Ugen
freq Ugen
iphase = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFSaw" [Ugen
freq, Ugen
iphase] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Triangle oscillator

 LFTri [ControlRate,AudioRate] freq=440 iphase=0
-}
lfTri :: Rate -> Ugen -> Ugen -> Ugen
lfTri :: Rate -> Ugen -> Ugen -> Ugen
lfTri Rate
rate Ugen
freq Ugen
iphase = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LFTri" [Ugen
freq, Ugen
iphase] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | 2nd order Butterworth lowpass filter

 LPF [ControlRate,AudioRate] in=0 freq=440;    FILTER: TRUE
-}
lpf :: Ugen -> Ugen -> Ugen
lpf :: Ugen -> Ugen -> Ugen
lpf Ugen
in_ Ugen
freq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"LPF" [Ugen
in_, Ugen
freq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Two point average filter

 LPZ1 [ControlRate,AudioRate] in=0;    FILTER: TRUE
-}
lpz1 :: Ugen -> Ugen
lpz1 :: Ugen -> Ugen
lpz1 Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"LPZ1" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Two zero fixed lowpass

 LPZ2 [ControlRate,AudioRate] in=0;    FILTER: TRUE
-}
lpz2 :: Ugen -> Ugen
lpz2 :: Ugen -> Ugen
lpz2 Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"LPZ2" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Exponential lag

 Lag [ControlRate,AudioRate] in=0 lagTime=0.1;    FILTER: TRUE
-}
lag :: Ugen -> Ugen -> Ugen
lag :: Ugen -> Ugen -> Ugen
lag Ugen
in_ Ugen
lagTime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Lag" [Ugen
in_, Ugen
lagTime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Exponential lag

 Lag2 [ControlRate,AudioRate] in=0 lagTime=0.1;    FILTER: TRUE
-}
lag2 :: Ugen -> Ugen -> Ugen
lag2 :: Ugen -> Ugen -> Ugen
lag2 Ugen
in_ Ugen
lagTime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Lag2" [Ugen
in_, Ugen
lagTime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Exponential lag

 Lag2UD [ControlRate,AudioRate] in=0 lagTimeU=0.1 lagTimeD=0.1;    FILTER: TRUE
-}
lag2UD :: Ugen -> Ugen -> Ugen -> Ugen
lag2UD :: Ugen -> Ugen -> Ugen -> Ugen
lag2UD Ugen
in_ Ugen
lagTimeU Ugen
lagTimeD = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Lag2UD" [Ugen
in_, Ugen
lagTimeU, Ugen
lagTimeD] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Exponential lag

 Lag3 [ControlRate,AudioRate] in=0 lagTime=0.1;    FILTER: TRUE
-}
lag3 :: Ugen -> Ugen -> Ugen
lag3 :: Ugen -> Ugen -> Ugen
lag3 Ugen
in_ Ugen
lagTime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Lag3" [Ugen
in_, Ugen
lagTime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Exponential lag

 Lag3UD [ControlRate,AudioRate] in=0 lagTimeU=0.1 lagTimeD=0.1;    FILTER: TRUE
-}
lag3UD :: Ugen -> Ugen -> Ugen -> Ugen
lag3UD :: Ugen -> Ugen -> Ugen -> Ugen
lag3UD Ugen
in_ Ugen
lagTimeU Ugen
lagTimeD = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Lag3UD" [Ugen
in_, Ugen
lagTimeU, Ugen
lagTimeD] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Read a control signal from a bus with a lag

 LagIn [ControlRate] bus=0 lag=0.1;    NC INPUT: True
-}
lagIn :: Int -> Ugen -> Ugen -> Ugen
lagIn :: Int -> Ugen -> Ugen -> Ugen
lagIn Int
numChannels Ugen
bus Ugen
lag_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"LagIn" [Ugen
bus, Ugen
lag_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Exponential lag

 LagUD [ControlRate,AudioRate] in=0 lagTimeU=0.1 lagTimeD=0.1;    FILTER: TRUE
-}
lagUD :: Ugen -> Ugen -> Ugen -> Ugen
lagUD :: Ugen -> Ugen -> Ugen -> Ugen
lagUD Ugen
in_ Ugen
lagTimeU Ugen
lagTimeD = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"LagUD" [Ugen
in_, Ugen
lagTimeU, Ugen
lagTimeD] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Output the last value before the input changed

 LastValue [ControlRate,AudioRate] in=0 diff=0.01;    FILTER: TRUE
-}
lastValue :: Ugen -> Ugen -> Ugen
lastValue :: Ugen -> Ugen -> Ugen
lastValue Ugen
in_ Ugen
diff = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"LastValue" [Ugen
in_, Ugen
diff] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Sample and hold

 Latch [ControlRate,AudioRate] in=0 trig=0;    FILTER: TRUE
-}
latch :: Ugen -> Ugen -> Ugen
latch :: Ugen -> Ugen -> Ugen
latch Ugen
in_ Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1]) String
"Latch" [Ugen
in_, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Latoocarfian chaotic generator

 LatoocarfianC [AudioRate] freq=22050 a=1 b=3 c=0.5 d=0.5 xi=0.5 yi=0.5
-}
latoocarfianC :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
latoocarfianC :: Rate
-> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
latoocarfianC Rate
rate Ugen
freq Ugen
a Ugen
b Ugen
c Ugen
d Ugen
xi Ugen
yi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LatoocarfianC" [Ugen
freq, Ugen
a, Ugen
b, Ugen
c, Ugen
d, Ugen
xi, Ugen
yi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Latoocarfian chaotic generator

 LatoocarfianL [AudioRate] freq=22050 a=1 b=3 c=0.5 d=0.5 xi=0.5 yi=0.5
-}
latoocarfianL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
latoocarfianL :: Rate
-> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
latoocarfianL Rate
rate Ugen
freq Ugen
a Ugen
b Ugen
c Ugen
d Ugen
xi Ugen
yi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LatoocarfianL" [Ugen
freq, Ugen
a, Ugen
b, Ugen
c, Ugen
d, Ugen
xi, Ugen
yi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Latoocarfian chaotic generator

 LatoocarfianN [AudioRate] freq=22050 a=1 b=3 c=0.5 d=0.5 xi=0.5 yi=0.5
-}
latoocarfianN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
latoocarfianN :: Rate
-> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
latoocarfianN Rate
rate Ugen
freq Ugen
a Ugen
b Ugen
c Ugen
d Ugen
xi Ugen
yi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LatoocarfianN" [Ugen
freq, Ugen
a, Ugen
b, Ugen
c, Ugen
d, Ugen
xi, Ugen
yi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Remove DC

 LeakDC [ControlRate,AudioRate] in=0 coef=0.995;    FILTER: TRUE
-}
leakDC :: Ugen -> Ugen -> Ugen
leakDC :: Ugen -> Ugen -> Ugen
leakDC Ugen
in_ Ugen
coef = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"LeakDC" [Ugen
in_, Ugen
coef] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Output least changed

 LeastChange [ControlRate,AudioRate] a=0 b=0
-}
leastChange :: Rate -> Ugen -> Ugen -> Ugen
leastChange :: Rate -> Ugen -> Ugen -> Ugen
leastChange Rate
rate Ugen
a Ugen
b = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LeastChange" [Ugen
a, Ugen
b] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Peak limiter

 Limiter [AudioRate] in=0 level=1 dur=0.01;    FILTER: TRUE
-}
limiter :: Ugen -> Ugen -> Ugen -> Ugen
limiter :: Ugen -> Ugen -> Ugen -> Ugen
limiter Ugen
in_ Ugen
level Ugen
dur = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Limiter" [Ugen
in_, Ugen
level, Ugen
dur] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Linear congruential chaotic generator

 LinCongC [AudioRate] freq=22050 a=1.1 c=0.13 m=1 xi=0
-}
linCongC :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
linCongC :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
linCongC Rate
rate Ugen
freq Ugen
a Ugen
c Ugen
m Ugen
xi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LinCongC" [Ugen
freq, Ugen
a, Ugen
c, Ugen
m, Ugen
xi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Linear congruential chaotic generator

 LinCongL [AudioRate] freq=22050 a=1.1 c=0.13 m=1 xi=0
-}
linCongL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
linCongL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
linCongL Rate
rate Ugen
freq Ugen
a Ugen
c Ugen
m Ugen
xi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LinCongL" [Ugen
freq, Ugen
a, Ugen
c, Ugen
m, Ugen
xi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Linear congruential chaotic generator

 LinCongN [AudioRate] freq=22050 a=1.1 c=0.13 m=1 xi=0
-}
linCongN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
linCongN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
linCongN Rate
rate Ugen
freq Ugen
a Ugen
c Ugen
m Ugen
xi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LinCongN" [Ugen
freq, Ugen
a, Ugen
c, Ugen
m, Ugen
xi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Map a linear range to an exponential range

 LinExp [InitialisationRate,ControlRate,AudioRate] in=0 srclo=0 srchi=1 dstlo=1 dsthi=2;    FILTER: TRUE
-}
linExp :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
linExp :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
linExp Ugen
in_ Ugen
srclo Ugen
srchi Ugen
dstlo Ugen
dsthi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"LinExp" [Ugen
in_, Ugen
srclo, Ugen
srchi, Ugen
dstlo, Ugen
dsthi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Two channel linear pan.

 LinPan2 [ControlRate,AudioRate] in=0 pos=0 level=1;    FILTER: TRUE
-}
linPan2 :: Ugen -> Ugen -> Ugen -> Ugen
linPan2 :: Ugen -> Ugen -> Ugen -> Ugen
linPan2 Ugen
in_ Ugen
pos Ugen
level = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"LinPan2" [Ugen
in_, Ugen
pos, Ugen
level] Maybe [Ugen]
forall a. Maybe a
Nothing Int
2 (Int -> Special
Special Int
0) UgenId
NoId

{- | Skewed random number generator.

 LinRand [InitialisationRate] lo=0 hi=1 minmax=0;    NONDET
-}
linRandId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
linRandId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
linRandId a
z Ugen
lo Ugen
hi Ugen
minmax = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"LinRand" [Ugen
lo, Ugen
hi, Ugen
minmax] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of LinRand.
linRandM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
linRandM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
linRandM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
linRandId

-- | Unsafe variant of LinRand.
linRand :: Ugen -> Ugen -> Ugen -> Ugen
linRand :: Ugen -> Ugen -> Ugen -> Ugen
linRand = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
linRandM

{- | Two channel linear crossfade.

 LinXFade2 [ControlRate,AudioRate] inA=0 inB=0 pan=0 level=1;    FILTER: TRUE, PSUEDO INPUTS: [3]
-}
linXFade2 :: Ugen -> Ugen -> Ugen -> Ugen
linXFade2 :: Ugen -> Ugen -> Ugen -> Ugen
linXFade2 Ugen
inA Ugen
inB Ugen
pan = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1]) String
"LinXFade2" [Ugen
inA, Ugen
inB, Ugen
pan] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Line generator.

 Line [ControlRate,AudioRate] start=0 end=1 dur=1 doneAction=0;    ENUMERATION INPUTS: 3=DoneAction
-}
line :: Rate -> Ugen -> Ugen -> Ugen -> DoneAction Ugen -> Ugen
line :: Rate -> Ugen -> Ugen -> Ugen -> DoneAction Ugen -> Ugen
line Rate
rate Ugen
start Ugen
end Ugen
dur DoneAction Ugen
doneAction = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Line" [Ugen
start, Ugen
end, Ugen
dur, (DoneAction Ugen -> Ugen
forall t. Num t => DoneAction t -> t
from_done_action DoneAction Ugen
doneAction)] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Simple linear envelope generator.

 Linen [ControlRate] gate=1 attackTime=0.01 susLevel=1 releaseTime=1 doneAction=0;    ENUMERATION INPUTS: 4=DoneAction
-}
linen :: Ugen -> Ugen -> Ugen -> Ugen -> DoneAction Ugen -> Ugen
linen :: Ugen -> Ugen -> Ugen -> Ugen -> DoneAction Ugen -> Ugen
linen Ugen
gate_ Ugen
attackTime Ugen
susLevel Ugen
releaseTime DoneAction Ugen
doneAction = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"Linen" [Ugen
gate_, Ugen
attackTime, Ugen
susLevel, Ugen
releaseTime, (DoneAction Ugen -> Ugen
forall t. Num t => DoneAction t -> t
from_done_action DoneAction Ugen
doneAction)] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Allocate a buffer local to the synth

 LocalBuf [InitialisationRate] numChannels=1 numFrames=1;    REORDERS INPUTS: [1,0], NONDET
-}
localBufId :: ID a => a -> Ugen -> Ugen -> Ugen
localBufId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
localBufId a
z Ugen
numChannels Ugen
numFrames = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"LocalBuf" [Ugen
numChannels, Ugen
numFrames] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of LocalBuf.
localBufM :: Uid m => Ugen -> Ugen -> m Ugen
localBufM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
localBufM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
localBufId

-- | Unsafe variant of LocalBuf.
localBuf :: Ugen -> Ugen -> Ugen
localBuf :: Ugen -> Ugen -> Ugen
localBuf = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
localBufM

{- | Define and read from buses local to a synth.

 LocalIn [ControlRate,AudioRate] *default=0;    MCE=1, NC INPUT: True
-}
localIn :: Int -> Rate -> Ugen -> Ugen
localIn :: Int -> Rate -> Ugen -> Ugen
localIn Int
numChannels Rate
rate Ugen
default_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LocalIn" [] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
default_]) Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Write to buses local to a synth.

 LocalOut [ControlRate,AudioRate] *channelsArray=0;    MCE=1, FILTER: TRUE
-}
localOut :: Ugen -> Ugen
localOut :: Ugen -> Ugen
localOut Ugen
input = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"LocalOut" [] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
input]) Int
0 (Int -> Special
Special Int
0) UgenId
NoId

{- | Chaotic noise function

 Logistic [ControlRate,AudioRate] chaosParam=3 freq=1000 init=0.5
-}
logistic :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
logistic :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
logistic Rate
rate Ugen
chaosParam Ugen
freq Ugen
init_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Logistic" [Ugen
chaosParam, Ugen
freq, Ugen
init_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Lorenz chaotic generator

 LorenzL [AudioRate] freq=22050 s=10 r=28 b=2.667 h=0.05 xi=0.1 yi=0 zi=0
-}
lorenzL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
lorenzL :: Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
lorenzL Rate
rate Ugen
freq Ugen
s Ugen
r Ugen
b Ugen
h Ugen
xi Ugen
yi Ugen
zi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"LorenzL" [Ugen
freq, Ugen
s, Ugen
r, Ugen
b, Ugen
h, Ugen
xi, Ugen
yi, Ugen
zi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Extraction of instantaneous loudness in sones

 Loudness [ControlRate] chain=0 smask=0.25 tmask=1
-}
loudness :: Ugen -> Ugen -> Ugen -> Ugen
loudness :: Ugen -> Ugen -> Ugen -> Ugen
loudness Ugen
chain Ugen
smask Ugen
tmask = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"Loudness" [Ugen
chain, Ugen
smask, Ugen
tmask] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Mel frequency cepstral coefficients

 MFCC [ControlRate] chain=0 numcoeff=13
-}
mfcc :: Rate -> Ugen -> Ugen -> Ugen
mfcc :: Rate -> Ugen -> Ugen -> Ugen
mfcc Rate
rate Ugen
chain Ugen
numcoeff = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"MFCC" [Ugen
chain, Ugen
numcoeff] Maybe [Ugen]
forall a. Maybe a
Nothing Int
13 (Int -> Special
Special Int
0) UgenId
NoId

{- | Reduce precision.

 MantissaMask [ControlRate,AudioRate] in=0 bits=3;    FILTER: TRUE
-}
mantissaMask :: Ugen -> Ugen -> Ugen
mantissaMask :: Ugen -> Ugen -> Ugen
mantissaMask Ugen
in_ Ugen
bits = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"MantissaMask" [Ugen
in_, Ugen
bits] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Median filter.

 Median [ControlRate,AudioRate] length=3 in=0;    FILTER: TRUE
-}
median :: Ugen -> Ugen -> Ugen
median :: Ugen -> Ugen -> Ugen
median Ugen
length_ Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"Median" [Ugen
length_, Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Parametric filter.

 MidEQ [ControlRate,AudioRate] in=0 freq=440 rq=1 db=0;    FILTER: TRUE
-}
midEQ :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
midEQ :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
midEQ Ugen
in_ Ugen
freq Ugen
rq Ugen
db = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"MidEQ" [Ugen
in_, Ugen
freq, Ugen
rq, Ugen
db] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Minimum difference of two values in modulo arithmetics

 ModDif [InitialisationRate,ControlRate,AudioRate] x=0 y=0 mod=1;    FILTER: TRUE
-}
modDif :: Ugen -> Ugen -> Ugen -> Ugen
modDif :: Ugen -> Ugen -> Ugen -> Ugen
modDif Ugen
x Ugen
y Ugen
mod_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"ModDif" [Ugen
x, Ugen
y, Ugen
mod_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Moog VCF implementation, designed by Federico Fontana

 MoogFF [ControlRate,AudioRate] in=0 freq=100 gain=2 reset=0;    FILTER: TRUE
-}
moogFF :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
moogFF :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
moogFF Ugen
in_ Ugen
freq Ugen
gain Ugen
reset = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"MoogFF" [Ugen
in_, Ugen
freq, Ugen
gain, Ugen
reset] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Output most changed.

 MostChange [ControlRate,AudioRate] a=0 b=0;    FILTER: TRUE
-}
mostChange :: Ugen -> Ugen -> Ugen
mostChange :: Ugen -> Ugen -> Ugen
mostChange Ugen
a Ugen
b = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1]) String
"MostChange" [Ugen
a, Ugen
b] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Mouse button Ugen.

 MouseButton [ControlRate] minval=0 maxval=1 lag=0.2
-}
mouseButton :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
mouseButton :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
mouseButton Rate
rate Ugen
minval Ugen
maxval Ugen
lag_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"MouseButton" [Ugen
minval, Ugen
maxval, Ugen
lag_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Cursor tracking Ugen.

 MouseX [ControlRate] minval=0 maxval=1 warp=0 lag=0.2;    ENUMERATION INPUTS: 2=Warp
-}
mouseX :: Rate -> Ugen -> Ugen -> Warp Ugen -> Ugen -> Ugen
mouseX :: Rate -> Ugen -> Ugen -> Warp Ugen -> Ugen -> Ugen
mouseX Rate
rate Ugen
minval Ugen
maxval Warp Ugen
warp Ugen
lag_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"MouseX" [Ugen
minval, Ugen
maxval, (Warp Ugen -> Ugen
forall t. Num t => Warp t -> t
from_warp Warp Ugen
warp), Ugen
lag_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Cursor tracking Ugen.

 MouseY [ControlRate] minval=0 maxval=1 warp=0 lag=0.2;    ENUMERATION INPUTS: 2=Warp
-}
mouseY :: Rate -> Ugen -> Ugen -> Warp Ugen -> Ugen -> Ugen
mouseY :: Rate -> Ugen -> Ugen -> Warp Ugen -> Ugen -> Ugen
mouseY Rate
rate Ugen
minval Ugen
maxval Warp Ugen
warp Ugen
lag_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"MouseY" [Ugen
minval, Ugen
maxval, (Warp Ugen -> Ugen
forall t. Num t => Warp t -> t
from_warp Warp Ugen
warp), Ugen
lag_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Sum of uniform distributions.

 NRand [InitialisationRate] lo=0 hi=1 n=0;    NONDET
-}
nRandId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
nRandId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
nRandId a
z Ugen
lo Ugen
hi Ugen
n = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"NRand" [Ugen
lo, Ugen
hi, Ugen
n] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of NRand.
nRandM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
nRandM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
nRandM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
nRandId

-- | Unsafe variant of NRand.
nRand :: Ugen -> Ugen -> Ugen -> Ugen
nRand :: Ugen -> Ugen -> Ugen -> Ugen
nRand = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
nRandM

{- | (Undocumented class)

 NodeID [InitialisationRate]
-}
nodeID :: Rate -> Ugen
nodeID :: Rate -> Ugen
nodeID Rate
rate = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"NodeID" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Flattens dynamics.

 Normalizer [AudioRate] in=0 level=1 dur=0.01;    FILTER: TRUE
-}
normalizer :: Ugen -> Ugen -> Ugen -> Ugen
normalizer :: Ugen -> Ugen -> Ugen -> Ugen
normalizer Ugen
in_ Ugen
level Ugen
dur = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Normalizer" [Ugen
in_, Ugen
level, Ugen
dur] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Number of audio busses.

 NumAudioBuses [InitialisationRate]
-}
numAudioBuses :: Ugen
numAudioBuses :: Ugen
numAudioBuses = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"NumAudioBuses" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Number of open buffers.

 NumBuffers [InitialisationRate]
-}
numBuffers :: Ugen
numBuffers :: Ugen
numBuffers = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"NumBuffers" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Number of control busses.

 NumControlBuses [InitialisationRate]
-}
numControlBuses :: Ugen
numControlBuses :: Ugen
numControlBuses = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"NumControlBuses" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Number of input busses.

 NumInputBuses [InitialisationRate]
-}
numInputBuses :: Ugen
numInputBuses :: Ugen
numInputBuses = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"NumInputBuses" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Number of output busses.

 NumOutputBuses [InitialisationRate]
-}
numOutputBuses :: Ugen
numOutputBuses :: Ugen
numOutputBuses = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"NumOutputBuses" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Number of currently running synths.

 NumRunningSynths [InitialisationRate,ControlRate]
-}
numRunningSynths :: Ugen
numRunningSynths :: Ugen
numRunningSynths = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"NumRunningSynths" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Write a signal to a bus with sample accurate timing.

 OffsetOut [ControlRate,AudioRate] bus=0 *channelsArray=0;    MCE=1, FILTER: TRUE
-}
offsetOut :: Ugen -> Ugen -> Ugen
offsetOut :: Ugen -> Ugen -> Ugen
offsetOut Ugen
bus Ugen
input = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"OffsetOut" [Ugen
bus] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
input]) Int
0 (Int -> Special
Special Int
0) UgenId
NoId

{- | One pole filter.

 OnePole [ControlRate,AudioRate] in=0 coef=0.5;    FILTER: TRUE
-}
onePole :: Ugen -> Ugen -> Ugen
onePole :: Ugen -> Ugen -> Ugen
onePole Ugen
in_ Ugen
coef = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"OnePole" [Ugen
in_, Ugen
coef] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | One zero filter.

 OneZero [ControlRate,AudioRate] in=0 coef=0.5;    FILTER: TRUE
-}
oneZero :: Ugen -> Ugen -> Ugen
oneZero :: Ugen -> Ugen -> Ugen
oneZero Ugen
in_ Ugen
coef = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"OneZero" [Ugen
in_, Ugen
coef] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Onset detector

 Onsets [ControlRate] chain=0 threshold=0.5 odftype=3 relaxtime=1 floor=0.1 mingap=10 medianspan=11 whtype=1 rawodf=0
-}
onsets :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
onsets :: Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
onsets Ugen
chain Ugen
threshold Ugen
odftype Ugen
relaxtime Ugen
floor_ Ugen
mingap Ugen
medianspan Ugen
whtype Ugen
rawodf = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"Onsets" [Ugen
chain, Ugen
threshold, Ugen
odftype, Ugen
relaxtime, Ugen
floor_, Ugen
mingap, Ugen
medianspan, Ugen
whtype, Ugen
rawodf] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Interpolating wavetable oscillator.

 Osc [ControlRate,AudioRate] bufnum=0 freq=440 phase=0
-}
osc :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
osc :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
osc Rate
rate Ugen
bufnum Ugen
freq Ugen
phase = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Osc" [Ugen
bufnum, Ugen
freq, Ugen
phase] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Noninterpolating wavetable oscillator.

 OscN [ControlRate,AudioRate] bufnum=0 freq=440 phase=0
-}
oscN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
oscN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
oscN Rate
rate Ugen
bufnum Ugen
freq Ugen
phase = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"OscN" [Ugen
bufnum, Ugen
freq, Ugen
phase] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Write a signal to a bus.

 Out [ControlRate,AudioRate] bus=0 *channelsArray=0;    MCE=1, FILTER: TRUE
-}
out :: Ugen -> Ugen -> Ugen
out :: Ugen -> Ugen -> Ugen
out Ugen
bus Ugen
input = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"Out" [Ugen
bus] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
input]) Int
0 (Int -> Special
Special Int
0) UgenId
NoId

{- | Very fast sine grain with a parabolic envelope

 PSinGrain [AudioRate] freq=440 dur=0.2 amp=0.1
-}
pSinGrain :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
pSinGrain :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
pSinGrain Rate
rate Ugen
freq Ugen
dur Ugen
amp = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"PSinGrain" [Ugen
freq, Ugen
dur, Ugen
amp] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Complex addition.

 PV_Add [ControlRate] bufferA=0 bufferB=0
-}
pv_Add :: Ugen -> Ugen -> Ugen
pv_Add :: Ugen -> Ugen -> Ugen
pv_Add Ugen
bufferA Ugen
bufferB = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_Add" [Ugen
bufferA, Ugen
bufferB] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Scramble bins.

 PV_BinScramble [ControlRate] buffer=0 wipe=0 width=0.2 trig=0;    NONDET
-}
pv_BinScrambleId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_BinScrambleId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_BinScrambleId a
z Ugen
buffer Ugen
wipe Ugen
width Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_BinScramble" [Ugen
buffer, Ugen
wipe, Ugen
width, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of PV_BinScramble.
pv_BinScrambleM :: Uid m => Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
pv_BinScrambleM :: forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
pv_BinScrambleM = (Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn4 Ugen Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d e.
Uid m =>
(Int -> Fn4 a b c d e) -> Fn4 a b c d (m e)
liftUid4 Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_BinScrambleId

-- | Unsafe variant of PV_BinScramble.
pv_BinScramble :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_BinScramble :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_BinScramble = (Ugen -> Ugen -> Ugen -> Ugen -> IO Ugen)
-> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c d r.
(a -> b -> c -> d -> IO r) -> a -> b -> c -> d -> r
liftUnsafe4 Ugen -> Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
pv_BinScrambleM

{- | Shift and stretch bin position.

 PV_BinShift [ControlRate] buffer=0 stretch=1 shift=0 interp=0
-}
pv_BinShift :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_BinShift :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_BinShift Ugen
buffer Ugen
stretch Ugen
shift Ugen
interp = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_BinShift" [Ugen
buffer, Ugen
stretch, Ugen
shift, Ugen
interp] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Combine low and high bins from two inputs.

 PV_BinWipe [ControlRate] bufferA=0 bufferB=0 wipe=0
-}
pv_BinWipe :: Ugen -> Ugen -> Ugen -> Ugen
pv_BinWipe :: Ugen -> Ugen -> Ugen -> Ugen
pv_BinWipe Ugen
bufferA Ugen
bufferB Ugen
wipe = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_BinWipe" [Ugen
bufferA, Ugen
bufferB, Ugen
wipe] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Zero bins.

 PV_BrickWall [ControlRate] buffer=0 wipe=0
-}
pv_BrickWall :: Ugen -> Ugen -> Ugen
pv_BrickWall :: Ugen -> Ugen -> Ugen
pv_BrickWall Ugen
buffer Ugen
wipe = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_BrickWall" [Ugen
buffer, Ugen
wipe] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Complex plane attack.

 PV_ConformalMap [ControlRate] buffer=0 areal=0 aimag=0
-}
pv_ConformalMap :: Ugen -> Ugen -> Ugen -> Ugen
pv_ConformalMap :: Ugen -> Ugen -> Ugen -> Ugen
pv_ConformalMap Ugen
buffer Ugen
areal Ugen
aimag = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_ConformalMap" [Ugen
buffer, Ugen
areal, Ugen
aimag] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Complex conjugate

 PV_Conj [ControlRate] buffer=0
-}
pv_Conj :: Ugen -> Ugen
pv_Conj :: Ugen -> Ugen
pv_Conj Ugen
buffer = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_Conj" [Ugen
buffer] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Copy an FFT buffer

 PV_Copy [ControlRate] bufferA=0 bufferB=0
-}
pv_Copy :: Ugen -> Ugen -> Ugen
pv_Copy :: Ugen -> Ugen -> Ugen
pv_Copy Ugen
bufferA Ugen
bufferB = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_Copy" [Ugen
bufferA, Ugen
bufferB] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Copy magnitudes and phases.

 PV_CopyPhase [ControlRate] bufferA=0 bufferB=0
-}
pv_CopyPhase :: Ugen -> Ugen -> Ugen
pv_CopyPhase :: Ugen -> Ugen -> Ugen
pv_CopyPhase Ugen
bufferA Ugen
bufferB = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_CopyPhase" [Ugen
bufferA, Ugen
bufferB] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Random phase shifting.

 PV_Diffuser [ControlRate] buffer=0 trig=0
-}
pv_Diffuser :: Ugen -> Ugen -> Ugen
pv_Diffuser :: Ugen -> Ugen -> Ugen
pv_Diffuser Ugen
buffer Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_Diffuser" [Ugen
buffer, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Complex division

 PV_Div [ControlRate] bufferA=0 bufferB=0
-}
pv_Div :: Ugen -> Ugen -> Ugen
pv_Div :: Ugen -> Ugen -> Ugen
pv_Div Ugen
bufferA Ugen
bufferB = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_Div" [Ugen
bufferA, Ugen
bufferB] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{-
-- | FFT onset detector.
--
--  PV_HainsworthFoote [ControlRate,AudioRate] maxSize=0
pv_HainsworthFoote :: Ugen -> Ugen
pv_HainsworthFoote maxSize = mkUgen Nothing [ControlRate,AudioRate] (Left ControlRate) "PV_HainsworthFoote" [maxSize] Nothing 1 (Special 0) NoId

-- | FFT feature detector for onset detection.
--
--  PV_JensenAndersen [ControlRate,AudioRate] maxSize=0
pv_JensenAndersen :: Ugen -> Ugen
pv_JensenAndersen maxSize = mkUgen Nothing [ControlRate,AudioRate] (Left ControlRate) "PV_JensenAndersen" [maxSize] Nothing 1 (Special 0) NoId
-}

{- | Pass bins which are a local maximum.

 PV_LocalMax [ControlRate] buffer=0 threshold=0
-}
pv_LocalMax :: Ugen -> Ugen -> Ugen
pv_LocalMax :: Ugen -> Ugen -> Ugen
pv_LocalMax Ugen
buffer Ugen
threshold = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_LocalMax" [Ugen
buffer, Ugen
threshold] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Pass bins above a threshold.

 PV_MagAbove [ControlRate] buffer=0 threshold=0
-}
pv_MagAbove :: Ugen -> Ugen -> Ugen
pv_MagAbove :: Ugen -> Ugen -> Ugen
pv_MagAbove Ugen
buffer Ugen
threshold = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_MagAbove" [Ugen
buffer, Ugen
threshold] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Pass bins below a threshold.

 PV_MagBelow [ControlRate] buffer=0 threshold=0
-}
pv_MagBelow :: Ugen -> Ugen -> Ugen
pv_MagBelow :: Ugen -> Ugen -> Ugen
pv_MagBelow Ugen
buffer Ugen
threshold = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_MagBelow" [Ugen
buffer, Ugen
threshold] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Clip bins to a threshold.

 PV_MagClip [ControlRate] buffer=0 threshold=0
-}
pv_MagClip :: Ugen -> Ugen -> Ugen
pv_MagClip :: Ugen -> Ugen -> Ugen
pv_MagClip Ugen
buffer Ugen
threshold = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_MagClip" [Ugen
buffer, Ugen
threshold] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Division of magnitudes

 PV_MagDiv [ControlRate] bufferA=0 bufferB=0 zeroed=0.0001
-}
pv_MagDiv :: Ugen -> Ugen -> Ugen -> Ugen
pv_MagDiv :: Ugen -> Ugen -> Ugen -> Ugen
pv_MagDiv Ugen
bufferA Ugen
bufferB Ugen
zeroed = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_MagDiv" [Ugen
bufferA, Ugen
bufferB, Ugen
zeroed] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Freeze magnitudes.

 PV_MagFreeze [ControlRate] buffer=0 freeze=0
-}
pv_MagFreeze :: Ugen -> Ugen -> Ugen
pv_MagFreeze :: Ugen -> Ugen -> Ugen
pv_MagFreeze Ugen
buffer Ugen
freeze = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_MagFreeze" [Ugen
buffer, Ugen
freeze] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Multiply magnitudes.

 PV_MagMul [ControlRate] bufferA=0 bufferB=0
-}
pv_MagMul :: Ugen -> Ugen -> Ugen
pv_MagMul :: Ugen -> Ugen -> Ugen
pv_MagMul Ugen
bufferA Ugen
bufferB = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_MagMul" [Ugen
bufferA, Ugen
bufferB] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Multiply magnitudes by noise.

 PV_MagNoise [ControlRate] buffer=0
-}
pv_MagNoise :: Ugen -> Ugen
pv_MagNoise :: Ugen -> Ugen
pv_MagNoise Ugen
buffer = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_MagNoise" [Ugen
buffer] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | shift and stretch magnitude bin position.

 PV_MagShift [ControlRate] buffer=0 stretch=1 shift=0
-}
pv_MagShift :: Ugen -> Ugen -> Ugen -> Ugen
pv_MagShift :: Ugen -> Ugen -> Ugen -> Ugen
pv_MagShift Ugen
buffer Ugen
stretch Ugen
shift = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_MagShift" [Ugen
buffer, Ugen
stretch, Ugen
shift] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Average magnitudes across bins.

 PV_MagSmear [ControlRate] buffer=0 bins=0
-}
pv_MagSmear :: Ugen -> Ugen -> Ugen
pv_MagSmear :: Ugen -> Ugen -> Ugen
pv_MagSmear Ugen
buffer Ugen
bins = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_MagSmear" [Ugen
buffer, Ugen
bins] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Square magnitudes.

 PV_MagSquared [ControlRate] buffer=0
-}
pv_MagSquared :: Ugen -> Ugen
pv_MagSquared :: Ugen -> Ugen
pv_MagSquared Ugen
buffer = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_MagSquared" [Ugen
buffer] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Maximum magnitude.

 PV_Max [ControlRate] bufferA=0 bufferB=0
-}
pv_Max :: Ugen -> Ugen -> Ugen
pv_Max :: Ugen -> Ugen -> Ugen
pv_Max Ugen
bufferA Ugen
bufferB = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_Max" [Ugen
bufferA, Ugen
bufferB] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Minimum magnitude.

 PV_Min [ControlRate] bufferA=0 bufferB=0
-}
pv_Min :: Ugen -> Ugen -> Ugen
pv_Min :: Ugen -> Ugen -> Ugen
pv_Min Ugen
bufferA Ugen
bufferB = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_Min" [Ugen
bufferA, Ugen
bufferB] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Complex multiply.

 PV_Mul [ControlRate] bufferA=0 bufferB=0
-}
pv_Mul :: Ugen -> Ugen -> Ugen
pv_Mul :: Ugen -> Ugen -> Ugen
pv_Mul Ugen
bufferA Ugen
bufferB = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_Mul" [Ugen
bufferA, Ugen
bufferB] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Shift phase.

 PV_PhaseShift [ControlRate] buffer=0 shift=0 integrate=0
-}
pv_PhaseShift :: Ugen -> Ugen -> Ugen -> Ugen
pv_PhaseShift :: Ugen -> Ugen -> Ugen -> Ugen
pv_PhaseShift Ugen
buffer Ugen
shift Ugen
integrate = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_PhaseShift" [Ugen
buffer, Ugen
shift, Ugen
integrate] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Shift phase by 270 degrees.

 PV_PhaseShift270 [ControlRate] buffer=0
-}
pv_PhaseShift270 :: Ugen -> Ugen
pv_PhaseShift270 :: Ugen -> Ugen
pv_PhaseShift270 Ugen
buffer = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_PhaseShift270" [Ugen
buffer] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Shift phase by 90 degrees.

 PV_PhaseShift90 [ControlRate] buffer=0
-}
pv_PhaseShift90 :: Ugen -> Ugen
pv_PhaseShift90 :: Ugen -> Ugen
pv_PhaseShift90 Ugen
buffer = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_PhaseShift90" [Ugen
buffer] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Pass random bins.

 PV_RandComb [ControlRate] buffer=0 wipe=0 trig=0;    NONDET
-}
pv_RandCombId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
pv_RandCombId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
pv_RandCombId a
z Ugen
buffer Ugen
wipe Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_RandComb" [Ugen
buffer, Ugen
wipe, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of PV_RandComb.
pv_RandCombM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
pv_RandCombM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
pv_RandCombM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
pv_RandCombId

-- | Unsafe variant of PV_RandComb.
pv_RandComb :: Ugen -> Ugen -> Ugen -> Ugen
pv_RandComb :: Ugen -> Ugen -> Ugen -> Ugen
pv_RandComb = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
pv_RandCombM

{- | Crossfade in random bin order.

 PV_RandWipe [ControlRate] bufferA=0 bufferB=0 wipe=0 trig=0;    NONDET
-}
pv_RandWipeId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_RandWipeId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_RandWipeId a
z Ugen
bufferA Ugen
bufferB Ugen
wipe Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_RandWipe" [Ugen
bufferA, Ugen
bufferB, Ugen
wipe, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of PV_RandWipe.
pv_RandWipeM :: Uid m => Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
pv_RandWipeM :: forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
pv_RandWipeM = (Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn4 Ugen Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d e.
Uid m =>
(Int -> Fn4 a b c d e) -> Fn4 a b c d (m e)
liftUid4 Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_RandWipeId

-- | Unsafe variant of PV_RandWipe.
pv_RandWipe :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_RandWipe :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_RandWipe = (Ugen -> Ugen -> Ugen -> Ugen -> IO Ugen)
-> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c d r.
(a -> b -> c -> d -> IO r) -> a -> b -> c -> d -> r
liftUnsafe4 Ugen -> Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *).
Uid m =>
Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
pv_RandWipeM

{- | Make gaps in spectrum.

 PV_RectComb [ControlRate] buffer=0 numTeeth=0 phase=0 width=0.5
-}
pv_RectComb :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_RectComb :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_RectComb Ugen
buffer Ugen
numTeeth Ugen
phase Ugen
width = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_RectComb" [Ugen
buffer, Ugen
numTeeth, Ugen
phase, Ugen
width] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Make gaps in spectrum.

 PV_RectComb2 [ControlRate] bufferA=0 bufferB=0 numTeeth=0 phase=0 width=0.5
-}
pv_RectComb2 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_RectComb2 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pv_RectComb2 Ugen
bufferA Ugen
bufferB Ugen
numTeeth Ugen
phase Ugen
width = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PV_RectComb2" [Ugen
bufferA, Ugen
bufferB, Ugen
numTeeth, Ugen
phase, Ugen
width] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Two channel equal power pan.

 Pan2 [ControlRate,AudioRate] in=0 pos=0 level=1;    FILTER: TRUE
-}
pan2 :: Ugen -> Ugen -> Ugen -> Ugen
pan2 :: Ugen -> Ugen -> Ugen -> Ugen
pan2 Ugen
in_ Ugen
pos Ugen
level = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Pan2" [Ugen
in_, Ugen
pos, Ugen
level] Maybe [Ugen]
forall a. Maybe a
Nothing Int
2 (Int -> Special
Special Int
0) UgenId
NoId

{- | Four channel equal power pan.

 Pan4 [ControlRate,AudioRate] in=0 xpos=0 ypos=0 level=1
-}
pan4 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pan4 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pan4 Rate
rate Ugen
in_ Ugen
xpos Ugen
ypos Ugen
level = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Pan4" [Ugen
in_, Ugen
xpos, Ugen
ypos, Ugen
level] Maybe [Ugen]
forall a. Maybe a
Nothing Int
4 (Int -> Special
Special Int
0) UgenId
NoId

{- | Azimuth panner

 PanAz [ControlRate,AudioRate] in=0 pos=0 level=1 width=2 orientation=0.5;    NC INPUT: True, FILTER: TRUE
-}
panAz :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
panAz :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
panAz Int
numChannels Ugen
in_ Ugen
pos Ugen
level Ugen
width Ugen
orientation = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"PanAz" [Ugen
in_, Ugen
pos, Ugen
level, Ugen
width, Ugen
orientation] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Ambisonic B-format panner.

 PanB [ControlRate,AudioRate] in=0 azimuth=0 elevation=0 gain=1
-}
panB :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
panB :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
panB Rate
rate Ugen
in_ Ugen
azimuth Ugen
elevation Ugen
gain = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"PanB" [Ugen
in_, Ugen
azimuth, Ugen
elevation, Ugen
gain] Maybe [Ugen]
forall a. Maybe a
Nothing Int
4 (Int -> Special
Special Int
0) UgenId
NoId

{- | 2D Ambisonic B-format panner.

 PanB2 [ControlRate,AudioRate] in=0 azimuth=0 gain=1;    FILTER: TRUE
-}
panB2 :: Ugen -> Ugen -> Ugen -> Ugen
panB2 :: Ugen -> Ugen -> Ugen -> Ugen
panB2 Ugen
in_ Ugen
azimuth Ugen
gain = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"PanB2" [Ugen
in_, Ugen
azimuth, Ugen
gain] Maybe [Ugen]
forall a. Maybe a
Nothing Int
3 (Int -> Special
Special Int
0) UgenId
NoId

{- | Real-time partitioned convolution

 PartConv [AudioRate] in=0 fftsize=0 irbufnum=0
-}
partConv :: Ugen -> Ugen -> Ugen -> Ugen
partConv :: Ugen -> Ugen -> Ugen -> Ugen
partConv Ugen
in_ Ugen
fftsize Ugen
irbufnum = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"PartConv" [Ugen
in_, Ugen
fftsize, Ugen
irbufnum] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | When triggered, pauses a node.

 Pause [ControlRate] gate=0 id=0
-}
pause :: Ugen -> Ugen -> Ugen
pause :: Ugen -> Ugen -> Ugen
pause Ugen
gate_ Ugen
id_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"Pause" [Ugen
gate_, Ugen
id_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | When triggered, pause enclosing synth.

 PauseSelf [ControlRate] in=0
-}
pauseSelf :: Ugen -> Ugen
pauseSelf :: Ugen -> Ugen
pauseSelf Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PauseSelf" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | FIXME: PauseSelfWhenDone purpose.

 PauseSelfWhenDone [ControlRate] src=0
-}
pauseSelfWhenDone :: Ugen -> Ugen
pauseSelfWhenDone :: Ugen -> Ugen
pauseSelfWhenDone Ugen
src = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"PauseSelfWhenDone" [Ugen
src] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Track peak signal amplitude.

 Peak [ControlRate,AudioRate] in=0 trig=0;    FILTER: TRUE
-}
peak :: Ugen -> Ugen -> Ugen
peak :: Ugen -> Ugen -> Ugen
peak Ugen
in_ Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Peak" [Ugen
in_, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Track peak signal amplitude.

 PeakFollower [ControlRate,AudioRate] in=0 decay=0.999;    FILTER: TRUE
-}
peakFollower :: Ugen -> Ugen -> Ugen
peakFollower :: Ugen -> Ugen -> Ugen
peakFollower Ugen
in_ Ugen
decay_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"PeakFollower" [Ugen
in_, Ugen
decay_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | A resettable linear ramp between two levels.

 Phasor [ControlRate,AudioRate] trig=0 rate=1 start=0 end=1 resetPos=0
-}
phasor :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
phasor :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
phasor Rate
rate Ugen
trig_ Ugen
rate_ Ugen
start Ugen
end Ugen
resetPos = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Phasor" [Ugen
trig_, Ugen
rate_, Ugen
start, Ugen
end, Ugen
resetPos] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Pink Noise.

 PinkNoise [ControlRate,AudioRate] ;    NONDET
-}
pinkNoiseId :: ID a => a -> Rate -> Ugen
pinkNoiseId :: forall a. ID a => a -> Rate -> Ugen
pinkNoiseId a
z Rate
rate = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"PinkNoise" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of PinkNoise.
pinkNoiseM :: Uid m => Rate -> m Ugen
pinkNoiseM :: forall (m :: * -> *). Uid m => Rate -> m Ugen
pinkNoiseM = (Int -> Rate -> Ugen) -> Fn1 Rate (m Ugen)
forall (m :: * -> *) a b. Uid m => (Int -> Fn1 a b) -> Fn1 a (m b)
liftUid1 Int -> Rate -> Ugen
forall a. ID a => a -> Rate -> Ugen
pinkNoiseId

-- | Unsafe variant of PinkNoise.
pinkNoise :: Rate -> Ugen
pinkNoise :: Rate -> Ugen
pinkNoise = (Rate -> IO Ugen) -> Rate -> Ugen
forall a r. (a -> IO r) -> a -> r
liftUnsafe1 Rate -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> m Ugen
pinkNoiseM

{- | Autocorrelation pitch follower

 Pitch [ControlRate] in=0 initFreq=440 minFreq=60 maxFreq=4000 execFreq=100 maxBinsPerOctave=16 median=1 ampThreshold=0.01 peakThreshold=0.5 downSample=1 clar=0
-}
pitch :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pitch :: Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
pitch Ugen
in_ Ugen
initFreq Ugen
minFreq Ugen
maxFreq Ugen
execFreq Ugen
maxBinsPerOctave Ugen
median_ Ugen
ampThreshold Ugen
peakThreshold Ugen
downSample Ugen
clar = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"Pitch" [Ugen
in_, Ugen
initFreq, Ugen
minFreq, Ugen
maxFreq, Ugen
execFreq, Ugen
maxBinsPerOctave, Ugen
median_, Ugen
ampThreshold, Ugen
peakThreshold, Ugen
downSample, Ugen
clar] Maybe [Ugen]
forall a. Maybe a
Nothing Int
2 (Int -> Special
Special Int
0) UgenId
NoId

{- | Time domain pitch shifter.

 PitchShift [AudioRate] in=0 windowSize=0.2 pitchRatio=1 pitchDispersion=0 timeDispersion=0;    FILTER: TRUE
-}
pitchShift :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pitchShift :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pitchShift Ugen
in_ Ugen
windowSize Ugen
pitchRatio Ugen
pitchDispersion Ugen
timeDispersion = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"PitchShift" [Ugen
in_, Ugen
windowSize, Ugen
pitchRatio, Ugen
pitchDispersion, Ugen
timeDispersion] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Sample playback oscillator.

 PlayBuf [ControlRate,AudioRate] bufnum=0 rate=1 trigger=1 startPos=0 loop=0 doneAction=0;    NC INPUT: True, ENUMERATION INPUTS: 4=Loop, 5=DoneAction
-}
playBuf :: Int -> Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Loop Ugen -> DoneAction Ugen -> Ugen
playBuf :: Int
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Loop Ugen
-> DoneAction Ugen
-> Ugen
playBuf Int
numChannels Rate
rate Ugen
bufnum Ugen
rate_ Ugen
trigger Ugen
startPos Loop Ugen
loop DoneAction Ugen
doneAction = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"PlayBuf" [Ugen
bufnum, Ugen
rate_, Ugen
trigger, Ugen
startPos, (Loop Ugen -> Ugen
forall t. Num t => Loop t -> t
from_loop Loop Ugen
loop), (DoneAction Ugen -> Ugen
forall t. Num t => DoneAction t -> t
from_done_action DoneAction Ugen
doneAction)] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | A Karplus-Strong Ugen

 Pluck [AudioRate] in=0 trig=1 maxdelaytime=0.2 delaytime=0.2 decaytime=1 coef=0.5;    FILTER: TRUE
-}
pluck :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pluck :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
pluck Ugen
in_ Ugen
trig_ Ugen
maxdelaytime Ugen
delaytime Ugen
decaytime Ugen
coef = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Pluck" [Ugen
in_, Ugen
trig_, Ugen
maxdelaytime, Ugen
delaytime, Ugen
decaytime, Ugen
coef] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{-
-- | Print the current output value of a Ugen
--
--  Poll [ControlRate,AudioRate] trig=0 in=0 trigid=-1 label=0;    FILTER: TRUE, REORDERS INPUTS: [0,1,3,2]
poll :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
poll trig_ in_ trigid label_ = mkUgen Nothing [ControlRate,AudioRate] (Right [1]) "Poll" [trig_,in_,trigid,label_] Nothing 1 (Special 0) NoId
-}

{- | Band limited pulse wave.

 Pulse [ControlRate,AudioRate] freq=440 width=0.5
-}
pulse :: Rate -> Ugen -> Ugen -> Ugen
pulse :: Rate -> Ugen -> Ugen -> Ugen
pulse Rate
rate Ugen
freq Ugen
width = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Pulse" [Ugen
freq, Ugen
width] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Pulse counter.

 PulseCount [ControlRate,AudioRate] trig=0 reset=0;    FILTER: TRUE
-}
pulseCount :: Ugen -> Ugen -> Ugen
pulseCount :: Ugen -> Ugen -> Ugen
pulseCount Ugen
trig_ Ugen
reset = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"PulseCount" [Ugen
trig_, Ugen
reset] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Pulse divider.

 PulseDivider [ControlRate,AudioRate] trig=0 div=2 start=0;    FILTER: TRUE
-}
pulseDivider :: Ugen -> Ugen -> Ugen -> Ugen
pulseDivider :: Ugen -> Ugen -> Ugen -> Ugen
pulseDivider Ugen
trig_ Ugen
div_ Ugen
start = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"PulseDivider" [Ugen
trig_, Ugen
div_, Ugen
start] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | General quadratic map chaotic generator

 QuadC [AudioRate] freq=22050 a=1 b=-1 c=-0.75 xi=0
-}
quadC :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
quadC :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
quadC Rate
rate Ugen
freq Ugen
a Ugen
b Ugen
c Ugen
xi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"QuadC" [Ugen
freq, Ugen
a, Ugen
b, Ugen
c, Ugen
xi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | General quadratic map chaotic generator

 QuadL [AudioRate] freq=22050 a=1 b=-1 c=-0.75 xi=0
-}
quadL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
quadL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
quadL Rate
rate Ugen
freq Ugen
a Ugen
b Ugen
c Ugen
xi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"QuadL" [Ugen
freq, Ugen
a, Ugen
b, Ugen
c, Ugen
xi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | General quadratic map chaotic generator

 QuadN [AudioRate] freq=22050 a=1 b=-1 c=-0.75 xi=0
-}
quadN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
quadN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
quadN Rate
rate Ugen
freq Ugen
a Ugen
b Ugen
c Ugen
xi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"QuadN" [Ugen
freq, Ugen
a, Ugen
b, Ugen
c, Ugen
xi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | A resonant high pass filter.

 RHPF [ControlRate,AudioRate] in=0 freq=440 rq=1;    FILTER: TRUE
-}
rhpf :: Ugen -> Ugen -> Ugen -> Ugen
rhpf :: Ugen -> Ugen -> Ugen -> Ugen
rhpf Ugen
in_ Ugen
freq Ugen
rq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"RHPF" [Ugen
in_, Ugen
freq, Ugen
rq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | A resonant low pass filter.

 RLPF [ControlRate,AudioRate] in=0 freq=440 rq=1;    FILTER: TRUE
-}
rlpf :: Ugen -> Ugen -> Ugen -> Ugen
rlpf :: Ugen -> Ugen -> Ugen -> Ugen
rlpf Ugen
in_ Ugen
freq Ugen
rq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"RLPF" [Ugen
in_, Ugen
freq, Ugen
rq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Number of radians per sample.

 RadiansPerSample [InitialisationRate]
-}
radiansPerSample :: Ugen
radiansPerSample :: Ugen
radiansPerSample = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"RadiansPerSample" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Break a continuous signal into line segments

 Ramp [ControlRate,AudioRate] in=0 lagTime=0.1;    FILTER: TRUE
-}
ramp :: Ugen -> Ugen -> Ugen
ramp :: Ugen -> Ugen -> Ugen
ramp Ugen
in_ Ugen
lagTime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Ramp" [Ugen
in_, Ugen
lagTime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Single random number generator.

 Rand [InitialisationRate] lo=0 hi=1;    NONDET
-}
randId :: ID a => a -> Ugen -> Ugen -> Ugen
randId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen
randId a
z Ugen
lo Ugen
hi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"Rand" [Ugen
lo, Ugen
hi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Rand.
randM :: Uid m => Ugen -> Ugen -> m Ugen
randM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
randM = (Int -> Ugen -> Ugen -> Ugen) -> Fn2 Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c.
Uid m =>
(Int -> Fn2 a b c) -> Fn2 a b (m c)
liftUid2 Int -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen
randId

-- | Unsafe variant of Rand.
rand :: Ugen -> Ugen -> Ugen
rand :: Ugen -> Ugen -> Ugen
rand = (Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen
forall a b r. (a -> b -> IO r) -> a -> b -> r
liftUnsafe2 Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> m Ugen
randM

{- | Set the synth's random generator ID.

 RandID [InitialisationRate,ControlRate] id=0
-}
randID :: Rate -> Ugen -> Ugen
randID :: Rate -> Ugen -> Ugen
randID Rate
rate Ugen
id_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"RandID" [Ugen
id_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
0 (Int -> Special
Special Int
0) UgenId
NoId

{- | Sets the synth's random generator seed.

 RandSeed [InitialisationRate,ControlRate,AudioRate] trig=0 seed=56789
-}
randSeed :: Rate -> Ugen -> Ugen -> Ugen
randSeed :: Rate -> Ugen -> Ugen -> Ugen
randSeed Rate
rate Ugen
trig_ Ugen
seed = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"RandSeed" [Ugen
trig_, Ugen
seed] Maybe [Ugen]
forall a. Maybe a
Nothing Int
0 (Int -> Special
Special Int
0) UgenId
NoId

{- | Record or overdub into a Buffer.

 RecordBuf [ControlRate,AudioRate] bufnum=0 offset=0 recLevel=1 preLevel=0 run=1 loop=1 trigger=1 doneAction=0 *inputArray=0;    MCE=1, REORDERS INPUTS: [8,0,1,2,3,4,5,6,7], ENUMERATION INPUTS: 5=Loop, 7=DoneAction
-}
recordBuf :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Loop Ugen -> Ugen -> DoneAction Ugen -> Ugen -> Ugen
recordBuf :: Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Loop Ugen
-> Ugen
-> DoneAction Ugen
-> Ugen
-> Ugen
recordBuf Rate
rate Ugen
bufnum Ugen
offset Ugen
recLevel Ugen
preLevel Ugen
run Loop Ugen
loop Ugen
trigger DoneAction Ugen
doneAction Ugen
inputArray = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"RecordBuf" [Ugen
bufnum, Ugen
offset, Ugen
recLevel, Ugen
preLevel, Ugen
run, (Loop Ugen -> Ugen
forall t. Num t => Loop t -> t
from_loop Loop Ugen
loop), Ugen
trigger, (DoneAction Ugen -> Ugen
forall t. Num t => DoneAction t -> t
from_done_action DoneAction Ugen
doneAction)] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
inputArray]) Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Send signal to a bus, overwriting previous contents.

 ReplaceOut [ControlRate,AudioRate] bus=0 *channelsArray=0;    MCE=1, FILTER: TRUE
-}
replaceOut :: Ugen -> Ugen -> Ugen
replaceOut :: Ugen -> Ugen -> Ugen
replaceOut Ugen
bus Ugen
input = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"ReplaceOut" [Ugen
bus] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
input]) Int
0 (Int -> Special
Special Int
0) UgenId
NoId

{- | Resonant filter.

 Resonz [ControlRate,AudioRate] in=0 freq=440 bwr=1;    FILTER: TRUE
-}
resonz :: Ugen -> Ugen -> Ugen -> Ugen
resonz :: Ugen -> Ugen -> Ugen -> Ugen
resonz Ugen
in_ Ugen
freq Ugen
bwr = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Resonz" [Ugen
in_, Ugen
freq, Ugen
bwr] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Ringing filter.

 Ringz [ControlRate,AudioRate] in=0 freq=440 decaytime=1;    FILTER: TRUE
-}
ringz :: Ugen -> Ugen -> Ugen -> Ugen
ringz :: Ugen -> Ugen -> Ugen -> Ugen
ringz Ugen
in_ Ugen
freq Ugen
decaytime = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Ringz" [Ugen
in_, Ugen
freq, Ugen
decaytime] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Rotate a sound field.

 Rotate2 [ControlRate,AudioRate] x=0 y=0 pos=0;    FILTER: TRUE
-}
rotate2 :: Ugen -> Ugen -> Ugen -> Ugen
rotate2 :: Ugen -> Ugen -> Ugen -> Ugen
rotate2 Ugen
x Ugen
y Ugen
pos = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1]) String
"Rotate2" [Ugen
x, Ugen
y, Ugen
pos] Maybe [Ugen]
forall a. Maybe a
Nothing Int
2 (Int -> Special
Special Int
0) UgenId
NoId

{- | Track maximum level.

 RunningMax [ControlRate,AudioRate] in=0 trig=0;    FILTER: TRUE
-}
runningMax :: Ugen -> Ugen -> Ugen
runningMax :: Ugen -> Ugen -> Ugen
runningMax Ugen
in_ Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"RunningMax" [Ugen
in_, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Track minimum level.

 RunningMin [ControlRate,AudioRate] in=0 trig=0;    FILTER: TRUE
-}
runningMin :: Ugen -> Ugen -> Ugen
runningMin :: Ugen -> Ugen -> Ugen
runningMin Ugen
in_ Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"RunningMin" [Ugen
in_, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Running sum over n frames

 RunningSum [ControlRate,AudioRate] in=0 numsamp=40;    FILTER: TRUE
-}
runningSum :: Ugen -> Ugen -> Ugen
runningSum :: Ugen -> Ugen -> Ugen
runningSum Ugen
in_ Ugen
numsamp = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"RunningSum" [Ugen
in_, Ugen
numsamp] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Second order filter section (biquad).

 SOS [ControlRate,AudioRate] in=0 a0=0 a1=0 a2=0 b1=0 b2=0;    FILTER: TRUE
-}
sos :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
sos :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
sos Ugen
in_ Ugen
a0 Ugen
a1 Ugen
a2 Ugen
b1 Ugen
b2 = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"SOS" [Ugen
in_, Ugen
a0, Ugen
a1, Ugen
a2, Ugen
b1, Ugen
b2] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Duration of one sample.

 SampleDur [InitialisationRate]
-}
sampleDur :: Ugen
sampleDur :: Ugen
sampleDur = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"SampleDur" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Server sample rate.

 SampleRate [InitialisationRate]
-}
sampleRate :: Ugen
sampleRate :: Ugen
sampleRate = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"SampleRate" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Remove infinity, NaN, and denormals

 Sanitize [ControlRate,AudioRate] in=0 replace=0;    FILTER: TRUE
-}
sanitize :: Ugen -> Ugen -> Ugen
sanitize :: Ugen -> Ugen -> Ugen
sanitize Ugen
in_ Ugen
replace = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Sanitize" [Ugen
in_, Ugen
replace] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Band limited sawtooth.

 Saw [ControlRate,AudioRate] freq=440
-}
saw :: Rate -> Ugen -> Ugen
saw :: Rate -> Ugen -> Ugen
saw Rate
rate Ugen
freq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Saw" [Ugen
freq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Schmidt trigger.

 Schmidt [InitialisationRate,ControlRate,AudioRate] in=0 lo=0 hi=1;    FILTER: TRUE
-}
schmidt :: Ugen -> Ugen -> Ugen -> Ugen
schmidt :: Ugen -> Ugen -> Ugen -> Ugen
schmidt Ugen
in_ Ugen
lo Ugen
hi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Schmidt" [Ugen
in_, Ugen
lo, Ugen
hi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Select output from an array of inputs.

 Select [InitialisationRate,ControlRate,AudioRate] which=0 *array=0;    MCE=1, FILTER: TRUE
-}
select :: Ugen -> Ugen -> Ugen
select :: Ugen -> Ugen -> Ugen
select Ugen
which Ugen
array = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1]) String
"Select" [Ugen
which] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
array]) Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Send a trigger message from the server back to the client.

 SendTrig [ControlRate,AudioRate] in=0 id=0 value=0;    FILTER: TRUE
-}
sendTrig :: Ugen -> Ugen -> Ugen -> Ugen
sendTrig :: Ugen -> Ugen -> Ugen -> Ugen
sendTrig Ugen
in_ Ugen
id_ Ugen
value = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"SendTrig" [Ugen
in_, Ugen
id_, Ugen
value] Maybe [Ugen]
forall a. Maybe a
Nothing Int
0 (Int -> Special
Special Int
0) UgenId
NoId

{- | Set-reset flip flop.

 SetResetFF [ControlRate,AudioRate] trig=0 reset=0;    FILTER: TRUE
-}
setResetFF :: Ugen -> Ugen -> Ugen
setResetFF :: Ugen -> Ugen -> Ugen
setResetFF Ugen
trig_ Ugen
reset = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1]) String
"SetResetFF" [Ugen
trig_, Ugen
reset] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Wave shaper.

 Shaper [ControlRate,AudioRate] bufnum=0 in=0;    FILTER: TRUE
-}
shaper :: Ugen -> Ugen -> Ugen
shaper :: Ugen -> Ugen -> Ugen
shaper Ugen
bufnum Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"Shaper" [Ugen
bufnum, Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Interpolating sine wavetable oscillator.

 SinOsc [ControlRate,AudioRate] freq=440 phase=0
-}
sinOsc :: Rate -> Ugen -> Ugen -> Ugen
sinOsc :: Rate -> Ugen -> Ugen -> Ugen
sinOsc Rate
rate Ugen
freq Ugen
phase = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"SinOsc" [Ugen
freq, Ugen
phase] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Feedback FM oscillator

 SinOscFB [ControlRate,AudioRate] freq=440 feedback=0
-}
sinOscFB :: Rate -> Ugen -> Ugen -> Ugen
sinOscFB :: Rate -> Ugen -> Ugen -> Ugen
sinOscFB Rate
rate Ugen
freq Ugen
feedback = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"SinOscFB" [Ugen
freq, Ugen
feedback] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Slew rate limiter.

 Slew [ControlRate,AudioRate] in=0 up=1 dn=1;    FILTER: TRUE
-}
slew :: Ugen -> Ugen -> Ugen -> Ugen
slew :: Ugen -> Ugen -> Ugen -> Ugen
slew Ugen
in_ Ugen
up Ugen
dn = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Slew" [Ugen
in_, Ugen
up, Ugen
dn] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Slope of signal

 Slope [ControlRate,AudioRate] in=0;    FILTER: TRUE
-}
slope :: Ugen -> Ugen
slope :: Ugen -> Ugen
slope Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Slope" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Spectral centroid

 SpecCentroid [ControlRate] buffer=0
-}
specCentroid :: Rate -> Ugen -> Ugen
specCentroid :: Rate -> Ugen -> Ugen
specCentroid Rate
rate Ugen
buffer = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"SpecCentroid" [Ugen
buffer] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Spectral Flatness measure

 SpecFlatness [ControlRate] buffer=0
-}
specFlatness :: Rate -> Ugen -> Ugen
specFlatness :: Rate -> Ugen -> Ugen
specFlatness Rate
rate Ugen
buffer = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"SpecFlatness" [Ugen
buffer] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Find a percentile of FFT magnitude spectrum

 SpecPcile [ControlRate] buffer=0 fraction=0.5 interpolate=0
-}
specPcile :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
specPcile :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
specPcile Rate
rate Ugen
buffer Ugen
fraction Ugen
interpolate = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"SpecPcile" [Ugen
buffer, Ugen
fraction, Ugen
interpolate] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | physical model of resonating spring

 Spring [ControlRate,AudioRate] in=0 spring=1 damp=0
-}
spring :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
spring :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
spring Rate
rate Ugen
in_ Ugen
spring_ Ugen
damp = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Spring" [Ugen
in_, Ugen
spring_, Ugen
damp] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Standard map chaotic generator

 StandardL [AudioRate] freq=22050 k=1 xi=0.5 yi=0
-}
standardL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
standardL :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
standardL Rate
rate Ugen
freq Ugen
k Ugen
xi Ugen
yi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"StandardL" [Ugen
freq, Ugen
k, Ugen
xi, Ugen
yi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Standard map chaotic generator

 StandardN [AudioRate] freq=22050 k=1 xi=0.5 yi=0
-}
standardN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
standardN :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
standardN Rate
rate Ugen
freq Ugen
k Ugen
xi Ugen
yi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"StandardN" [Ugen
freq, Ugen
k, Ugen
xi, Ugen
yi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Pulse counter.

 Stepper [ControlRate,AudioRate] trig=0 reset=0 min=0 max=7 step=1 resetval=0;    FILTER: TRUE
-}
stepper :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
stepper :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
stepper Ugen
trig_ Ugen
reset Ugen
min_ Ugen
max_ Ugen
step Ugen
resetval = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Stepper" [Ugen
trig_, Ugen
reset, Ugen
min_, Ugen
max_, Ugen
step, Ugen
resetval] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Stereo real-time convolver with linear interpolation

 StereoConvolution2L [AudioRate] in=0 kernelL=0 kernelR=0 trigger=0 framesize=2048 crossfade=1
-}
stereoConvolution2L :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
stereoConvolution2L :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
stereoConvolution2L Rate
rate Ugen
in_ Ugen
kernelL Ugen
kernelR Ugen
trigger Ugen
framesize Ugen
crossfade = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"StereoConvolution2L" [Ugen
in_, Ugen
kernelL, Ugen
kernelR, Ugen
trigger, Ugen
framesize, Ugen
crossfade] Maybe [Ugen]
forall a. Maybe a
Nothing Int
2 (Int -> Special
Special Int
0) UgenId
NoId

{- | Offset from synth start within one sample.

 SubsampleOffset [InitialisationRate]
-}
subsampleOffset :: Ugen
subsampleOffset :: Ugen
subsampleOffset = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"SubsampleOffset" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Sum three signals

 Sum3 [] in0=0 in1=0 in2=0;    FILTER: TRUE
-}
sum3 :: Ugen -> Ugen -> Ugen -> Ugen
sum3 :: Ugen -> Ugen -> Ugen -> Ugen
sum3 Ugen
in0 Ugen
in1 Ugen
in2 = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate, Rate
DemandRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1, Int
2]) String
"Sum3" [Ugen
in0, Ugen
in1, Ugen
in2] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Sum four signals

 Sum4 [] in0=0 in1=0 in2=0 in3=0;    FILTER: TRUE
-}
sum4 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
sum4 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
sum4 Ugen
in0 Ugen
in1 Ugen
in2 Ugen
in3 = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate, Rate
DemandRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1, Int
2, Int
3]) String
"Sum4" [Ugen
in0, Ugen
in1, Ugen
in2, Ugen
in3] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Triggered linear ramp

 Sweep [ControlRate,AudioRate] trig=0 rate=1;    FILTER: TRUE
-}
sweep :: Rate -> Ugen -> Ugen -> Ugen
sweep :: Rate -> Ugen -> Ugen -> Ugen
sweep Rate
rate Ugen
trig_ Ugen
rate_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Sweep" [Ugen
trig_, Ugen
rate_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Hard sync sawtooth wave.

 SyncSaw [ControlRate,AudioRate] syncFreq=440 sawFreq=440
-}
syncSaw :: Rate -> Ugen -> Ugen -> Ugen
syncSaw :: Rate -> Ugen -> Ugen -> Ugen
syncSaw Rate
rate Ugen
syncFreq Ugen
sawFreq = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"SyncSaw" [Ugen
syncFreq, Ugen
sawFreq] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Control rate trigger to audio rate trigger converter

 T2A [AudioRate] in=0 offset=0
-}
t2a :: Ugen -> Ugen -> Ugen
t2a :: Ugen -> Ugen -> Ugen
t2a Ugen
in_ Ugen
offset = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"T2A" [Ugen
in_, Ugen
offset] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Audio rate trigger to control rate trigger converter

 T2K [ControlRate] in=0
-}
t2k :: Ugen -> Ugen
t2k :: Ugen -> Ugen
t2k Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"T2K" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | physical model of bouncing object

 TBall [ControlRate,AudioRate] in=0 g=10 damp=0 friction=0.01
-}
tBall :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
tBall :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
tBall Rate
rate Ugen
in_ Ugen
g Ugen
damp Ugen
friction_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"TBall" [Ugen
in_, Ugen
g, Ugen
damp, Ugen
friction_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Trigger delay.

 TDelay [ControlRate,AudioRate] in=0 dur=0.1;    FILTER: TRUE
-}
tDelay :: Ugen -> Ugen -> Ugen
tDelay :: Ugen -> Ugen -> Ugen
tDelay Ugen
in_ Ugen
dur = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"TDelay" [Ugen
in_, Ugen
dur] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Demand results as trigger from demand rate Ugens.

 TDuty [ControlRate,AudioRate] dur=1 reset=0 doneAction=0 level=1 gapFirst=0;    REORDERS INPUTS: [0,1,3,2,4], ENUMERATION INPUTS: 2=DoneAction
-}
tDuty :: Rate -> Ugen -> Ugen -> DoneAction Ugen -> Ugen -> Ugen -> Ugen
tDuty :: Rate -> Ugen -> Ugen -> DoneAction Ugen -> Ugen -> Ugen -> Ugen
tDuty Rate
rate Ugen
dur Ugen
reset DoneAction Ugen
doneAction Ugen
level Ugen
gapFirst = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"TDuty" [Ugen
dur, Ugen
reset, (DoneAction Ugen -> Ugen
forall t. Num t => DoneAction t -> t
from_done_action DoneAction Ugen
doneAction), Ugen
level, Ugen
gapFirst] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Triggered exponential random number generator.

 TExpRand [ControlRate,AudioRate] lo=0.01 hi=1 trig=0;    FILTER: TRUE, NONDET
-}
tExpRandId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tExpRandId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tExpRandId a
z Ugen
lo Ugen
hi Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
2]) String
"TExpRand" [Ugen
lo, Ugen
hi, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of TExpRand.
tExpRandM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tExpRandM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tExpRandM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tExpRandId

-- | Unsafe variant of TExpRand.
tExpRand :: Ugen -> Ugen -> Ugen -> Ugen
tExpRand :: Ugen -> Ugen -> Ugen -> Ugen
tExpRand = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tExpRandM

{- | Buffer granulator.

 TGrains [AudioRate] trigger=0 bufnum=0 rate=1 centerPos=0 dur=0.1 pan=0 amp=0.1 interp=4;    NC INPUT: True
-}
tGrains :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
tGrains :: Int
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
tGrains Int
numChannels Ugen
trigger Ugen
bufnum Ugen
rate_ Ugen
centerPos Ugen
dur Ugen
pan Ugen
amp Ugen
interp = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"TGrains" [Ugen
trigger, Ugen
bufnum, Ugen
rate_, Ugen
centerPos, Ugen
dur, Ugen
pan, Ugen
amp, Ugen
interp] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Triggered integer random number generator.

 TIRand [ControlRate,AudioRate] lo=0 hi=127 trig=0;    FILTER: TRUE, NONDET
-}
tiRandId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tiRandId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tiRandId a
z Ugen
lo Ugen
hi Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
2]) String
"TIRand" [Ugen
lo, Ugen
hi, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Tirand.
tiRandM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tiRandM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tiRandM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tiRandId

-- | Unsafe variant of Tirand.
tiRand :: Ugen -> Ugen -> Ugen -> Ugen
tiRand :: Ugen -> Ugen -> Ugen -> Ugen
tiRand = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tiRandM

{- | Triggered random number generator.

 TRand [ControlRate,AudioRate] lo=0 hi=1 trig=0;    FILTER: TRUE, NONDET
-}
tRandId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tRandId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tRandId a
z Ugen
lo Ugen
hi Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
2]) String
"TRand" [Ugen
lo, Ugen
hi, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of TRand.
tRandM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tRandM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tRandM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tRandId

-- | Unsafe variant of TRand.
tRand :: Ugen -> Ugen -> Ugen -> Ugen
tRand :: Ugen -> Ugen -> Ugen -> Ugen
tRand = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tRandM

{- | Triggered windex.

 TWindex [ControlRate,AudioRate] in=0 normalize=0 *array=0;    MCE=1, FILTER: TRUE, REORDERS INPUTS: [0,2,1], NONDET
-}
tWindexId :: ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tWindexId :: forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tWindexId a
z Ugen
in_ Ugen
normalize Ugen
array = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"TWindex" [Ugen
in_, Ugen
normalize] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
array]) Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of TWindex.
tWindexM :: Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tWindexM :: forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tWindexM = (Int -> Ugen -> Ugen -> Ugen -> Ugen)
-> Fn3 Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d.
Uid m =>
(Int -> Fn3 a b c d) -> Fn3 a b c (m d)
liftUid3 Int -> Ugen -> Ugen -> Ugen -> Ugen
forall a. ID a => a -> Ugen -> Ugen -> Ugen -> Ugen
tWindexId

-- | Unsafe variant of TWindex.
tWindex :: Ugen -> Ugen -> Ugen -> Ugen
tWindex :: Ugen -> Ugen -> Ugen -> Ugen
tWindex = (Ugen -> Ugen -> Ugen -> IO Ugen) -> Ugen -> Ugen -> Ugen -> Ugen
forall a b c r. (a -> b -> c -> IO r) -> a -> b -> c -> r
liftUnsafe3 Ugen -> Ugen -> Ugen -> IO Ugen
forall (m :: * -> *). Uid m => Ugen -> Ugen -> Ugen -> m Ugen
tWindexM

{- | Returns time since last triggered.

 Timer [ControlRate,AudioRate] trig=0;    FILTER: TRUE
-}
timer :: Ugen -> Ugen
timer :: Ugen -> Ugen
timer Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Timer" [Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Toggle flip flop.

 ToggleFF [ControlRate,AudioRate] trig=0;    FILTER: TRUE
-}
toggleFF :: Ugen -> Ugen
toggleFF :: Ugen -> Ugen
toggleFF Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"ToggleFF" [Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Timed trigger.

 Trig [ControlRate,AudioRate] in=0 dur=0.1;    FILTER: TRUE
-}
trig :: Ugen -> Ugen -> Ugen
trig :: Ugen -> Ugen -> Ugen
trig Ugen
in_ Ugen
dur = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Trig" [Ugen
in_, Ugen
dur] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Timed trigger.

 Trig1 [ControlRate,AudioRate] in=0 dur=0.1;    FILTER: TRUE
-}
trig1 :: Ugen -> Ugen -> Ugen
trig1 :: Ugen -> Ugen -> Ugen
trig1 Ugen
in_ Ugen
dur = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Trig1" [Ugen
in_, Ugen
dur] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Two pole filter.

 TwoPole [ControlRate,AudioRate] in=0 freq=440 radius=0.8;    FILTER: TRUE
-}
twoPole :: Ugen -> Ugen -> Ugen -> Ugen
twoPole :: Ugen -> Ugen -> Ugen -> Ugen
twoPole Ugen
in_ Ugen
freq Ugen
radius = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"TwoPole" [Ugen
in_, Ugen
freq, Ugen
radius] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Two zero filter.

 TwoZero [ControlRate,AudioRate] in=0 freq=440 radius=0.8;    FILTER: TRUE
-}
twoZero :: Ugen -> Ugen -> Ugen -> Ugen
twoZero :: Ugen -> Ugen -> Ugen -> Ugen
twoZero Ugen
in_ Ugen
freq Ugen
radius = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"TwoZero" [Ugen
in_, Ugen
freq, Ugen
radius] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Stream in audio from a file, with variable rate

 VDiskIn [AudioRate] bufnum=0 rate=1 loop=0 sendID=0;    NC INPUT: True, ENUMERATION INPUTS: 2=Loop
-}
vDiskIn :: Int -> Ugen -> Ugen -> Loop Ugen -> Ugen -> Ugen
vDiskIn :: Int -> Ugen -> Ugen -> Loop Ugen -> Ugen -> Ugen
vDiskIn Int
numChannels Ugen
bufnum Ugen
rate_ Loop Ugen
loop Ugen
sendID = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"VDiskIn" [Ugen
bufnum, Ugen
rate_, (Loop Ugen -> Ugen
forall t. Num t => Loop t -> t
from_loop Loop Ugen
loop), Ugen
sendID] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | Variable wavetable oscillator.

 VOsc [ControlRate,AudioRate] bufpos=0 freq=440 phase=0
-}
vOsc :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
vOsc :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
vOsc Rate
rate Ugen
bufpos Ugen
freq Ugen
phase = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"VOsc" [Ugen
bufpos, Ugen
freq, Ugen
phase] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Three variable wavetable oscillators.

 VOsc3 [ControlRate,AudioRate] bufpos=0 freq1=110 freq2=220 freq3=440
-}
vOsc3 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
vOsc3 :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
vOsc3 Rate
rate Ugen
bufpos Ugen
freq1 Ugen
freq2 Ugen
freq3 = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"VOsc3" [Ugen
bufpos, Ugen
freq1, Ugen
freq2, Ugen
freq3] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Variable shaped lag

 VarLag [ControlRate,AudioRate] in=0 time=0.1 curvature=0 warp=5 start=0;    FILTER: TRUE
-}
varLag :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
varLag :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
varLag Ugen
in_ Ugen
time Ugen
curvature Ugen
warp Ugen
start = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"VarLag" [Ugen
in_, Ugen
time, Ugen
curvature, Ugen
warp, Ugen
start] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Variable duty saw

 VarSaw [ControlRate,AudioRate] freq=440 iphase=0 width=0.5
-}
varSaw :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
varSaw :: Rate -> Ugen -> Ugen -> Ugen -> Ugen
varSaw Rate
rate Ugen
freq Ugen
iphase Ugen
width = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"VarSaw" [Ugen
freq, Ugen
iphase, Ugen
width] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | The Vibrato oscillator models a slow frequency modulation.

 Vibrato [ControlRate,AudioRate] freq=440 rate=6 depth=0.02 delay=0 onset=0 rateVariation=0.04 depthVariation=0.1 iphase=0 trig=0;    NONDET
-}
vibratoId :: ID a => a -> Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
vibratoId :: forall a.
ID a =>
a
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
vibratoId a
z Rate
rate Ugen
freq Ugen
rate_ Ugen
depth Ugen
delay Ugen
onset Ugen
rateVariation Ugen
depthVariation Ugen
iphase Ugen
trig_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"Vibrato" [Ugen
freq, Ugen
rate_, Ugen
depth, Ugen
delay, Ugen
onset, Ugen
rateVariation, Ugen
depthVariation, Ugen
iphase, Ugen
trig_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of Vibrato.
vibratoM :: Uid m => Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> m Ugen
vibratoM :: forall (m :: * -> *).
Uid m =>
Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> m Ugen
vibratoM = (Int
 -> Rate
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen)
-> Fn10 Rate Ugen Ugen Ugen Ugen Ugen Ugen Ugen Ugen Ugen (m Ugen)
forall (m :: * -> *) a b c d e f g h i j k.
Uid m =>
(Int -> Fn10 a b c d e f g h i j k)
-> Fn10 a b c d e f g h i j (m k)
liftUid10 Int
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
forall a.
ID a =>
a
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
vibratoId

-- | Unsafe variant of Vibrato.
vibrato :: Rate -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
vibrato :: Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
vibrato = (Rate
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> Ugen
 -> IO Ugen)
-> Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
forall a b c d e f g h i j r.
(a -> b -> c -> d -> e -> f -> g -> h -> i -> j -> IO r)
-> a -> b -> c -> d -> e -> f -> g -> h -> i -> j -> r
liftUnsafe10 Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> IO Ugen
forall (m :: * -> *).
Uid m =>
Rate
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> m Ugen
vibratoM

{- | Warp a buffer with a time pointer

 Warp1 [AudioRate] bufnum=0 pointer=0 freqScale=1 windowSize=0.2 envbufnum=-1 overlaps=8 windowRandRatio=0 interp=1;    NC INPUT: True
-}
warp1 :: Int -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen -> Ugen
warp1 :: Int
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
-> Ugen
warp1 Int
numChannels Ugen
bufnum Ugen
pointer Ugen
freqScale Ugen
windowSize Ugen
envbufnum Ugen
overlaps Ugen
windowRandRatio Ugen
interp = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
AudioRate) String
"Warp1" [Ugen
bufnum, Ugen
pointer, Ugen
freqScale, Ugen
windowSize, Ugen
envbufnum, Ugen
overlaps, Ugen
windowRandRatio, Ugen
interp] Maybe [Ugen]
forall a. Maybe a
Nothing Int
numChannels (Int -> Special
Special Int
0) UgenId
NoId

{- | White noise.

 WhiteNoise [ControlRate,AudioRate] ;    NONDET
-}
whiteNoiseId :: ID a => a -> Rate -> Ugen
whiteNoiseId :: forall a. ID a => a -> Rate -> Ugen
whiteNoiseId a
z Rate
rate = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"WhiteNoise" [] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) (a -> UgenId
forall a. ID a => a -> UgenId
toUid a
z)

-- | Monad variant of WhiteNoise.
whiteNoiseM :: Uid m => Rate -> m Ugen
whiteNoiseM :: forall (m :: * -> *). Uid m => Rate -> m Ugen
whiteNoiseM = (Int -> Rate -> Ugen) -> Fn1 Rate (m Ugen)
forall (m :: * -> *) a b. Uid m => (Int -> Fn1 a b) -> Fn1 a (m b)
liftUid1 Int -> Rate -> Ugen
forall a. ID a => a -> Rate -> Ugen
whiteNoiseId

-- | Unsafe variant of WhiteNoise.
whiteNoise :: Rate -> Ugen
whiteNoise :: Rate -> Ugen
whiteNoise = (Rate -> IO Ugen) -> Rate -> Ugen
forall a r. (a -> IO r) -> a -> r
liftUnsafe1 Rate -> IO Ugen
forall (m :: * -> *). Uid m => Rate -> m Ugen
whiteNoiseM

{- | Wrap a signal outside given thresholds.

 Wrap [InitialisationRate,ControlRate,AudioRate] in=0 lo=0 hi=1;    FILTER: TRUE
-}
wrap :: Ugen -> Ugen -> Ugen -> Ugen
wrap :: Ugen -> Ugen -> Ugen -> Ugen
wrap Ugen
in_ Ugen
lo Ugen
hi = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"Wrap" [Ugen
in_, Ugen
lo, Ugen
hi] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Index into a table with a signal.

 WrapIndex [ControlRate,AudioRate] bufnum=0 in=0;    FILTER: TRUE
-}
wrapIndex :: Ugen -> Ugen -> Ugen
wrapIndex :: Ugen -> Ugen -> Ugen
wrapIndex Ugen
bufnum Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
1]) String
"WrapIndex" [Ugen
bufnum, Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Equal power two channel cross fade.

 XFade2 [ControlRate,AudioRate] inA=0 inB=0 pan=0 level=1;    FILTER: TRUE
-}
xFade2 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
xFade2 :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
xFade2 Ugen
inA Ugen
inB Ugen
pan Ugen
level = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1]) String
"XFade2" [Ugen
inA, Ugen
inB, Ugen
pan, Ugen
level] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Exponential line generator.

 XLine [ControlRate,AudioRate] start=1 end=2 dur=1 doneAction=0;    ENUMERATION INPUTS: 3=DoneAction
-}
xLine :: Rate -> Ugen -> Ugen -> Ugen -> DoneAction Ugen -> Ugen
xLine :: Rate -> Ugen -> Ugen -> Ugen -> DoneAction Ugen -> Ugen
xLine Rate
rate Ugen
start Ugen
end Ugen
dur DoneAction Ugen
doneAction = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
rate) String
"XLine" [Ugen
start, Ugen
end, Ugen
dur, (DoneAction Ugen -> Ugen
forall t. Num t => DoneAction t -> t
from_done_action DoneAction Ugen
doneAction)] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Send signal to a bus, crossfading with previous contents.

 XOut [ControlRate,AudioRate] bus=0 xfade=0 *channelsArray=0;    MCE=1, FILTER: TRUE
-}
xOut :: Ugen -> Ugen -> Ugen -> Ugen
xOut :: Ugen -> Ugen -> Ugen -> Ugen
xOut Ugen
bus Ugen
xfade Ugen
input = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
2]) String
"XOut" [Ugen
bus, Ugen
xfade] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
input]) Int
0 (Int -> Special
Special Int
0) UgenId
NoId

{- | Zero crossing frequency follower

 ZeroCrossing [ControlRate,AudioRate] in=0;    FILTER: TRUE
-}
zeroCrossing :: Ugen -> Ugen
zeroCrossing :: Ugen -> Ugen
zeroCrossing Ugen
in_ = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0]) String
"ZeroCrossing" [Ugen
in_] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | LocalBuf count

 MaxLocalBufs [InitialisationRate,ControlRate] count=0
-}
maxLocalBufs :: Ugen -> Ugen
maxLocalBufs :: Ugen -> Ugen
maxLocalBufs Ugen
count = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
ControlRate) String
"MaxLocalBufs" [Ugen
count] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Multiply add

 MulAdd [InitialisationRate,ControlRate,AudioRate] in=0 mul=0 add=0;    FILTER: TRUE
-}
mulAdd :: Ugen -> Ugen -> Ugen -> Ugen
mulAdd :: Ugen -> Ugen -> Ugen -> Ugen
mulAdd Ugen
in_ Ugen
mul Ugen
add = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate, Rate
ControlRate, Rate
AudioRate] ([Int] -> Either Rate [Int]
forall a b. b -> Either a b
Right [Int
0, Int
1, Int
2]) String
"MulAdd" [Ugen
in_, Ugen
mul, Ugen
add] Maybe [Ugen]
forall a. Maybe a
Nothing Int
1 (Int -> Special
Special Int
0) UgenId
NoId

{- | Set local buffer

 SetBuf [InitialisationRate] buf=0 offset=0 length=0 *array=0;    MCE=1, REORDERS INPUTS: [0,1,2,3]
-}
setBuf :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
setBuf :: Ugen -> Ugen -> Ugen -> Ugen -> Ugen
setBuf Ugen
buf Ugen
offset Ugen
length_ Ugen
array = Maybe ([Sample] -> Sample)
-> [Rate]
-> Either Rate [Int]
-> String
-> [Ugen]
-> Maybe [Ugen]
-> Int
-> Special
-> UgenId
-> Ugen
mkUgen Maybe ([Sample] -> Sample)
forall a. Maybe a
Nothing [Rate
InitialisationRate] (Rate -> Either Rate [Int]
forall a b. a -> Either a b
Left Rate
InitialisationRate) String
"SetBuf" [Ugen
buf, Ugen
offset, Ugen
length_] ([Ugen] -> Maybe [Ugen]
forall a. a -> Maybe a
Just [Ugen
array]) Int
1 (Int -> Special
Special Int
0) UgenId
NoId