Struct pitch_calc::step::Step [] [src]

pub struct Step(pub Step);

Pitch representation in the form of a MIDI-esque Step.

Methods

impl Step
[src]

fn step(&self) -> Step

Return the value in steps.

fn hz(&self) -> Hz

Return the unit value of the equivalent frequency Hz.

fn to_hz(&self) -> Hz

Convert to the equivalent frequency in Hz.

fn letter_octave(&self) -> (Letter, Octave)

Convert to the closest equivalent (Letter, Octave).

fn letter(&self) -> Letter

Convert to the closest equivalent Letter.

fn octave(&self) -> Octave

Convert to the closest equivalent Octave.

fn to_letter_octave(&self) -> LetterOctave

Convert to the closest equivalent LetterOctave.

fn mel(&self) -> Mel

Convert to a Mel unit value.

fn to_mel(&self) -> Mel

Convert to a Mel struct.

fn perc(&self) -> Perc

Convert to the unit value of the equivalent Perc.

fn to_perc(&self) -> Perc

Convert to a percentage of the human hearing range.

fn scaled_perc_with_weight(&self, weight: ScaleWeight) -> Perc

Convert to a scaled percentage of the human hearing range with a given weight.

fn scaled_perc(&self) -> Perc

Convert to a scaled percentage of the human hearing range.

fn to_scaled_perc_with_weight(&self, weight: ScaleWeight) -> ScaledPerc

Convert to a scaled percentage of the human hearing range with a given weight.

fn to_scaled_perc(&self) -> ScaledPerc

Convert to a scaled percentage of the human hearing range.

Trait Implementations

impl Decodable for Step
[src]

fn decode<__D: Decoder>(__arg_0: &mut __D) -> Result<Step, __D::Error>

impl Encodable for Step
[src]

fn encode<__S: Encoder>(&self, __arg_0: &mut __S) -> Result<(), __S::Error>

impl Clone for Step
[src]

fn clone(&self) -> Step

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)
1.0.0

Performs copy-assignment from source. Read more

impl Copy for Step
[src]

impl Debug for Step
[src]

fn fmt(&self, __arg_0: &mut Formatter) -> Result

Formats the value using the given formatter.

impl Add for Step
[src]

type Output = Step

The resulting type after applying the + operator

fn add(self, rhs: Step) -> Step

The method for the + operator

impl Sub for Step
[src]

type Output = Step

The resulting type after applying the - operator

fn sub(self, rhs: Step) -> Step

The method for the - operator

impl Mul for Step
[src]

type Output = Step

The resulting type after applying the * operator

fn mul(self, rhs: Step) -> Step

The method for the * operator

impl Div for Step
[src]

type Output = Step

The resulting type after applying the / operator

fn div(self, rhs: Step) -> Step

The method for the / operator

impl Rem for Step
[src]

type Output = Step

The resulting type after applying the % operator

fn rem(self, rhs: Step) -> Step

The method for the % operator

impl Neg for Step
[src]

type Output = Step

The resulting type after applying the - operator

fn neg(self) -> Step

The method for the unary - operator

impl PartialEq for Step
[src]

fn eq(&self, other: &Step) -> bool

This method tests for self and other values to be equal, and is used by ==. Read more

fn ne(&self, other: &Rhs) -> bool
1.0.0

This method tests for !=.

impl Eq for Step
[src]

impl PartialOrd for Step
[src]

fn partial_cmp(&self, other: &Step) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more

fn lt(&self, other: &Rhs) -> bool
1.0.0

This method tests less than (for self and other) and is used by the < operator. Read more

fn le(&self, other: &Rhs) -> bool
1.0.0

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more

fn gt(&self, other: &Rhs) -> bool
1.0.0

This method tests greater than (for self and other) and is used by the > operator. Read more

fn ge(&self, other: &Rhs) -> bool
1.0.0

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

impl Ord for Step
[src]

fn cmp(&self, other: &Step) -> Ordering

This method returns an Ordering between self and other. Read more