A MIDI Library for .NET

PitchExtensionMethods.NoteWithLetter Method

Returns the note that would name this pitch if it used the given letter.

[Extension]
public static Note NoteWithLetter(
   this Pitch pitch,
   this char letter
);

Parameters

pitch
The pitch being named.
letter
The letter to use in the name, in ['A'..'G'].

Return Value

The note for pitch with letter. The result may have a large number of accidentals if pitch is not easily named by letter.

Exceptions

Exception Type Condition
ArgumentOutOfRangeException letter is out of range.

See Also

PitchExtensionMethods Class | Midi Namespace