Skip to content

Commit

Permalink
some post-merge fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
James Trayford committed Dec 18, 2024
1 parent 4479ebc commit 06d180f
Show file tree
Hide file tree
Showing 8 changed files with 257 additions and 111 deletions.
2 changes: 2 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']

myst_footnote_transition = False

# html_theme_options = {
# 'page_width': '1200px'
# }
6 changes: 5 additions & 1 deletion docs/yamls_to_tables.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ def yaml_traverse(metadict, valdict, rdict, headlev=1):
return

with open('docs/tables.md', 'w') as outfile:
l = len(glob(str(p)))
i = 0
for f in glob(str(p)):
p = Path(f)
ydat = read_yaml(p)
Expand All @@ -73,6 +75,8 @@ def yaml_traverse(metadict, valdict, rdict, headlev=1):
# print('---')
outfile.write(f"\n# {generators[p.parents[0].name]}\n")
outfile.write(ystr)
outfile.write('---')
if i < l-1:
outfile.write('---')
i += 1

# --- hide: stop ---
51 changes: 27 additions & 24 deletions src/strauss/presets/sampler/default.yml
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,12 @@ _meta:
If looping, ending point of loop in seconds. If loop_end is longer than the sample, clip to end of the sample.
volume_envelope:
_doc: >-
Define the note volume envelope applied to the samples
A: Attack, how long it takes for a tone to sound after it’s triggered
D: Decay, how long it takes for the tones attack to die down after it’s triggered
S: Sustain, the volume/level of the sound while it’s being triggered
R: Release, how long the tone takes to go silent after the trigger is released
Define the note volume envelope applied to the samples. _'ADSR'_ is a common parametrisation in sound synthesis,
find out more e.g. [at this link](https://blg.native-instruments.com/adsr-explained/)
A: Attack, how long it takes for a sound to rise to 100% of the `level` after it’s triggered.
D: Decay, how long it takes for the sounds volume to die down to the `Sustain` value after the `Attack` period.
S: Sustain, the volume level (from 0 to 1.0) maintained after the `Decay` period, while the note is held.
R: Release, how long the tone takes to finally die away once the note is released.
Ac: Curvature of the attack portion of a note. Values from -1 to 1, positive indicates increases quickly then slow,
negative slowly then quick. a value of 0 is a linear attack, increasing in volume at a constant rate.
Dc: Curvature of the Decay portion of a note. Values from -1 to 1, positive indicates decreases quickly then slow,
Expand All @@ -123,47 +124,50 @@ _meta:
pitch_lfo:
_doc: >-
Controls for the `'Low Frequency Oscillator'` (LFO) used to modulate pitch of notes at rhythmic
frequencies. In music this is often referred to a `'vibrato'`.
frequencies. In music this is often referred to as `'vibrato'`.
use: Switch feature on or off
wave: Type of waveform used for the oscillator. As with `Synthesizer` oscillators can be sawtooth
(`'saw'`), square (`'square'`), sinusoid (`'sine'`), triangle (`'tri'`) or noise (`'noise'`).
amount: the amplitude of the maximal pitch oscillation from the underlying pitch
freq: Base frequency of the LFO oscillations.
freq_shift: Shift relative to the base LFO frequency.
phase: The phase of the LFO oscillations, defined in terms of fraction of a whole cycle
A: Attack, how long it takes for a tone to sound after it’s triggered
D: Decay, how long it takes for the tone’s attack to die down after it’s triggered
S: Sustain, the volume/level of the sound while it’s being triggered
R: Release, how long the tone takes to go silent after the trigger is released
A: Attack, how long it takes for the LFO depth to rise to 100% of the `level` after it’s triggered.
D: Decay, how long it takes for the LFO depth to die down to the `Sustain` value after the `Attack` period.
S: Sustain, the LFO depth (from 0 to 1.0) maintained after the `Decay` period, while the note is held.
R: Release, how long LFO depth takes to finally die to 0 once the note is released.
Ac: Curvature of the attack portion of a note. Values from -1 to 1, positive indicates increases quickly then slow,
negative slowly then quick. a value of 0 is a linear attack, increasing in volume at a constant rate.
Dc: Curvature of the Decay portion of a note. Values from -1 to 1, positive indicates decreases quickly then slow,
negative slowly then quick. a value of 0 is a linear decay, decreasing in volume at a constant rate.
Rc: Curvature of the release portion of a note. Values from -1 to 1, positive indicates decreases quickly then slow,
negative slowly then quick. a value of 0 is a linear release, decreasing in volume at a constant rate.
level: Total amplitude level of the envelope from 0 to 1, contolling maximum volume of the note.
level: Total level of the envelope from 0 to 1, contolling maximum depth of the LFO.
volume_lfo:
_doc: >-
Controls for the `'Low Frequency Oscillator'` (LFO) used to modulate volume of notes at rhythmic
frequencies. In music this is often referred to as `'tremolo'`.
use: switch volume LFO effects on or off
wave: Type of waveform used for the oscillator. As with `Synthesizer` oscillators can be sawtooth
(`'saw'`), square (`'square'`), sinusoid (`'sine'`), triangle (`'tri'`) or noise (`'noise'`).
amount: The amplitude of the maximal pitch oscillation from the underlying pitch
amount: The amplitude of the maximal volume oscillation from the underlying pitch
freq: Base frequency of the LFO oscillations.
freq_shift: Shift relative to the base LFO frequency
phase: The phase of the LFO oscillations, defined in terms of fraction of a whole cycle.
A: Attack, how long it takes for a tone to sound after it’s triggered
D: Decay, how long it takes for the tone’s attack to die down after it’s triggered
S: Sustain, the volume/level of the sound while it’s being triggered
R: Release, how long the tone takes to go silent after the trigger is released
Ac: Curvature of the attack portion of a note. Values from -1 to 1, positive indicates increases quickly then slow,
negative slowly then quick. a value of 0 is a linear attack, increasing in volume at a constant rate.
Dc: Curvature of the Decay portion of a note. Values from -1 to 1, positive indicates decreases quickly then slow,
negative slowly then quick. a value of 0 is a linear decay, decreasing in volume at a constant rate.
Rc: Curvature of the release portion of a note. Values from -1 to 1, positive indicates decreases quickly then slow,
negative slowly then quick. a value of 0 is a linear release, decreasing in volume at a constant rate.
level: Total amplitude level of the envelope from 0 to 1, contolling maximum volume of the note
A: Attack, how long it takes for the LFO depth to rise to 100% of the `level` after it’s triggered.
D: Decay, how long it takes for the LFO depth to die down to the `Sustain` value after the `Attack` period.
S: Sustain, the LFO depth (from 0 to 1.0) maintained after the `Decay` period, while the note is held.
R: Release, how long LFO depth takes to finally die to 0 once the note is released.
Ac: >-
Curvature of the attack portion of a note. Values from -1 to 1, positive indicates increases quickly then slow,
negative slowly then quick. a value of 0 is a linear attack, increasing in volume at a constant rate.
Dc: >-
Curvature of the Decay portion of a note. Values from -1 to 1, positive indicates decreases quickly then slow,
negative slowly then quick. a value of 0 is a linear decay, decreasing in volume at a constant rate.
Rc: >-
Curvature of the release portion of a note. Values from -1 to 1, positive indicates decreases quickly then slow,
negative slowly then quick. a value of 0 is a linear release, decreasing in volume at a constant rate.
level: Total level of the envelope from 0 to 1, contolling maximum depth of the LFO.
volume: >-
Master Volume of generator.
pitch: >-
Expand All @@ -178,4 +182,3 @@ _meta:
Pitch range minimum in semitones
pitch_shift: >-
Default shift in semitones
51 changes: 49 additions & 2 deletions src/strauss/presets/sampler/ranges/default.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,54 @@ volume_envelope:
Dc_unit: 'unitless'
Rc_unit: 'unitless'
level_unit: 'unitless'


volume_lfo:
A: [1e-2, 20.]
D: [1e-2, 20.]
S: [0., 1.]
R: [1e-2, 20]
Ac: [-1. ,1.]
Dc: [-1. ,1.]
Rc: [-1. ,1.]
level: [0., 1.]
amount: [0, 1]
freq: [1., 12.]
freq_shift: [0., 3.]
A_unit: 'seconds'
D_unit: 'seconds'
S_unit: 'unitless'
R_unit: 'seconds'
Ac_unit: 'unitless'
Dc_unit: 'unitless'
Rc_unit: 'unitless'
level_unit: 'unitless'
freq_unit: 'Hz'
freq_shift_unit: 'octave'

pitch_lfo:
A: [1e-2, 20.]
D: [1e-2, 20.]
S: [0., 1.]
R: [1e-2, 20]
Ac: [-1. ,1.]
Dc: [-1. ,1.]
Rc: [-1. ,1.]
level: [0., 1.]
amount: [0, 2]
freq: [1., 12.]
freq_shift: [0., 3.]
A_unit: 'seconds'
D_unit: 'seconds'
S_unit: 'unitless'
R_unit: 'seconds'
Ac_unit: 'unitless'
Dc_unit: 'unitless'
Rc_unit: 'unitless'
level_unit: 'unitless'
amount_unit: 'semitones'
freq_unit: 'Hz'
freq_shift_unit: 'octave'

# filter cutoff
cutoff: [0., 1.]
cutoff_unit: 'unitless'
Expand All @@ -43,7 +90,7 @@ polar: [0.,1.]
polar_unit: 'unitless'

# pitch range and default shift in semitones
pitch_shift: [0., 36.]
pitch_shift: [0., 24.]
pitch_shift_unit: 'semitones'

_meta:
Expand Down
Loading

0 comments on commit 06d180f

Please sign in to comment.