Microsoft DirectX 8.1 (Visual Basic) |
The IsPlaying method ascertains whether a particular segment or
object.IsPlaying( _
segment As DirectMusicSegment8, _
SegmentState8 As DirectMusicSegmentState8 _
) As Boolean
Parts
object
Resolves to a DirectMusicPerformance8 object.
segment
DirectMusicSegment8 to check. If Nothing, check only SegmentState8.
SegmentState8
DirectMusicSegmentState8 to check. If Nothing, check only segment.
Return Values
If the method succeeds and the requested segment or segment state is playing, the return value is True. If neither is playing, or only one was requested and it is not playing, the return value is False.
Error Codes
If the method fails, it raises an error, and Err.Number can be set to one of the following values:
DMUS_E_NO_MASTER_CLOCK |
Remarks
The method returns True only if the segment or segment state is actually playing at the speakers. Because of latency, this method might return False even though DirectMusicPerformance8.PlaySegmentEx has just been called on the segment. Similarly, the method returns True as long as the segment is being heard, even though all messages might already have been dispatched.