new Metronome(tempo)
Parameters:
| Name | Type | Argument | Default | Description |
|---|---|---|---|---|
tempo |
number |
<optional> |
music21.tempo.baseTempo | the tempo of the metronome to start |
- Source:
Properties:
| Name | Type | Argument | Default | Description |
|---|---|---|---|---|
tempo |
number | |||
numBeatsPerMeasure |
Int |
<optional> |
4 | |
minTempo |
number |
<optional> |
10 | |
maxTempo |
number |
<optional> |
600 | |
flash |
bool |
<optional> |
false | flash the tempo |
silent |
bool |
<optional> |
false | play silently |
beat |
Int | current beat number |
||
chirpTimeout |
Int | an index of a timeout object for chirping |
Extends
Methods
-
<static> Metronome#addDiv(where) → {JQueryDOMObject}
-
add a Metronome interface onto the DOM at where
Parameters:
Name Type Argument Default Description whereJQueryDOMObject | DOMObject <optional>
'body' - Source:
Returns:
- a div holding the metronome.
- Type
- JQueryDOMObject
-
<static> Metronome#chirp()
-
Play a note (a higher one on the downbeat) and start the metronome chirping.
- Source:
-
<static> Metronome#decreaseSpeed(n) → {number}
-
Decrease the metronome tempo one "click"
To change the tempo, just set this.tempo = n
Parameters:
Name Type Description nInt number of clicks to the left
- Source:
Returns:
new tempo
- Type
- number
-
<static> Metronome#increaseSpeed(n) → {number}
-
Increase the metronome tempo one "click".
Value changes depending on the current tempo. Uses standard metronome guidelines.
To change the tempo, just set this.tempo = n
Parameters:
Name Type Description nInt number of clicks to the right
- Source:
Returns:
new tempo
- Type
- number
-
<static> Metronome#stopChirp()
-
Stop the metronome from chirping.
- Source: