Karya, built on Mon Jul 24 11:39:07 PDT 2017 (patch 33511aca01257b76b88de7c7a2763b7a965c084e)

Safe HaskellNone

Instrument.Inst

Contents

Description

This is called Inst because I already have way too many modules named Instrument and I couldn't think of anything better. TODO think of something better.

The hierarchy, from general to specific goes:

  • InstTypes.Qualified - global name of an Inst, used to instantiate a ScoreTypes.Instrument.
  • Instrument - name an instance of an Inst within a score
  • Inst - instrument encompassing all backends.
  • Patch - backend-specific instrument

Instrument configuration is divided into static (built-in to the instrument) and dynamic (configured per score).

Static configuration starts with Inst, and is divided into Backend specific and Common.Common.

Dynamic configuration starts with Allocation and is also divided into Backend specific and Common.Config. When a new allocation is created, the Midi.Patch.patch_defaults are copied to Midi.Patch.config_settings.

Synopsis

Inst

data Inst code Source #

Constructors

Inst 

Instances

Show code => Show (Inst code) # 

Methods

showsPrec :: Int -> Inst code -> ShowS #

show :: Inst code -> String #

showList :: [Inst code] -> ShowS #

Pretty.Pretty code => Pretty.Pretty (Inst code) # 

Methods

pretty :: Inst code -> Text Source #

format :: Inst code -> Doc Source #

formatList :: [Inst code] -> Doc Source #

db

data Db code Source #

Instances

Show code => Show (Db code) # 

Methods

showsPrec :: Int -> Db code -> ShowS #

show :: Db code -> String #

showList :: [Db code] -> ShowS #

Pretty.Pretty code => Pretty.Pretty (Db code) # 

Methods

pretty :: Db code -> Text Source #

format :: Db code -> Doc Source #

formatList :: [Db code] -> Doc Source #

data Synth code Source #

Constructors

Synth 

Fields

Instances

Show code => Show (Synth code) # 

Methods

showsPrec :: Int -> Synth code -> ShowS #

show :: Synth code -> String #

showList :: [Synth code] -> ShowS #

Pretty.Pretty code => Pretty.Pretty (Synth code) # 

Methods

pretty :: Synth code -> Text Source #

format :: Synth code -> Doc Source #

formatList :: [Synth code] -> Doc Source #

empty :: Db code Source #

size :: Db code -> Int Source #

Number of Insts in the db.

synths :: Db code -> [(InstTypes.SynthName, Synth code)] Source #

data SynthDecl code Source #

Unchecked synth declaration. db will check it for duplicates and other problems. (name, doc, patches)

Instances

Show code => Show (SynthDecl code) # 

Methods

showsPrec :: Int -> SynthDecl code -> ShowS #

show :: SynthDecl code -> String #

showList :: [SynthDecl code] -> ShowS #

Pretty.Pretty code => Pretty.Pretty (SynthDecl code) # 

Methods

pretty :: SynthDecl code -> Text Source #

format :: SynthDecl code -> Doc Source #

formatList :: [SynthDecl code] -> Doc Source #

db :: [SynthDecl code] -> (Db code, [Text]) Source #

Construct and validate a Db, returning any errors that occurred.

merge :: Db code -> Db code -> (Db code, [InstTypes.SynthName]) Source #

Merge the Dbs, and return any duplicate synths.