mirror of
https://github.com/cookiengineer/audacity
synced 2025-10-25 07:43:54 +02:00
Try to clarify real time / track time distinction in comments...
... Rather than the confusing old terminology of "warped" time, meaning the real time after accounting for time track, though that persists mostly in the names of variables now mostly used only within PlaybackSchedule. "Track" time refers to a position in a wave track, as indexed by the time ruler. "Real" time is indexed by the other scale of numbers drawn in the time track, which is drawn on the screen with nonuniform spacing (so "warped" in that sense), but it corresponds to uniform actual time.
This commit is contained in:
@@ -429,7 +429,7 @@ class AUDACITY_DLL_API AudioIO final {
|
||||
*/
|
||||
static int GetOptimalSupportedSampleRate();
|
||||
|
||||
/** \brief During playback, the (unwarped) track time most recently played
|
||||
/** \brief During playback, the track time most recently played
|
||||
*
|
||||
* When playing looped, this will start from t0 again,
|
||||
* too. So the returned time should be always between
|
||||
@@ -520,7 +520,7 @@ private:
|
||||
void PrepareMidiIterator(bool send = true, double offset = 0);
|
||||
bool StartPortMidiStream();
|
||||
|
||||
// Compute nondecreasing time stamps, accounting for pauses, but not the
|
||||
// Compute nondecreasing real time stamps, accounting for pauses, but not the
|
||||
// synth latency.
|
||||
double UncorrectedMidiEventTime();
|
||||
|
||||
@@ -648,7 +648,7 @@ private:
|
||||
std::vector< std::pair< int, int > > mPendingNotesOff;
|
||||
#endif
|
||||
|
||||
/// Time at which the next event should be output, measured in seconds.
|
||||
/// Real time at which the next event should be output, measured in seconds.
|
||||
/// Note that this could be a note's time+duration for note offs.
|
||||
double mNextEventTime;
|
||||
/// Track of next event
|
||||
@@ -840,7 +840,7 @@ private:
|
||||
std::atomic<double> mTime;
|
||||
|
||||
/// Accumulated real time (not track position), starting at zero (unlike
|
||||
/// mTime), and wrapping back to zero each time around looping play.
|
||||
/// mTime), and wrapping back to zero each time around looping play.
|
||||
/// Thus, it is the length in real seconds between mT0 and mTime.
|
||||
double mWarpedTime;
|
||||
|
||||
@@ -939,7 +939,7 @@ private:
|
||||
// time track if one is given; result is always nonnegative
|
||||
double RealDuration(double trackTime1) const;
|
||||
|
||||
// How much real ("warped") time left?
|
||||
// How much real time left?
|
||||
double RealTimeRemaining() const;
|
||||
|
||||
// Advance the real time position
|
||||
|
||||
Reference in New Issue
Block a user