Msynth.Note
Notes.
type ('sample, 'event) t =
event:'event Stream.Event.t ->
on_die:(unit -> unit) ->
unit ->
Stream.sample ->
float ->
'sample Stream.stream
A function for creating notes. It takes as arugment the events it can recieve, as well as an on_die
function, which it should call when the note has finished playing (we cannot determine this externally in case there is some release), and returns a function which plays a note at given frequency and volume.
val simple :
(unit -> Stream.sample -> float -> float) ->
(float, [< `Release ]) t
Note from an oscillator.
Add a detuned note on top of the note.
val add :
(dt:float Stream.t ->
event:'a Stream.Event.t ->
on_die:(unit -> unit) ->
Stream.sample ->
float ->
float) ->
(dt:float Stream.t ->
event:'a Stream.Event.t ->
on_die:(unit -> unit) ->
Stream.sample ->
float ->
float) ->
(float, 'b) t
Add two notes.
module Drum : sig ... end
Basic (TR-808 type) drum notes.