- type Time = Double
- type Dur = Time
- type Score a = MediaUnit Dur () a
- rest :: Temporal Dur a => Dur -> a
- note :: Dur -> a -> Score a
- toList :: Score a -> EventList Dur a
- dur :: Temporal Dur a => a -> Dur
- class Arrangeable a where
- line :: Arrangeable a => [a] -> a
- chord :: Arrangeable a => [a] -> a
- loop :: Arrangeable a => Int -> a -> a
- trill :: Arrangeable a => Int -> a -> a -> a
- rondo :: Arrangeable a => a -> a -> a -> a
- reprise :: Arrangeable a => a -> a -> a -> a
- delay :: (Temporal Dur a, Arrangeable a) => Dur -> a -> a
- stretch :: Stretchable Dur a => Dur -> a -> a
- tstretch :: TemporalStretchable Dur a => (Time -> Dur) -> a -> a
- cut :: Dur -> Dur -> Score a -> Score a
- takeS :: Dur -> Score a -> Score a
- dropS :: Dur -> Score a -> Score a
- reverseS :: Score a -> Score a
- pedal :: Dur -> Score a -> Score a
- pedalBy :: (Time -> Dur -> a -> (b, Dur)) -> Score a -> Score b
- sustain :: Dur -> Score a -> Score a
- sustainBy :: (Time -> Dur -> a -> (b, Dur)) -> Score a -> Score b
- tmap :: (Time -> a -> b) -> Score a -> Score b
- dmap :: (Dur -> a -> b) -> Score a -> Score b
- tdmap :: (Time -> Dur -> a -> b) -> Score a -> Score b
- tmapRel :: (Time -> a -> b) -> Score a -> Score b
- dmapRel :: (Dur -> a -> b) -> Score a -> Score b
- tdmapRel :: (Time -> Dur -> a -> b) -> Score a -> Score b
- tstretchRel :: TemporalStretchable Dur a => (Time -> Dur) -> a -> a
- linseg :: (Num t, Ord t, Fractional t) => [t] -> t -> t

# Types

# Constructors

# Duration querry

# Arrangers

class Arrangeable a where

composing structures in sequent and parallel ways

Arrangeable (Media c a) | |

Dur t => Arrangeable (EventList t a) | |

Dur t => Arrangeable (MediaUnit t c a) |

line :: Arrangeable a => [a] -> aSource

sequential composition

chord :: Arrangeable a => [a] -> aSource

parallel composition

loop :: Arrangeable a => Int -> a -> aSource

trill :: Arrangeable a => Int -> a -> a -> aSource

loop for two groups of notes

rondo :: Arrangeable a => a -> a -> a -> aSource

rondo form

rondo a b c = line [a, b, a, c, a]

reprise :: Arrangeable a => a -> a -> a -> aSource

reprise form

reprise a b1 b2 = line [a, b1, a, b2]

# Transformers

## In time domain

stretch :: Stretchable Dur a => Dur -> a -> aSource

stretch in time domain

tstretch :: TemporalStretchable Dur a => (Time -> Dur) -> a -> aSource

stretch in time domain depndent on note's time

cut :: Dur -> Dur -> Score a -> Score aSource

extracting score parts in some time interval.
it reverses output if `t1 < t0`

.

pedal :: Dur -> Score a -> Score aSource

adds sustain, but total duration of score elements remains unchaged

notes are sustained within total duration interval. adds given amount of time to all notes.

pedalBy :: (Time -> Dur -> a -> (b, Dur)) -> Score a -> Score bSource

general "pedal"

total duration of score element remains unchanged. notes are sustained within total duration interval

## Mappings

tmap :: (Time -> a -> b) -> Score a -> Score bSource

temporal functor `tmap`

method for scores

map with time

dmap :: (Dur -> a -> b) -> Score a -> Score bSource

temporal functor `dmap`

method for scores

map with duration

tdmap :: (Time -> Dur -> a -> b) -> Score a -> Score bSource

temporal functor `tdmap`

method for scores

map with time and duration

# Misc

tmapRel :: (Time -> a -> b) -> Score a -> Score bSource

relative `tmap`

map with time normalized by total duration value

dmapRel :: (Dur -> a -> b) -> Score a -> Score bSource

relative `dmap`

map with duration normalized by total duration value

tdmapRel :: (Time -> Dur -> a -> b) -> Score a -> Score bSource

relative `tdmap`

map with time and duration normalized by total duration value

tstretchRel :: TemporalStretchable Dur a => (Time -> Dur) -> a -> aSource

relative `tstretch`

time normalized by durtion of value

linseg :: (Num t, Ord t, Fractional t) => [t] -> t -> t

linear interpolation