csound-sampler-0.0.9.0: A musical sampler based on Csound

Safe HaskellNone
LanguageHaskell98

Csound.Sam.Trig

Contents

Synopsis

Char sampler

samCharTrig :: Maybe Sam -> String -> String -> Sam -> Sam Source #

Triggers the sample with any char from the first string and stops the sample with any char from the second string.

samCharTap :: Sig -> String -> Sam -> Sam Source #

Char trigger with fixed note limiting by length in second. It's useful optimization. It's good to use for drum notes and short sounds.

samCharPush :: Maybe Sam -> Char -> Sam -> Sam Source #

Plays a sample while the key is pressed.

samCharToggle :: Maybe Sam -> Char -> Sam -> Sam Source #

Toggles the sample when the key is pressed.

samCharGroup :: Maybe Sam -> [(Char, Sam)] -> String -> Sam Source #

Plays one of the sample from the list when corresponding char is pressed. The last string is for stopping the samples.

samCharCycle :: Maybe Sam -> Char -> String -> [Sam] -> Sam Source #

Plays samples in sequence when key is pressed. The last string is for stopping the sequence.

Synchronized with number of beats

samSyncCharTrig :: Sig -> Maybe Sam -> String -> String -> Sam -> Sam Source #

Triggers the sample with any char from the first string and stops the sample with any char from the second string. The first argument is the number of beats for syncronization.

samSyncCharPush :: Sig -> Maybe Sam -> Char -> Sam -> Sam Source #

Plays a sample while the key is pressed. The first argument is the number of beats for syncronization.

samSyncCharToggle :: Sig -> Maybe Sam -> Char -> Sam -> Sam Source #

Toggles the sample when the key is pressed. The first argument is the number of beats for syncronization.

samSyncCharTap :: Sig -> Sig -> String -> Sam -> Sam Source #

Char trigger with fixed note limiting by length in second. It's useful optimization. It's good to use for drum notes and short sounds. The first argument is the number of beats for syncronization.

samSyncCharGroup :: Sig -> Maybe Sam -> [(Char, Sam)] -> String -> Sam Source #

Plays one of the sample from the list when corresponding char is pressed. The last string is for stopping the samples.

samSyncCharCycle :: Sig -> Maybe Sam -> Char -> String -> [Sam] -> Sam Source #

Plays samples in sequence when key is pressed. The last string is for stopping the sequence. The first argument is the number of beats for syncronization.

Midi sampler

samMidiTrig :: MidiChn -> Int -> Sam -> Sam Source #

Triggers a sample with midi key. The key is an integer midi code. The C1 is 60 and the A1 is 69.

samMidiTap :: MidiChn -> Sig -> Int -> Sam -> Sam Source #

Midi trigger with fixed note limiting by length in second. It's useful optimization. It's good to use for drum notes and short sounds. The key is an integer midi code. The C1 is 60 and the A1 is 69.

samMidiToggle :: MidiChn -> Int -> Sam -> Sam Source #

Toggles samples with midi key. The key is an integer midi code. The C1 is 60 and the A1 is 69.

samMidiGroup :: MidiChn -> [(Int, Sam)] -> Sam Source #

Plays samples in the group. It's like the samCharGroup. The key is an integer midi code. The C1 is 60 and the A1 is 69.

Generic functions

samMidiTrigBy :: MidiTrigFun Sig2 -> MidiChn -> Int -> Sam -> Sam Source #

Generic samMidiTrig. We can specify the midi triggering function. The midi function takes in a signal and a volume of the pressed key (it ranges from 0 to 1). It produces some output. The default is scaling the signal with the amplitude.

samMidiTapBy :: MidiTrigFun Sig2 -> MidiChn -> Sig -> Int -> Sam -> Sam Source #

Generic samMidiTap. We can specify the midi triggering function. The midi function takes in a signal and a volume of the pressed key (it ranges from 0 to 1). It produces some output. The default is scaling the signal with the amplitude.

samMidiPushBy :: MidiTrigFun Sig2 -> MidiChn -> Int -> Sam -> Sam Source #

Generic samMidiPush. We can specify the midi triggering function. The midi function takes in a signal and a volume of the pressed key (it ranges from 0 to 1). It produces some output. The default is scaling the signal with the amplitude.

samMidiToggleBy :: MidiTrigFun Sig2 -> MidiChn -> Int -> Sam -> Sam Source #

Generic samMidiToggle. We can specify the midi triggering function. The midi function takes in a signal and a volume of the pressed key (it ranges from 0 to 1). It produces some output. The default is scaling the signal with the amplitude.

samMidiGroupBy :: MidiTrigFun Sig2 -> MidiChn -> [(Int, Sam)] -> Sam Source #

Generic samMidiGroup. We can specify the midi triggering function. The midi function takes in a signal and a volume of the pressed key (it ranges from 0 to 1). It produces some output. The default is scaling the signal with the amplitude.