hsc3-0.20: Haskell SuperCollider
Safe HaskellSafe-Inferred
LanguageHaskell2010

Sound.Sc3.Server.Param

Description

Synthesis parameters

Synopsis

Documentation

type Param1 = (String, Double) Source #

An Sc3 synthesis parameter, ie. (controlName, controlValue).

type Param = [Param1] Source #

Set of Sc3 synthesiser parameters.

param_insert :: Param -> Param1 -> Param Source #

Add new, or overwrite existing, parameter.

param_merge_uniq :: Param -> Param -> Param Source #

Merge, require keys be unique.

param_merge_uniq [("a",1),("b",2)] [("c",3),("d",4)] == [("a",1),("b",2),("c",3),("d",4)]
param_merge_uniq [("a",1)] [("a",2)] -- error

param_merge_r :: Param -> Param -> Param Source #

Merge, right biased.

param_merge_r [("a",1),("b",2)] [("c",3),("a",4)] == [("b",2),("c",3),("a",4)]

param_merge_r_seq :: [Param] -> Param Source #

Right-fold (right-biased) of param_merge

param_merge_r_seq [[("a",1),("b",2)],[("c",3),("a",4)],[("b",5)]] == [("c",3),("a",4),("b",5)]

param_get :: Param -> String -> Double -> Double Source #

Lookup parameter value, with default.

param_parse :: (Char, Char) -> String -> Param Source #

Given (param-separator,key-value-separator) parse paramter string.

param_parse (';','=') "a=1;b=2" == [("a",1),("b",2)]

param_pp :: (Char, Char) -> Int -> Param -> String Source #

Inverse of param_parse, k is the precision to print values to.

param_pp (';','=') 4 [("a",1),("b",2)] == "a=1.0;b=2.0"