Skip to content
A library for musical pitch conversions! Provides functions and methods for converting between frequency (hz), midi-step, letter-octave and mels.
Rust
Branch: master
Clone or download
mitchmindtree Merge pull request #26 from klingtnet/implement-integer-conversion-fo…
…r-step

Implement integer conversion traits for Step type
Latest commit f821621 Nov 16, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
examples Increment version for crates.io Sep 7, 2015
src Implement integer conversion traits for Step type Nov 15, 2018
.gitignore
.travis.yml Remove unnecessary stuff from travis Apr 28, 2017
Cargo.toml Switch to derived serialization Jun 23, 2017
README.md Fix toml markdown Jun 17, 2015

README.md

pitch_calc Build Status

A library for musical pitch conversions!

pitch_calc provides functions and methods for converting between frequency, midi-step and letter-octave.

It looks like this.

assert!(Hz(440.0).letter_octave() == (A, 4))

Types

  • Hz ("times per second").
  • LetterOctave (musical letter notation).
  • Mel (a perceptual scale of pitches judged by listeners to be equal in distance from one another).
  • Perc (Percentage of the human hearing range (20hz - 20khz)).
  • ScaledPerc (Scaled percentage of the human hearing range).
  • Step (MIDI semitone steps).

Usage

Add the following to your Cargo.toml.

[dependencies.pitch_calc]
git = "https://github.com/RustAudio/pitch_calc"

or

[dependencies]
pitch_calc = "X.X.X"

where "X.X.X" is the version you want (find the latest version in the Cargo.toml).

See the example for a simple demonstration.

You can’t perform that action at this time.