IDirectMusicTrack8::PlayEx
Causes the track to play in clock time. It performs any work that the track must do when the segment is played, such as creating and sending messages.
HRESULT PlayEx(
void* pStateData,
REFERENCE_TIME rtStart,
REFERENCE_TIME rtEnd,
REFERENCE_TIME rtOffset,
DWORD dwFlags,
IDirectMusicPerformance* pPerf,
IDirectMusicSegmentState* pSegSt,
DWORD dwVirtualID
);
Parameters
- pStateData
- Pointer to state data from the IDirectMusicTrack8::InitPlay method. The format and use of the data is specific to the track.
- rtStart
- Start time.
- rtEnd
- End time.
- rtOffset
- Offset to add to all messages sent to IDirectMusicPerformance8::SendPMsg.
- dwFlags
- Flags that indicate the state of this call. See DMUS_TRACKF_FLAGS. A value of zero indicates that this call to PlayEx continues playback from the previous call.
- pPerf
- Performance used to allocate and send messages.
- pSegSt
- Segment state that this track belongs to. The IDirectMusicSegmentState8::QueryInterface method can be called to obtain an IDirectMusicGraph8 interface—for instance, to call IDirectMusicGraph8::StampPMsg.
- dwVirtualID
- Virtual identifier of the track. This value must be put in the dwVirtualTrackID member of any message (see DMUS_PMSG) that is sent by IDirectMusicPerformance8::SendPMsg.
Return Values
If the method succeeds, the return value can be S_OK or DMUS_S_END.
If it fails, the method can return one of the following error values:
Header: Declared in dmplugin.h.
See Also
IDirectMusicTrack8::Play