public class TrackTimeManager
extends java.lang.Object
MidiParserListener
,
RealtimeMidiParserListener
Constructor and Description |
---|
TrackTimeManager() |
Modifier and Type | Method and Description |
---|---|
void |
addTrackTickTimeBookmark(java.lang.String timeBookmarkID) |
void |
advanceTrackBeatTime(double advanceTime)
Advances the timer for the current track by the specified duration,
which is specified in Pulses Per Quarter (PPQ)
|
protected void |
createTrack(byte track) |
protected byte |
getCurrentLayerNumber() |
byte |
getCurrentTrackNumber() |
double |
getInitialNoteBeatTimeForHarmonicNotes() |
protected byte |
getLastCreatedTrackNumber() |
double |
getLatestTrackBeatTime(byte trackNumber)
Returns the latest track time across all layers in the given track
|
double |
getTrackBeatTime()
Returns the timer for the current track and current layer.
|
double |
getTrackBeatTimeBookmark(java.lang.String timeBookmarkID) |
void |
setAllTrackBeatTime(double newTime)
Sets the timer for all tracks to the given time,
which is specified in Pulses Per Quarter (PPQ)
|
void |
setCurrentLayerNumber(byte layerNumber)
Sets the current layer within the track to which new events will be added.
|
void |
setCurrentTrack(byte trackNumber)
Sets the current track, or channel, to which new events will be added.
|
void |
setInitialNoteBeatTimeForHarmonicNotes(double initialNoteBeatTimeForHarmonicNotes) |
void |
setTrackBeatTime(double newTime)
Sets the timer for the current track by the given time,
which is specified in Pulses Per Quarter (PPQ)
|
public void setCurrentTrack(byte trackNumber)
trackNumber
- the track to selectpublic byte getCurrentTrackNumber()
protected byte getLastCreatedTrackNumber()
protected void createTrack(byte track)
public void setCurrentLayerNumber(byte layerNumber)
layerNumber
- the layer to selectprotected byte getCurrentLayerNumber()
public void setInitialNoteBeatTimeForHarmonicNotes(double initialNoteBeatTimeForHarmonicNotes)
public double getInitialNoteBeatTimeForHarmonicNotes()
public void advanceTrackBeatTime(double advanceTime)
duration
- the duration to increase the track timerpublic void setTrackBeatTime(double newTime)
newTickTime
- the time at which to set the track timerpublic void setAllTrackBeatTime(double newTime)
newTickTime
- the time at which to set the track timerpublic double getTrackBeatTime()
public void addTrackTickTimeBookmark(java.lang.String timeBookmarkID)
public double getTrackBeatTimeBookmark(java.lang.String timeBookmarkID)
public double getLatestTrackBeatTime(byte trackNumber)
trackNumber
-