note note (symbol_or_number)
Takes a midi note, a symbol (e.g. :C) or a string (e.g. "C") and resolves it to a midi note. You can also pass an optional octave: parameter to get the midi note for a given octave. Please note - octave: param overrides any octave specified in a symbol i.e. :c3. If the note is nil, :r or :rest, then nil is returned (nil represents a rest)
Introduced in v2.0
| octave: |
The octave of the note. Overrides any octave declaration in the note symbol such as :c2. Default is 4 |
| # Example 1 | |
|
|
|
| # Example 2 | |
|
|
|