Skip to content

Commit 1176ae6

Browse files
committed
notes
1 parent 8d8b84c commit 1176ae6

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

notes.md

+45
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
idea for new voice computation structure,
2+
3+
should allow "duck" and "follow" featurees without compromising performance.
4+
implementation complexity is reasonable;
5+
the cost is some extra RAM usage (perhaps several KB per voice.)
6+
7+
1. allocate a number of buffers at least as big as the largest expected blocksize. each buffer will contain the value of a parameter for a whole block:
8+
- active subhead index
9+
- each subhead state:
10+
- read phase
11+
- write phase
12+
- pre+fade level
13+
- rec+fade level
14+
15+
2. each process block can be decomposed without looping over all voices on each sample.
16+
17+
## normal mode:
18+
19+
same as present operation, with some potential speed gain due to memory locality:
20+
21+
- update positions
22+
- update fade levels
23+
- peek+poke, mix
24+
25+
## "follow" mode:
26+
27+
here, one voice is always hard-synced to another, but with different buffer data and mix parameters. this allows stereo operation among other things.
28+
29+
- copy positions
30+
- copy fade levels
31+
- peek+poke, mix
32+
33+
## duck mode:
34+
35+
one voice uses another's write index as a reference; output level is attenuated when this voice's read position crosses that voice's record position.
36+
37+
- update positions
38+
- update fade levels, comparing with reference position
39+
- peek+poke, mix
40+
41+
42+
### details
43+
44+
- can use `std::array` and `std::copy` for state buffers
45+
-

0 commit comments

Comments
 (0)