temporal-csound-0.2.1: brings together temporal-music-notation and csound-expression packages

Safe HaskellNone

Csound

Description

Defines instance of CsdSco for Score.

We can trigger Csound orchestra with Score.

How to put the values in the container Score? There are many functions to construct the Score.

They live in the module Temporal.Music.Score. If you are not familiar with it, you can start with six basic functions.

  • rest -- makes a pause that lasts for some time (in seconds).
  • temp -- makes a score of one note that lasts for one second.
  • mel -- plays a list of notes in sequence (one after the other, short for melody).
  • har -- plays a list of notes in parallel (at the same time, short for harmony).
  • del -- delays all notes for some time (short for delay).
  • str -- change the tempo for all notes by the given ratio (short for stretch).

Let's play something:

 res = str 0.5 $ mel [ temp a, str 2 $ temp b, rest 1, har [temp a, temp b] ]

There are two handy infix operators for delay and stretch: (+|) and (*|). So we can write the previous score:

 res = 0.5 *| mel [ temp a, 2 *| temp b, 1 +| har [temp a, temp b] ]

Documentation