|Microsoft DirectX 9.0|
The StopEx method stops playback of a segment, segment state, or audiopath.
HRESULT StopEx( IUnknown *pObjectToStop, __int64 i64StopTime, DWORD dwFlags );
Pointer to the IUnknown interface of the segment, segment state, or audiopath to stop.
Time at which to stop. If the time is in the past or if 0 is passed in this parameter, the object stops playing immediately.
Flags that adjust the time when the stop should occur. Boundaries are in relation to the current primary segment. Can be 0 or one of the following values. DMUS_SEGF_REFTIME can be combined with one other flag.
|DMUS_SEGF_BEAT||Stop on the next beat boundary at or after i64StopTime.|
|DMUS_SEGF_DEFAULT||Stop on the default boundary, as set by the IDirectMusicSegment8::SetDefaultResolution method.|
|DMUS_SEGF_GRID||Stop on the next grid boundary at or after i64StopTime.|
|DMUS_SEGF_MEASURE||Stop on the next measure boundary at or after i64StopTime.|
|DMUS_SEGF_REFTIME||The value in i64StopTime is in reference time.|
|DMUS_SEGF_SEGMENTEND||Stop at the end of the primary segment.|
|DMUS_SEGF_MARKER||Stop at the next marker.|
If the method succeeds, the return value is S_OK.
If it fails, the method can return E_POINTER.
Stopping a segment stops all instances that are playing. Stopping an audiopath stops all segments playing on that audiopath.
Header: Declared in dmusici.h.