Microsoft DirectX 8.0 (Visual Basic) |
Converts time in music time format to time in clock time format.
object.MusicToClockTime(mtTime As Long) As Long
Returns the time in clock time units.
If the method fails, it raises an error, and Err.Number can be set to DMUS_E_NO_MASTER_CLOCK.
This method converts a time offset from the start of the performance, not a duration. The ratio between music time and clock time units depends on the tempo, so in making the conversion, DirectMusic takes into account all tempo changes since the start of the performance. If a master tempo has been set for the performance, it is taken into account as well.
Because clock time has a greater precision than music time, a time that has been converted from clock time to music time, and then back again, will probably not have its original value.
DirectMusicPerformance8.ClockToMusicTime, Clock Time vs. Music Time