| Portability | non-portable (TF,GNTD) |
|---|---|
| Stability | experimental |
| Maintainer | hans@hanshoglund.se |
| Safe Haskell | None |
Music.Score.Pitch
Description
Provides pitch manipulation.
- class HasPitch a where
- newtype PitchT p a = PitchT {
- getPitchT :: (p, a)
- getPitches :: (HasPitch a, Eq v, v ~ Pitch a, Foldable s, p ~ Pitch a) => s a -> [p]
- setPitches :: (HasPitch a, Functor s, p ~ Pitch a) => p -> s a -> s a
- modifyPitches :: (HasPitch a, Functor s, p ~ Pitch a) => (p -> p) -> s a -> s a
- up :: (HasPitch a, Functor s, AffineSpace p, p ~ Pitch a) => Diff p -> s a -> s a
- down :: (HasPitch a, Functor s, AffineSpace p, p ~ Pitch a) => Diff p -> s a -> s a
Documentation
Associated Types
Methods
getPitch :: a -> Pitch aSource
Get the pitch of the given note.
setPitch :: Pitch a -> a -> aSource
Set the pitch of the given note.
modifyPitch :: (Pitch a -> Pitch a) -> a -> aSource
Modify the pitch of the given note.
Instances
| HasPitch Double | |
| HasPitch Float | |
| HasPitch Int | |
| HasPitch Integer | |
| HasPitch () | |
| HasPitch a => HasPitch [a] | |
| Integral a => HasPitch (Ratio a) | |
| HasPitch a => HasPitch (Maybe a) | |
| HasPitch a => HasPitch (TieT a) | |
| HasPitch a => HasPitch (DynamicT a) | |
| HasPitch a => HasPitch (ArticulationT a) | |
| HasPitch a => HasPitch (SlideT a) | |
| HasPitch a => HasPitch (HarmonicT a) | |
| HasPitch a => HasPitch (TextT a) | |
| HasPitch a => HasPitch (TremoloT a) | |
| HasPitch a => HasPitch (ChordT a) | |
| HasPitch (PitchT p a) | |
| HasPitch a => HasPitch (PartT n a) |
getPitches :: (HasPitch a, Eq v, v ~ Pitch a, Foldable s, p ~ Pitch a) => s a -> [p]Source
Get all pitches in the given score. Returns a list of pitches.
Score a -> [Pitch]
setPitches :: (HasPitch a, Functor s, p ~ Pitch a) => p -> s a -> s aSource
Set all pitches in the given score.
Pitch -> Score a -> Score a
modifyPitches :: (HasPitch a, Functor s, p ~ Pitch a) => (p -> p) -> s a -> s aSource
Modify all pitches in the given score.
(Pitch -> Pitch) -> Score a -> Score a