Movatterモバイル変換


[0]ホーム

URL:


tidal-1.9.5: Pattern language for improvised music
Safe HaskellNone
LanguageHaskell2010

Sound.Tidal.Pattern

Synopsis

Documentation

dataEventF a bSource#

An event is a value that's active during a timespan. If a whole is present, the part should be equal to or fit inside it.

Constructors

Event 

Fields

Instances

Instances details
Functor (EventF a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Methods

fmap :: (a0 -> b) ->EventF a a0 ->EventF a b#

(<$) :: a0 ->EventF a b ->EventF a a0#

Show a =>Show (Event a)Source# 
Instance details

Defined inSound.Tidal.Show

Generic (EventF a b)Source# 
Instance details

Defined inSound.Tidal.Pattern

Associated Types

typeRep (EventF a b) 
Instance details

Defined inSound.Tidal.Pattern

typeRep (EventF a b) =D1 ('MetaData "EventF" "Sound.Tidal.Pattern" "tidal-1.9.5-AigyNDgOVjgLnp8Y8sieF9" 'False) (C1 ('MetaCons "Event" 'PrefixI 'True) ((S1 ('MetaSel ('Just "context") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Context):*:S1 ('MetaSel ('Just "whole") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe a))):*: (S1 ('MetaSel ('Just "part") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 a):*:S1 ('MetaSel ('Just "value") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 b))))

Methods

from ::EventF a b ->Rep (EventF a b) x#

to ::Rep (EventF a b) x ->EventF a b#

(NFData a,NFData b) =>NFData (EventF a b)Source# 
Instance details

Defined inSound.Tidal.Pattern

Methods

rnf ::EventF a b -> ()#

(Eq a,Eq b) =>Eq (EventF a b)Source# 
Instance details

Defined inSound.Tidal.Pattern

Methods

(==) ::EventF a b ->EventF a b ->Bool#

(/=) ::EventF a b ->EventF a b ->Bool#

(Ord a,Ord b) =>Ord (EventF a b)Source# 
Instance details

Defined inSound.Tidal.Pattern

Methods

compare ::EventF a b ->EventF a b ->Ordering#

(<) ::EventF a b ->EventF a b ->Bool#

(<=) ::EventF a b ->EventF a b ->Bool#

(>) ::EventF a b ->EventF a b ->Bool#

(>=) ::EventF a b ->EventF a b ->Bool#

max ::EventF a b ->EventF a b ->EventF a b#

min ::EventF a b ->EventF a b ->EventF a b#

typeRep (EventF a b)Source# 
Instance details

Defined inSound.Tidal.Pattern

typeRep (EventF a b) =D1 ('MetaData "EventF" "Sound.Tidal.Pattern" "tidal-1.9.5-AigyNDgOVjgLnp8Y8sieF9" 'False) (C1 ('MetaCons "Event" 'PrefixI 'True) ((S1 ('MetaSel ('Just "context") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Context):*:S1 ('MetaSel ('Just "whole") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe a))):*: (S1 ('MetaSel ('Just "part") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 a):*:S1 ('MetaSel ('Just "value") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 b))))

dataStateSource#

an Arc and some named control values

Constructors

State 

Fields

dataContextSource#

Some context for an event, currently just position within sourcecode

Constructors

Context 

Fields

Instances

Instances details
GenericContextSource# 
Instance details

Defined inSound.Tidal.Pattern

Associated Types

typeRepContext 
Instance details

Defined inSound.Tidal.Pattern

typeRepContext =D1 ('MetaData "Context" "Sound.Tidal.Pattern" "tidal-1.9.5-AigyNDgOVjgLnp8Y8sieF9" 'False) (C1 ('MetaCons "Context" 'PrefixI 'True) (S1 ('MetaSel ('Just "contextPosition") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [((Int,Int), (Int,Int))])))
ShowContextSource# 
Instance details

Defined inSound.Tidal.Show

NFDataContextSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

rnf ::Context -> ()#

EqContextSource# 
Instance details

Defined inSound.Tidal.Pattern

OrdContextSource# 
Instance details

Defined inSound.Tidal.Pattern

typeRepContextSource# 
Instance details

Defined inSound.Tidal.Pattern

typeRepContext =D1 ('MetaData "Context" "Sound.Tidal.Pattern" "tidal-1.9.5-AigyNDgOVjgLnp8Y8sieF9" 'False) (C1 ('MetaCons "Context" 'PrefixI 'True) (S1 ('MetaSel ('Just "contextPosition") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [((Int,Int), (Int,Int))])))

(*>) ::Pattern (a -> b) ->Pattern a ->Pattern binfixl 4Source#

Like*, but the "wholes" come from the right

empty ::Pattern aSource#

(<*) ::Pattern (a -> b) ->Pattern a ->Pattern binfixl 4Source#

Like*, but the "wholes" come from the left

reset ::PatternBool ->Pattern a ->Pattern aSource#

typeEvent a =EventF (ArcFTime) aSource#

dataPattern aSource#

A datatype representing events taking place over time

Constructors

Pattern 

Fields

Instances

Instances details
IsStringControlPatternSource# 
Instance details

Defined inSound.Tidal.Simple

ApplicativePatternSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

pure :: a ->Pattern a#

(<*>) ::Pattern (a -> b) ->Pattern a ->Pattern b#

liftA2 :: (a -> b -> c) ->Pattern a ->Pattern b ->Pattern c#

(*>) ::Pattern a ->Pattern b ->Pattern b#

(<*) ::Pattern a ->Pattern b ->Pattern a#

FunctorPatternSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

fmap :: (a -> b) ->Pattern a ->Pattern b#

(<$) :: a ->Pattern b ->Pattern a#

MonadPatternSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

(>>=) ::Pattern a -> (a ->Pattern b) ->Pattern b#

(>>) ::Pattern a ->Pattern b ->Pattern b#

return :: a ->Pattern a#

(Enumerable a,Parseable a) =>IsString (Pattern a)Source# 
Instance details

Defined inSound.Tidal.ParseBP

Monoid (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Semigroup (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Enum a =>Enum (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Floating a =>Floating (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

RealFloat a =>RealFloat (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Generic (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Associated Types

typeRep (Pattern a) 
Instance details

Defined inSound.Tidal.Pattern

typeRep (Pattern a) =D1 ('MetaData "Pattern" "Sound.Tidal.Pattern" "tidal-1.9.5-AigyNDgOVjgLnp8Y8sieF9" 'False) (C1 ('MetaCons "Pattern" 'PrefixI 'True) (S1 ('MetaSel ('Just "query") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (State -> [Event a]))))

Methods

from ::Pattern a ->Rep (Pattern a) x#

to ::Rep (Pattern a) x ->Pattern a#

Num a =>Num (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Fractional a =>Fractional (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Integral a =>Integral (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

(Num a,Ord a) =>Real (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

RealFrac a =>RealFrac (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Methods

properFraction ::Integral b =>Pattern a -> (b,Pattern a)#

truncate ::Integral b =>Pattern a -> b#

round ::Integral b =>Pattern a -> b#

ceiling ::Integral b =>Pattern a -> b#

floor ::Integral b =>Pattern a -> b#

Show a =>Show (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Show

NFData a =>NFData (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Methods

rnf ::Pattern a -> ()#

Eq (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Methods

(==) ::Pattern a ->Pattern a ->Bool#

(/=) ::Pattern a ->Pattern a ->Bool#

Ord a =>Ord (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

Stringy (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

typeRep (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

typeRep (Pattern a) =D1 ('MetaData "Pattern" "Sound.Tidal.Pattern" "tidal-1.9.5-AigyNDgOVjgLnp8Y8sieF9" 'False) (C1 ('MetaCons "Pattern" 'PrefixI 'True) (S1 ('MetaSel ('Just "query") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (State -> [Event a]))))

typeControlPattern =PatternValueMapSource#

silence ::Pattern aSource#

rev ::Pattern a ->Pattern aSource#

rev p returnsp with the event positions in each cycle reversed (or mirrored).

For example rev"1 [~ 2] ~ 3" is equivalent to rev"3 ~ [2 ~] 1".

Note thatrev reverses on a cycle-by-cycle basis. This means thatrev (slow 2 "1 2 3 4") would actually result in(slow 2 "2 1 4 3"). This is because theslow 2 makes the repeating pattern last two cycles, each of which is reversed independently.

In practice rev is generally used with conditionals, for example with every:

d1 $ every 3 rev $ n "0 1 [~ 2] 3" # sound "arpy"

orjux:

d1 $ jux rev $ n (iter 4 "0 1 [~ 2] 3") # sound "arpy"

noOv ::String -> aSource#

  • Patterns as numbers

typeValueMap =MapStringValueSource#

applyPatToPatBoth ::Pattern (a -> b) ->Pattern a ->Pattern bSource#

applyPatToPatLeft ::Pattern (a -> b) ->Pattern a ->Pattern bSource#

applyPatToPatRight ::Pattern (a -> b) ->Pattern a ->Pattern bSource#

(<<*) ::Pattern (a -> b) ->Pattern a ->Pattern binfixl 4Source#

Like*, but the "wholes" come from the left

applyPatToPatSqueeze ::Pattern (a -> b) ->Pattern a ->Pattern bSource#

applyPatToPat :: (MaybeArc ->MaybeArc ->Maybe (MaybeArc)) ->Pattern (a -> b) ->Pattern a ->Pattern bSource#

wholeOrPart ::Event a ->ArcSource#

filterAnalog ::Pattern a ->Pattern aSource#

filterDigital ::Pattern a ->Pattern aSource#

combineContexts :: [Context] ->ContextSource#

squeezeJoin ::Pattern (Pattern a) ->Pattern aSource#

Likeunwrap, but cycles of the inner patterns are compressed to fit the timespan of the outer whole (or the original query if it's a continuous pattern?) TODO - what if a continuous pattern contains a discrete one, or vice-versa?

unwrap ::Pattern (Pattern a) ->Pattern aSource#

Turns a pattern of patterns into a single pattern. (this is actuallyjoin)

1/ For queryarc, get the events from the outer patternpp 2/ Query the inner pattern using thepart of the outer 3/ For each inner event, set the whole and part to be the intersection of the outer whole and part, respectively 4 Concatenate all the events together (discarding wholesparts that didn't intersect)

TODO - what if a continuous pattern contains a discrete one, or vice-versa?

innerJoin ::Pattern (Pattern a) ->Pattern aSource#

Turns a pattern of patterns into a single pattern. Likeunwrap, but structure only comes from the inner pattern.

outerJoin ::Pattern (Pattern a) ->Pattern aSource#

Turns a pattern of patterns into a single pattern. Likeunwrap, but structure only comes from the outer pattern.

focusArc ::Arc ->Pattern a ->Pattern aSource#

_trigJoin ::Bool ->Pattern (Pattern a) ->Pattern aSource#

rotR ::Time ->Pattern a ->Pattern aSource#

Shifts a pattern forward in time by the given amount, expressed in cycles. Opposite ofrotL.

trigJoin ::Pattern (Pattern a) ->Pattern aSource#

trigZeroJoin ::Pattern (Pattern a) ->Pattern aSource#

resetTo ::PatternRational ->Pattern a ->Pattern aSource#

rotL ::Time ->Pattern a ->Pattern aSource#

Shifts a pattern back in time by the given amount, expressed in cycles.

This will skip to the fourth cycle:

do  resetCycles  d1 $ rotL 4 $ seqP    [ (0, 12, sound "bd bd*2")    , (4, 12, sound "hh*2 [sn cp] cp future*4")    , (8, 12, sound (samples "arpy*8" (run 16)))    ]

Useful when building and testing out longer sequences.

restart ::PatternBool ->Pattern a ->Pattern aSource#

restartTo ::PatternRational ->Pattern a ->Pattern aSource#

applyFIS :: (Double ->Double) -> (Int ->Int) -> (String ->String) ->Value ->ValueSource#

General utilities..

Apply one of three functions to a Value, depending on its type

fNum2 :: (Int ->Int ->Int) -> (Double ->Double ->Double) ->Value ->Value ->ValueSource#

Apply one of two functions to a pair of Values, depending on their types (int or float; strings and rationals are ignored)

dataValueSource#

Polymorphic values

Constructors

VS 

Fields

VF 

Fields

VN 

Fields

VR 

Fields

VI 

Fields

VB 

Fields

VX 

Fields

VPattern 
VList 

Fields

VState 

Instances

Instances details
IsStringControlPatternSource# 
Instance details

Defined inSound.Tidal.Simple

FloatingValueMapSource# 
Instance details

Defined inSound.Tidal.Pattern

GenericValueSource# 
Instance details

Defined inSound.Tidal.Pattern

Associated Types

typeRepValue 
Instance details

Defined inSound.Tidal.Pattern

typeRepValue =D1 ('MetaData "Value" "Sound.Tidal.Pattern" "tidal-1.9.5-AigyNDgOVjgLnp8Y8sieF9" 'False) (((C1 ('MetaCons "VS" 'PrefixI 'True) (S1 ('MetaSel ('Just "svalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0String)):+:C1 ('MetaCons "VF" 'PrefixI 'True) (S1 ('MetaSel ('Just "fvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Double))):+: (C1 ('MetaCons "VN" 'PrefixI 'True) (S1 ('MetaSel ('Just "nvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Note)):+: (C1 ('MetaCons "VR" 'PrefixI 'True) (S1 ('MetaSel ('Just "rvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Rational)):+:C1 ('MetaCons "VI" 'PrefixI 'True) (S1 ('MetaSel ('Just "ivalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Int))))):+: ((C1 ('MetaCons "VB" 'PrefixI 'True) (S1 ('MetaSel ('Just "bvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Bool)):+:C1 ('MetaCons "VX" 'PrefixI 'True) (S1 ('MetaSel ('Just "xvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Word8]))):+: (C1 ('MetaCons "VPattern" 'PrefixI 'True) (S1 ('MetaSel ('Just "pvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (PatternValue))):+: (C1 ('MetaCons "VList" 'PrefixI 'True) (S1 ('MetaSel ('Just "lvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Value])):+:C1 ('MetaCons "VState" 'PrefixI 'True) (S1 ('MetaSel ('Just "statevalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (ValueMap -> (ValueMap,Value))))))))

Methods

from ::Value ->RepValue x#

to ::RepValue x ->Value#

NumValueMapSource# 
Instance details

Defined inSound.Tidal.Pattern

FractionalValueMapSource# 
Instance details

Defined inSound.Tidal.Pattern

ShowValueSource# 
Instance details

Defined inSound.Tidal.Show

ShowValueMapSource# 
Instance details

Defined inSound.Tidal.Show

NFDataValueSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

rnf ::Value -> ()#

EqValueSource# 
Instance details

Defined inSound.Tidal.Pattern

OrdValueSource# 
Instance details

Defined inSound.Tidal.Pattern

UnionableValueMapSource# 
Instance details

Defined inSound.Tidal.Core

ModdableValueMapSource# 
Instance details

Defined inSound.Tidal.Pattern

Valuable [Value]Source# 
Instance details

Defined inSound.Tidal.Pattern

Methods

toValue :: [Value] ->ValueSource#

typeRepValueSource# 
Instance details

Defined inSound.Tidal.Pattern

typeRepValue =D1 ('MetaData "Value" "Sound.Tidal.Pattern" "tidal-1.9.5-AigyNDgOVjgLnp8Y8sieF9" 'False) (((C1 ('MetaCons "VS" 'PrefixI 'True) (S1 ('MetaSel ('Just "svalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0String)):+:C1 ('MetaCons "VF" 'PrefixI 'True) (S1 ('MetaSel ('Just "fvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Double))):+: (C1 ('MetaCons "VN" 'PrefixI 'True) (S1 ('MetaSel ('Just "nvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Note)):+: (C1 ('MetaCons "VR" 'PrefixI 'True) (S1 ('MetaSel ('Just "rvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Rational)):+:C1 ('MetaCons "VI" 'PrefixI 'True) (S1 ('MetaSel ('Just "ivalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Int))))):+: ((C1 ('MetaCons "VB" 'PrefixI 'True) (S1 ('MetaSel ('Just "bvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Bool)):+:C1 ('MetaCons "VX" 'PrefixI 'True) (S1 ('MetaSel ('Just "xvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Word8]))):+: (C1 ('MetaCons "VPattern" 'PrefixI 'True) (S1 ('MetaSel ('Just "pvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (PatternValue))):+: (C1 ('MetaCons "VList" 'PrefixI 'True) (S1 ('MetaSel ('Just "lvalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Value])):+:C1 ('MetaCons "VState" 'PrefixI 'True) (S1 ('MetaSel ('Just "statevalue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (ValueMap -> (ValueMap,Value))))))))

classModdable awhereSource#

Methods

gmod :: a -> a -> aSource#

Instances

Instances details
ModdableRationalSource# 
Instance details

Defined inSound.Tidal.Pattern

ModdableNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

gmod ::Note ->Note ->NoteSource#

ModdableValueMapSource# 
Instance details

Defined inSound.Tidal.Pattern

ModdableDoubleSource# 
Instance details

Defined inSound.Tidal.Pattern

ModdableIntSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

gmod ::Int ->Int ->IntSource#

newtypeNoteSource#

Note is Double, but with a different parser

Constructors

Note 

Fields

Instances

Instances details
DataNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

gfoldl :: (forall d b.Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) ->Note -> cNote#

gunfold :: (forall b r.Data b => c (b -> r) -> c r) -> (forall r. r -> c r) ->Constr -> cNote#

toConstr ::Note ->Constr#

dataTypeOf ::Note ->DataType#

dataCast1 ::Typeable t => (forall d.Data d => c (t d)) ->Maybe (cNote)#

dataCast2 ::Typeable t => (forall d e. (Data d,Data e) => c (t d e)) ->Maybe (cNote)#

gmapT :: (forall b.Data b => b -> b) ->Note ->Note#

gmapQl :: (r -> r' -> r) -> r -> (forall d.Data d => d -> r') ->Note -> r#

gmapQr ::forall r r'. (r' -> r -> r) -> r -> (forall d.Data d => d -> r') ->Note -> r#

gmapQ :: (forall d.Data d => d -> u) ->Note -> [u]#

gmapQi ::Int -> (forall d.Data d => d -> u) ->Note -> u#

gmapM ::Monad m => (forall d.Data d => d -> m d) ->Note -> mNote#

gmapMp ::MonadPlus m => (forall d.Data d => d -> m d) ->Note -> mNote#

gmapMo ::MonadPlus m => (forall d.Data d => d -> m d) ->Note -> mNote#

EnumNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

FloatingNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

GenericNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

Associated Types

typeRepNote 
Instance details

Defined inSound.Tidal.Pattern

typeRepNote =D1 ('MetaData "Note" "Sound.Tidal.Pattern" "tidal-1.9.5-AigyNDgOVjgLnp8Y8sieF9" 'True) (C1 ('MetaCons "Note" 'PrefixI 'True) (S1 ('MetaSel ('Just "unNote") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Double)))

Methods

from ::Note ->RepNote x#

to ::RepNote x ->Note#

NumNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

FractionalNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

RealNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

RealFracNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

properFraction ::Integral b =>Note -> (b,Note)#

truncate ::Integral b =>Note -> b#

round ::Integral b =>Note -> b#

ceiling ::Integral b =>Note -> b#

floor ::Integral b =>Note -> b#

ShowNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

NFDataNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

rnf ::Note -> ()#

EqNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

(==) ::Note ->Note ->Bool#

(/=) ::Note ->Note ->Bool#

OrdNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

EnumerableNoteSource# 
Instance details

Defined inSound.Tidal.ParseBP

ParseableNoteSource# 
Instance details

Defined inSound.Tidal.ParseBP

ModdableNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

Methods

gmod ::Note ->Note ->NoteSource#

ValuableNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

typeRepNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

typeRepNote =D1 ('MetaData "Note" "Sound.Tidal.Pattern" "tidal-1.9.5-AigyNDgOVjgLnp8Y8sieF9" 'True) (C1 ('MetaCons "Note" 'PrefixI 'True) (S1 ('MetaSel ('Just "unNote") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0Double)))

queryArc ::Pattern a ->Arc -> [Event a]Source#

splitQueries ::Pattern a ->Pattern aSource#

Splits queries that span cycles. For example `query p (0.5, 1.5)` would be turned into two queries, `(0.5,1)` and `(1,1.5)`, and the results combined. Being able to assume queries don't span cycles often makes transformations easier to specify.

withResultArc :: (Arc ->Arc) ->Pattern a ->Pattern aSource#

Apply a function to the arcs/timespans (both whole and parts) of the result

withResultTime :: (Time ->Time) ->Pattern a ->Pattern aSource#

Apply a function to the time (both start and end of the timespans of both whole and parts) of the result

withQueryArc :: (Arc ->Arc) ->Pattern a ->Pattern aSource#

Apply a function to the timespan of the query

withQueryTime :: (Time ->Time) ->Pattern a ->Pattern aSource#

Apply a function to the time (both start and end) of the query

withQueryControls :: (ValueMap ->ValueMap) ->Pattern a ->Pattern aSource#

Apply a function to the control values of the query

withEvent :: (Event a ->Event b) ->Pattern a ->Pattern bSource#

withEvent f p returns a newPattern with each event mapped over functionf.

withValue :: (a -> b) ->Pattern a ->Pattern bSource#

withEvent f p returns a newPattern with each value mapped over functionf.

withEvents :: ([Event a] -> [Event b]) ->Pattern a ->Pattern bSource#

withEvent f p returns a newPattern with f applied to the resulting list of events for each query functionf.

withPart :: (Arc ->Arc) ->Pattern a ->Pattern aSource#

withPart f p returns a newPattern with functionf applied to the part.

_extract :: (Value ->Maybe a) ->String ->ControlPattern ->Pattern aSource#

filterJust ::Pattern (Maybe a) ->Pattern aSource#

Turns a pattern ofMaybe values into a pattern of values, dropping the events ofNothing.

extractI ::String ->ControlPattern ->PatternIntSource#

Extract a pattern of integer values by from a control pattern, given the name of the control

getI ::Value ->MaybeIntSource#

extractF ::String ->ControlPattern ->PatternDoubleSource#

Extract a pattern of floating point values by from a control pattern, given the name of the control

getF ::Value ->MaybeDoubleSource#

extractS ::String ->ControlPattern ->PatternStringSource#

Extract a pattern of string values by from a control pattern, given the name of the control

getS ::Value ->MaybeStringSource#

extractB ::String ->ControlPattern ->PatternBoolSource#

Extract a pattern of boolean values by from a control pattern, given the name of the control

getB ::Value ->MaybeBoolSource#

extractR ::String ->ControlPattern ->PatternRationalSource#

Extract a pattern of rational values by from a control pattern, given the name of the control

getR ::Value ->MaybeRationalSource#

extractN ::String ->ControlPattern ->PatternNoteSource#

Extract a pattern of note values by from a control pattern, given the name of the control

getN ::Value ->MaybeNoteSource#

compressArc ::Arc ->Pattern a ->Pattern aSource#

_fastGap ::Time ->Pattern a ->Pattern aSource#

compressArcTo ::Arc ->Pattern a ->Pattern aSource#

_fast ::Time ->Pattern a ->Pattern aSource#

fast ::PatternTime ->Pattern a ->Pattern aSource#

Speed up a pattern by the given time pattern.

For example, the following will play the sound pattern"bd sn kurt" twice asfast (i.e., so it repeats twice per cycle), and the vowel pattern three timesas fast:

d1 $ sound (fast 2 "bd sn kurt")   # fast 3 (vowel "a e o")

The first parameter can be patterned to, for example, play the pattern at twicethe speed for the first half of each cycle and then four times the speed for thesecond half:

d1 $ fast "2 4" $ sound "bd sn kurt cp"

tParam :: (t1 -> t2 ->Pattern a) ->Pattern t1 -> t2 ->Pattern aSource#

fastSqueeze ::PatternTime ->Pattern a ->Pattern aSource#

fastSqueeze speeds up a pattern by a time pattern given as input, squeezing the resulting pattern inside one cycle and playing the original pattern at every repetition.

To better understand how it works, compare it withfast:

>>>print $ fast "1 2" $ s "bd sn"(0>½)|s: "bd"(½>¾)|s: "bd"(¾>1)|s: "sn"

This will givebd played in the first half cycle, andbd sn in the second half. On the other hand, using fastSqueeze;

>>>print $ fastSqueeze "1 2" $ s "bd sn"(0>¼)|s: "bd"(¼>½)|s: "sn"(½>⅝)|s: "bd"(⅝>¾)|s: "sn"(¾>⅞)|s: "bd"(⅞>1)|s: "sn"

The original pattern will play in the first half, and two repetitions of the original pattern will play in the second half. That is, every repetition contains the whole pattern.

If the time pattern has a single value, it becomes equivalent tofast:

d1 $ fastSqueeze 2 $ s "bd sn"d1 $ fast 2 $ s "bd sn"d1 $ s "[bd sn]*2"

tParamSqueeze :: (a ->Pattern b ->Pattern c) ->Pattern a ->Pattern b ->Pattern cSource#

density ::PatternTime ->Pattern a ->Pattern aSource#

An alias forfast

slow ::PatternTime ->Pattern a ->Pattern aSource#

Slow down a pattern by the given time pattern.

For example, the following will play the sound pattern"bd sn kurt" twice as slow (i.e., so it repeats once every two cycles), and the vowel pattern three times as slow:

d1 $ sound (slow 2 "bd sn kurt")   # slow 3 (vowel "a e o")

_slow ::Time ->Pattern a ->Pattern aSource#

matchManyToOne :: (b -> a ->Bool) ->Pattern a ->Pattern b ->Pattern (Bool, b)Source#

Mark values in the first pattern which match with at least one value in the second pattern.

filterValues :: (a ->Bool) ->Pattern a ->Pattern aSource#

Remove events from patterns that to not meet the given test

filterWhen :: (Time ->Bool) ->Pattern a ->Pattern aSource#

wholeStart ::Event a ->TimeSource#

Get the onset of an event'swhole

filterOnsets ::Pattern a ->Pattern aSource#

eventPartStart ::Event a ->TimeSource#

Get the onset of an event'swhole

filterEvents :: (Event a ->Bool) ->Pattern a ->Pattern aSource#

isDigital ::Event a ->BoolSource#

isAnalog ::Event a ->BoolSource#

playFor ::Time ->Time ->Pattern a ->Pattern aSource#

tParam2 :: (a -> b -> c ->Pattern d) ->Pattern a ->Pattern b -> c ->Pattern dSource#

tParam3 :: (a -> b -> c ->Pattern d ->Pattern e) ->Pattern a ->Pattern b ->Pattern c ->Pattern d ->Pattern eSource#

setContext ::Context ->Pattern a ->Pattern aSource#

withContext :: (Context ->Context) ->Pattern a ->Pattern aSource#

deltaMini ::String ->StringSource#

classStringy awhereSource#

Methods

deltaContext ::Int ->Int -> a -> aSource#

Instances

Instances details
StringyStringSource# 
Instance details

Defined inSound.Tidal.Pattern

Stringy (Pattern a)Source# 
Instance details

Defined inSound.Tidal.Pattern

onsetIn ::Arc ->Event a ->BoolSource#

True if anEvent's starts is within givenArc

defragParts ::Eq a => [Event a] -> [Event a]Source#

Returns a list of events, with any adjacent parts of the same whole combined

isAdjacent ::Eq a =>Event a ->Event a ->BoolSource#

ReturnsTrue if the two given events are adjacent parts of the same whole

wholeStop ::Event a ->TimeSource#

Get the offset of an event'swhole

eventPartStop ::Event a ->TimeSource#

Get the offset of an event'spart

eventPart ::Event a ->ArcSource#

Get the timespan of an event'spart

eventValue ::Event a -> aSource#

eventHasOnset ::Event a ->BoolSource#

toEvent :: (((Time,Time), (Time,Time)), a) ->Event aSource#

resolveState ::ValueMap -> [EventValueMap] -> (ValueMap, [EventValueMap])Source#

classValuable awhereSource#

Methods

toValue :: a ->ValueSource#

Instances

Instances details
ValuableRationalSource# 
Instance details

Defined inSound.Tidal.Pattern

ValuableNoteSource# 
Instance details

Defined inSound.Tidal.Pattern

ValuableStringSource# 
Instance details

Defined inSound.Tidal.Pattern

ValuableBoolSource# 
Instance details

Defined inSound.Tidal.Pattern

ValuableDoubleSource# 
Instance details

Defined inSound.Tidal.Pattern

ValuableIntSource# 
Instance details

Defined inSound.Tidal.Pattern

Valuable [Word8]Source# 
Instance details

Defined inSound.Tidal.Pattern

Methods

toValue :: [Word8] ->ValueSource#

Valuable [Value]Source# 
Instance details

Defined inSound.Tidal.Pattern

Methods

toValue :: [Value] ->ValueSource#

getBlob ::Value ->Maybe [Word8]Source#

getList ::Value ->Maybe [Value]Source#

valueToPattern ::Value ->PatternValueSource#

sameDur ::Event a ->Event a ->BoolSource#

groupEventsBy ::Eq a => (Event a ->Event a ->Bool) -> [Event a] -> [[Event a]]Source#

collectEvent :: [Event a] ->Maybe (Event [a])Source#

collectEventsBy ::Eq a => (Event a ->Event a ->Bool) -> [Event a] -> [Event [a]]Source#

collectBy ::Eq a => (Event a ->Event a ->Bool) ->Pattern a ->Pattern [a]Source#

collects all events satisfying the same constraint into a list

collect ::Eq a =>Pattern a ->Pattern [a]Source#

collects all events occuring at the exact same time into a list

uncollectEvent ::Event [a] -> [Event a]Source#

uncollectEvents :: [Event [a]] -> [Event a]Source#

uncollect ::Pattern [a] ->Pattern aSource#

merges all values in a list into one pattern by stacking the values

moduleSound.Tidal.Time

Produced byHaddock version 2.30.0


[8]ページ先頭

©2009-2025 Movatter.jp