Safe Haskell | None |
---|---|
Language | Haskell2010 |
DywaPitchTrack
Description
Note that because all parameters are hard-coded into the C library, you are limited to the following audio configuration:
- raw (headerless) format
- a sampling rate of 44100Hz,
- a sample size of
sizeof(double)
- floating-point encoding
- one channel (mono)
- data PitchTrack a
- runPitchTrack :: Int -> PitchTrack a -> IO a
- askSampleNum :: PitchTrack Int
- computePitch :: ByteString -> PitchTrack Double
- neededSampleNum :: Int -> Int
- sampleSize :: Int
Documentation
data PitchTrack a Source
Arguments
:: Int | Number of samples to be used for each computation |
-> PitchTrack a | Computations |
-> IO a |
Run the PitchTrack
monad
askSampleNum :: PitchTrack Int Source
The number of samples used for each computation
Arguments
:: ByteString | Samples |
-> PitchTrack Double | Computed pitch |
Compute the pitch.
The size of the ByteString must be equal to
the number of samples set in runPitchTrack
* the size of each sample (sampleSize
).
Note: this pre-condition is not checked!
Calculate the number of samples needed, based on the lowest frequency
sampleSize :: Int Source
Sample size