forked from ryan-hodgman1/meadowphysics
-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathack.lua
More file actions
executable file
·70 lines (53 loc) · 986 Bytes
/
Copy pathack.lua
File metadata and controls
executable file
·70 lines (53 loc) · 986 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
--
-- m e a d o w p h y s i c s
--
-- a grid-enabled
-- rhizomatic
-- cascading counter
--
--
-- *----
-- *-----
-- *---
-- *-----
--
--
local meadowphysics = include("lib/mp/core")()
local g = grid.connect()
-- voicing
local Ack = include("ack/lib/ack")
engine.name = 'Ack'
function trigger(note_num, hz, voice)
engine.trig(voice-1)
end
function gate_high(note_num, hz, voice)
end
function gate_low(note_num, hz, voice)
end
function init_engine ()
params:add_separator()
Ack.add_params()
for i=1, meadowphysics.voice_count do
-- Ack.add_channel_params(i)
end
end
-- core stuff
function init()
meadowphysics.init()
params:add_separator()
init_engine()
end
function key(n,z)
meadowphysics:handle_key(n,z)
end
function g.key(x, y, z)
meadowphysics:handle_grid_input(x, y, z)
end
function redraw()
screen.clear()
meadowphysics:draw()
screen.update()
end
function cleanup()
meadowphysics:all_notes_off()
end