File tree Expand file tree Collapse file tree
src/WAGS/Imperative/Create Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ allpass
2727 -> GraphBuilder p i o (T.GraphUnit id T.Allpass )
2828allpass _ initialAllpass attributes = GraphBuilder go
2929 where
30- initializeAllpass = unwrap $ Parameters .toInitializeAllpass initialAllpass
30+ { frequency, q } = unwrap $ Parameters .toInitializeAllpass initialAllpass
3131 go i@(Core.AudioInterpret { makeAllpass, setFrequency, setQ }) =
3232 { event:
3333 let
@@ -37,8 +37,8 @@ allpass _ initialAllpass attributes = GraphBuilder go
3737 { id
3838 , parent: nothing
3939 , scope: " imperative"
40- , frequency: initializeAllpass.frequency
41- , q: initializeAllpass.q
40+ , frequency
41+ , q
4242 }
4343 eventN = keepLatest $ attributes <#> unwrap >>> match
4444 { frequency: tmpResolveAU " imperative" i (setFrequency <<< { id, frequency: _ })
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ bandpass
2727 -> GraphBuilder p i o (T.GraphUnit id T.Bandpass )
2828bandpass _ initialBandpass attributes = GraphBuilder go
2929 where
30- initializeBandpass = unwrap $ Parameters .toInitializeBandpass initialBandpass
30+ { frequency, q } = unwrap $ Parameters .toInitializeBandpass initialBandpass
3131 go i@(Core.AudioInterpret { makeBandpass, setFrequency, setQ }) =
3232 { event:
3333 let
@@ -36,12 +36,12 @@ bandpass _ initialBandpass attributes = GraphBuilder go
3636 { id
3737 , parent: nothing
3838 , scope: " imperative"
39- , frequency: initializeBandpass.frequency
40- , q: initializeBandpass.q
39+ , frequency
40+ , q
4141 }
4242 eventN = keepLatest $ attributes <#> unwrap >>> match
43- { frequency: tmpResolveAU " imperative" i ( setFrequency <<< { id, frequency: _ })
44- , q: tmpResolveAU " imperative" i ( setQ <<< { id, q: _ })
43+ { frequency: tmpResolveAU " imperative" i $ setFrequency <<< { id, frequency: _ }
44+ , q: tmpResolveAU " imperative" i $ setQ <<< { id, q: _ }
4545 }
4646 in
4747 event0 <|> eventN
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ constant
2727 -> GraphBuilder p i o (T.GraphUnit id T.Constant )
2828constant _ initialConstant attributes = GraphBuilder go
2929 where
30- initializeConstant = unwrap $ Parameters .toInitializeConstant initialConstant
30+ { offset } = unwrap $ Parameters .toInitializeConstant initialConstant
3131 go i@(Core.AudioInterpret { makeConstant, setOffset, setOnOff }) =
3232 { event:
3333 let
@@ -36,7 +36,7 @@ constant _ initialConstant attributes = GraphBuilder go
3636 { id
3737 , parent: nothing
3838 , scope: " imperative"
39- , offset: initializeConstant.offset
39+ , offset
4040 }
4141 eventN = keepLatest $ attributes <#> unwrap >>> match
4242 { offset: tmpResolveAU " imperative" i $ setOffset <<< { id, offset:_ }
Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ convolver
2222 -> GraphBuilder p i o (T.GraphUnit id T.Convolver )
2323convolver _ initialConvolver = GraphBuilder go
2424 where
25- initializeConvolver = unwrap $ Parameters .toInitializeConvolver initialConvolver
25+ { buffer } = unwrap $ Parameters .toInitializeConvolver initialConvolver
2626 go (Core.AudioInterpret { makeConvolver }) =
2727 { event:
2828 let
@@ -31,7 +31,7 @@ convolver _ initialConvolver = GraphBuilder go
3131 { id
3232 , parent: nothing
3333 , scope: " imperative"
34- , buffer: initializeConvolver.buffer
34+ , buffer
3535 }
3636 in
3737 event0
Original file line number Diff line number Diff line change 2727 -> GraphBuilder p i o (T.GraphUnit id T.Delay )
2828delay _ initialDelay attributes = GraphBuilder go
2929 where
30- initializeDelay = unwrap $ Parameters .toInitializeDelay initialDelay
30+ { delayTime, maxDelayTime } = unwrap $ Parameters .toInitializeDelay initialDelay
3131 go i@(Core.AudioInterpret { makeDelay, setDelay }) =
3232 { event:
3333 let
@@ -36,8 +36,8 @@ delay _ initialDelay attributes = GraphBuilder go
3636 { id
3737 , parent: nothing
3838 , scope: " imperative"
39- , delayTime: initializeDelay.delayTime
40- , maxDelayTime: initializeDelay.maxDelayTime
39+ , delayTime
40+ , maxDelayTime
4141 }
4242 eventN = keepLatest $ attributes <#> unwrap >>> match
4343 { delayTime: tmpResolveAU " imperative" i $ setDelay <<< { id, delayTime: _ }
Original file line number Diff line number Diff line change 3232 -> GraphBuilder p i o (T.GraphUnit id T.Gain )
3333gain _ initialGain attributes = GraphBuilder go
3434 where
35- initializeGain = unwrap $ Parameters .toInitializeGain initialGain
35+ { gain } = unwrap $ Parameters .toInitializeGain initialGain
3636 go i@(Core.AudioInterpret { makeGain, setGain }) =
3737 { event:
3838 let
@@ -41,11 +41,11 @@ gain _ initialGain attributes = GraphBuilder go
4141 makeGain
4242 { id
4343 , parent: nothing
44- , gain: initializeGain.gain
44+ , gain
4545 , scope: " imperative"
4646 }
4747 eventN = keepLatest $ attributes <#> unwrap >>> match
48- { gain: Common .resolveAU i ( setGain <<< { id, gain: _ })
48+ { gain: Common .resolveAU i $ setGain <<< { id, gain: _ }
4949 }
5050 in
5151 event0 <|> eventN
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ highpass
2727 -> GraphBuilder p i o (T.GraphUnit id T.Highpass )
2828highpass _ initialHighpass attributes = GraphBuilder go
2929 where
30- initializeHighpass = unwrap $ Parameters .toInitializeHighpass initialHighpass
30+ { frequency, q } = unwrap $ Parameters .toInitializeHighpass initialHighpass
3131 go i@(Core.AudioInterpret { makeHighpass, setFrequency, setQ }) =
3232 { event:
3333 let
@@ -36,8 +36,8 @@ highpass _ initialHighpass attributes = GraphBuilder go
3636 { id
3737 , parent: nothing
3838 , scope: " imperative"
39- , frequency: initializeHighpass.frequency
40- , q: initializeHighpass.q
39+ , frequency
40+ , q
4141 }
4242 eventN = keepLatest $ attributes <#> unwrap >>> match
4343 { frequency: tmpResolveAU " imperative" i $ setFrequency <<< { id, frequency: _ }
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ highshelf
2727 -> GraphBuilder p i o (T.GraphUnit id T.Highshelf )
2828highshelf _ initialHighshelf attributes = GraphBuilder go
2929 where
30- initializeHighshelf = unwrap $ Parameters .toInitializeHighshelf initialHighshelf
30+ { frequency, gain } = unwrap $ Parameters .toInitializeHighshelf initialHighshelf
3131 go i@(Core.AudioInterpret { makeHighshelf, setFrequency, setGain }) =
3232 { event:
3333 let
@@ -36,8 +36,8 @@ highshelf _ initialHighshelf attributes = GraphBuilder go
3636 { id
3737 , parent: nothing
3838 , scope: " imperative"
39- , frequency: initializeHighshelf.frequency
40- , gain: initializeHighshelf.gain
39+ , frequency
40+ , gain
4141 }
4242 eventN = keepLatest $ attributes <#> unwrap >>> match
4343 { frequency: tmpResolveAU " imperative" i $ setFrequency <<< { id, frequency: _ }
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ lowpass
2727 -> GraphBuilder p i o (T.GraphUnit id T.Lowpass )
2828lowpass _ initialLowpass attributes = GraphBuilder go
2929 where
30- initializeLowpass = unwrap $ Parameters .toInitializeLowpass initialLowpass
30+ { frequency, q } = unwrap $ Parameters .toInitializeLowpass initialLowpass
3131 go i@(Core.AudioInterpret { makeLowpass, setFrequency, setQ }) =
3232 { event:
3333 let
@@ -36,8 +36,8 @@ lowpass _ initialLowpass attributes = GraphBuilder go
3636 { id
3737 , parent: nothing
3838 , scope: " imperative"
39- , frequency: initializeLowpass.frequency
40- , q: initializeLowpass.q
39+ , frequency
40+ , q
4141 }
4242 eventN = keepLatest $ attributes <#> unwrap >>> match
4343 { frequency: tmpResolveAU " imperative" i $ setFrequency <<< { id, frequency: _ }
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ lowshelf
2727 -> GraphBuilder p i o (T.GraphUnit id T.Lowshelf )
2828lowshelf _ initialLowshelf attributes = GraphBuilder go
2929 where
30- initializeLowshelf = unwrap $ Parameters .toInitializeLowshelf initialLowshelf
30+ { frequency, gain } = unwrap $ Parameters .toInitializeLowshelf initialLowshelf
3131 go i@(Core.AudioInterpret { makeLowshelf, setFrequency, setGain }) =
3232 { event:
3333 let
@@ -36,8 +36,8 @@ lowshelf _ initialLowshelf attributes = GraphBuilder go
3636 { id
3737 , parent: nothing
3838 , scope: " imperative"
39- , frequency: initializeLowshelf.frequency
40- , gain: initializeLowshelf.gain
39+ , frequency
40+ , gain
4141 }
4242 eventN = keepLatest $ attributes <#> unwrap >>> match
4343 { frequency: tmpResolveAU " imperative" i $ setFrequency <<< { id, frequency: _ }
You can’t perform that action at this time.
0 commit comments