Pitch class

Musical pitch.

Constructors

Pitch(int step, [int? octave])
Cerates a pitch.
factory

Properties

hashCode → int
The hash code for this object.
no setteroverride
octave → int
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
step → Step
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toInt() → int
Converts the pitch to the corresponding MIDI note.
toString() → String
A string representation of this object.
inherited
transpose(int semitones) → Pitch
Transposes the pitch by a number of semitones.

Operators

operator <(Pitch other) → bool
operator ==(covariant Pitch other) → bool
The equality operator.
override
operator >(Pitch other) → bool

Static Methods

staffOffsetToStep(int offset) → Step
Converts staff position to a scale step.
stepToStaffOffset(Step step) → int
Converts a step to position on the staff (0 is the bottom).