Safe Haskell | None |
---|
This module contains some instruments with Causal arrow interface. The interface is a bit low-level since you have to write the transformations of the Haskell-side separately from the computations on the LLVM side. A nicer integration is used in Synthesizer.LLVM.Server.CausalPacked.InstrumentPlug. However, we preserve this module in order to show how things work internally.
- type Instrument a sig = SampleRate a -> Instrument a sig
- type Control = T ShortStrictTime
- type Time = Time Real
- type Frequency = Frequency Real
- type BendModControl = Control (T Real)
- type DetuneBendModControl = T (Control Real) (Control (T Real))
- type PIOId a = T a a
- stereoFrequenciesFromDetuneBendModulation :: Param p Real -> (FuncP p inp (Value Real), FuncP p inp (T (Value Real))) -> FuncP p inp (T VectorValue)
- frequencyFromSampleRate :: SampleRate a -> Frequency a
- halfLifeControl :: Functor f => SampleRate Real -> f Time -> f (ParameterPacked Vector)
- frequencyControl :: Functor f => SampleRate Real -> f Frequency -> f Real
- takeThreshold :: T p Real -> T p VectorValue VectorValue
- fanoutShorten :: (Transform a, Transform b, Transform c) => T a b -> T a c -> T a (T b c)
- type EnvelopeControl = T GateChunk (T (Control Time) (Control Time))
- type WithEnvelopeControl remainder = T GateChunk (T (T (Control Time) (Control Time)) remainder)
- reorderEnvelopeControl :: (Arrow arrow, Read remainder) => arrow (WithEnvelopeControl remainder) (T EnvelopeControl remainder)
- ping :: IO (Instrument Real (Vector Vector))
- pingReleaseEnvelope :: IO (Real -> Real -> SampleRate Real -> Real -> T GateChunk (Vector Vector))
- pingRelease :: IO (Real -> Real -> Instrument Real (Vector Vector))
- pingControlledEnvelope :: Maybe Real -> IO (SampleRate Real -> Real -> T EnvelopeControl (Vector Vector))
- pingStereoReleaseFM :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (T (Control Real) (Control Time)) (T (T (Control Real) (Control Time)) DetuneBendModControl))) (Vector (T Vector)))
- filterSawStereoFM :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (T (Control Frequency) (Control Time)) DetuneBendModControl)) (Vector (T Vector)))
- tineStereoFM :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (T (Control Real) (Control Real)) DetuneBendModControl)) (Vector (T Vector)))
- bellNoiseStereoFM :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (T (Control Real) (Control Real)) DetuneBendModControl)) (Vector (T Vector)))
- stringControlledEnvelope :: IO (SampleRate Real -> Real -> T EnvelopeControl (Vector Vector))
- windCore :: T (SampleRate Real, p) a (Value Real) -> T (SampleRate Real, p) a (T (Value Real)) -> T (SampleRate Real, p) a (T VectorValue)
- wind :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl DetuneBendModControl) (Vector (T Vector)))
- windPhaser :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (Control Real) (T (Control Frequency) DetuneBendModControl))) (Vector (T Vector)))
- phaserOsci :: (T p Real -> T p Real -> T p a VectorValue) -> T p a (T VectorValue)
- type StringInstrument = SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (Control Real) DetuneBendModControl)) (Vector (T Vector))
- softStringShapeCore :: (forall r. VectorValue -> VectorValue -> CodeGenFunction r VectorValue) -> IO StringInstrument
- arcStringStereoFM :: (forall r. VectorValue -> CodeGenFunction r VectorValue) -> IO StringInstrument
- softStringShapeFM :: IO StringInstrument
- arcTriangleStringStereoFM :: IO StringInstrument
- arcSquareStringStereoFM :: IO StringInstrument
- arcSineStringStereoFM :: IO StringInstrument
- arcSawStringStereoFM :: IO StringInstrument
- cosineStringStereoFM :: IO StringInstrument
- fmStringStereoFM :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (T (Control Real) (Control Real)) DetuneBendModControl)) (Vector (T Vector)))
- sampledSound :: IO (T -> SampleRate Real -> Real -> Real -> T (T GateChunk DetuneBendModControl) (Vector (T Vector)))
- makeSampledSounds :: FilePath -> Info -> IO [SampleRate Real -> Real -> Real -> T (T GateChunk DetuneBendModControl) (Vector (T Vector))]
- sampledSoundMono :: IO (T -> SampleRate Real -> Real -> Real -> T (T GateChunk BendModControl) (Vector Vector))
- makeSampledSoundsMono :: FilePath -> Info -> IO [SampleRate Real -> Real -> Real -> T (T GateChunk BendModControl) (Vector Vector)]
Documentation
type Instrument a sig = SampleRate a -> Instrument a sigSource
type Control = T ShortStrictTimeSource
type BendModControl = Control (T Real)Source
stereoFrequenciesFromDetuneBendModulation :: Param p Real -> (FuncP p inp (Value Real), FuncP p inp (T (Value Real))) -> FuncP p inp (T VectorValue)Source
frequencyFromSampleRate :: SampleRate a -> Frequency aSource
halfLifeControl :: Functor f => SampleRate Real -> f Time -> f (ParameterPacked Vector)Source
frequencyControl :: Functor f => SampleRate Real -> f Frequency -> f RealSource
takeThreshold :: T p Real -> T p VectorValue VectorValueSource
type WithEnvelopeControl remainder = T GateChunk (T (T (Control Time) (Control Time)) remainder)Source
reorderEnvelopeControl :: (Arrow arrow, Read remainder) => arrow (WithEnvelopeControl remainder) (T EnvelopeControl remainder)Source
pingReleaseEnvelope :: IO (Real -> Real -> SampleRate Real -> Real -> T GateChunk (Vector Vector))Source
pingRelease :: IO (Real -> Real -> Instrument Real (Vector Vector))Source
pingControlledEnvelope :: Maybe Real -> IO (SampleRate Real -> Real -> T EnvelopeControl (Vector Vector))Source
pingStereoReleaseFM :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (T (Control Real) (Control Time)) (T (T (Control Real) (Control Time)) DetuneBendModControl))) (Vector (T Vector)))Source
filterSawStereoFM :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (T (Control Frequency) (Control Time)) DetuneBendModControl)) (Vector (T Vector)))Source
tineStereoFM :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (T (Control Real) (Control Real)) DetuneBendModControl)) (Vector (T Vector)))Source
bellNoiseStereoFM :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (T (Control Real) (Control Real)) DetuneBendModControl)) (Vector (T Vector)))Source
stringControlledEnvelope :: IO (SampleRate Real -> Real -> T EnvelopeControl (Vector Vector))Source
windCore :: T (SampleRate Real, p) a (Value Real) -> T (SampleRate Real, p) a (T (Value Real)) -> T (SampleRate Real, p) a (T VectorValue)Source
wind :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl DetuneBendModControl) (Vector (T Vector)))Source
windPhaser :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (Control Real) (T (Control Frequency) DetuneBendModControl))) (Vector (T Vector)))Source
phaserOsci :: (T p Real -> T p Real -> T p a VectorValue) -> T p a (T VectorValue)Source
type StringInstrument = SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (Control Real) DetuneBendModControl)) (Vector (T Vector))Source
softStringShapeCore :: (forall r. VectorValue -> VectorValue -> CodeGenFunction r VectorValue) -> IO StringInstrumentSource
arcStringStereoFM :: (forall r. VectorValue -> CodeGenFunction r VectorValue) -> IO StringInstrumentSource
fmStringStereoFM :: IO (SampleRate Real -> Real -> Real -> T (WithEnvelopeControl (T (T (Control Real) (Control Real)) DetuneBendModControl)) (Vector (T Vector)))Source
sampledSound :: IO (T -> SampleRate Real -> Real -> Real -> T (T GateChunk DetuneBendModControl) (Vector (T Vector)))Source
makeSampledSounds :: FilePath -> Info -> IO [SampleRate Real -> Real -> Real -> T (T GateChunk DetuneBendModControl) (Vector (T Vector))]Source
sampledSoundMono :: IO (T -> SampleRate Real -> Real -> Real -> T (T GateChunk BendModControl) (Vector Vector))Source
mainly for testing purposes
makeSampledSoundsMono :: FilePath -> Info -> IO [SampleRate Real -> Real -> Real -> T (T GateChunk BendModControl) (Vector Vector)]Source