HSoM-1.0.0: Library for computer music education

Safe HaskellNone
LanguageHaskell98

HSoM.Performance

Documentation

data Context a Source #

Constructors

Context 

Instances

Show a => Show (Context a) Source # 

Methods

showsPrec :: Int -> Context a -> ShowS #

show :: Context a -> String #

showList :: [Context a] -> ShowS #

type PMap a = PlayerName -> Player a Source #

perf :: PMap a -> Context a -> Music a -> (Performance, DurT) Source #

data Player a Source #

Constructors

MkPlayer 

Instances

Show a => Show (Player a) Source # 

Methods

showsPrec :: Int -> Player a -> ShowS #

show :: Player a -> String #

showList :: [Player a] -> ShowS #

type NoteFun a = Context a -> Dur -> a -> Performance Source #

defPlayNote :: (Context (Pitch, [a]) -> a -> MEvent -> MEvent) -> NoteFun (Pitch, [a]) Source #

playA :: (NFData a, ToMusic1 a) => PMap Note1 -> Context Note1 -> Music a -> IO () Source #

writeMidiA :: FilePath -> PMap a -> Context a -> Music a -> IO () Source #