Platform SDK: DirectX

IDirectMusicPerformance::TimeToRhythm

The IDirectMusicPerformance::TimeToRhythm method converts music time to rhythm time.

HRESULT TimeToRhythm(
  MUSIC_TIME mtTime,
  DMUS_TIMESIGNATURE *pTimeSig,
  WORD *pwMeasure,
  BYTE *pbBeat,
  BYTE *pbGrid,
  short *pnOffset
);

Parameters

mtTime
Time to convert.
pTimeSig
Address of a DMUS_TIMESIGNATURE structure that contains information about the time signature.
pwMeasure
Address of a variable to receive the measure in which the time falls.
pbBeat
Address of a variable to receive the beat at which the time falls.
pbGrid
Address of a variable to receive the grid at which the time falls.
pnOffset
Address of a variable to receive the offset from the grid (in music-time ticks) at which the time falls.

Return Values

If the method succeeds, the return value is S_OK.

Requirements

  Windows NT/2000: Requires Windows 2000.
  Windows 95/98: Requires Windows 95 or later. Available as a redistributable for Windows 95.
  Header: Declared in dmusici.h.

See Also

IDirectMusicPerformance::RhythmToTime