Safe Haskell | Safe-Inferred |
---|
Utilities for DeriveT.PSignal
s and DeriveT.Pitch
s.
Functions here can't go into Derive.PSignal itself due to circular imports---PSignal is a low level module imported by other low level modules like Derive.Score.
Synopsis
- scale :: Scale -> DeriveT.Scale
- interpolated :: DeriveT.Pitch -> DeriveT.Pitch -> Double -> DeriveT.Pitch
- transpose :: Pitch.Transpose -> DeriveT.RawPitch a -> DeriveT.RawPitch a
- transpose_nn :: Pitch.NoteNumber -> DeriveT.RawPitch a -> DeriveT.RawPitch a
- transpose_d :: Pitch.Step -> DeriveT.RawPitch a -> DeriveT.RawPitch a
- transpose_c :: Pitch.Step -> DeriveT.RawPitch a -> DeriveT.RawPitch a
- pitch_nn :: DeriveT.Transposed -> Deriver Pitch.NoteNumber
- pitch_note :: DeriveT.Transposed -> Deriver Pitch.Note
- modify_hz :: DeriveT.Scale -> (Pitch.Hz -> Pitch.Hz) -> DeriveT.Pitch -> DeriveT.Pitch
- equal :: DeriveT.RawPitch a -> DeriveT.RawPitch a -> Bool
Documentation
scale :: Scale -> DeriveT.Scale Source #
interpolated :: DeriveT.Pitch -> DeriveT.Pitch -> Double -> DeriveT.Pitch Source #
A pitch interpolated a certain distance between two other pitches.
transpose :: Pitch.Transpose -> DeriveT.RawPitch a -> DeriveT.RawPitch a Source #
Transpose a pitch.
transpose_nn :: Pitch.NoteNumber -> DeriveT.RawPitch a -> DeriveT.RawPitch a Source #
transpose_d :: Pitch.Step -> DeriveT.RawPitch a -> DeriveT.RawPitch a Source #
transpose_c :: Pitch.Step -> DeriveT.RawPitch a -> DeriveT.RawPitch a Source #
pitch_nn :: DeriveT.Transposed -> Deriver Pitch.NoteNumber Source #
Convert a Pitch to a NoteNumber, throwing an exception if the pitch failed.
pitch_note :: DeriveT.Transposed -> Deriver Pitch.Note Source #
Like pitch_nn
, but return the Note.
modify_hz :: DeriveT.Scale -> (Pitch.Hz -> Pitch.Hz) -> DeriveT.Pitch -> DeriveT.Pitch Source #
Modify a pitch by hz. Its symbolic pitch will remain the same.
equal :: DeriveT.RawPitch a -> DeriveT.RawPitch a -> Bool Source #