DirectX SDK |
The DirectSoundBuffer.SetCurrentPosition method moves the current play position for secondary sound buffers.
object.SetCurrentPosition(newPosition As Long)
If the method fails, an error is raised and Err.Number may be set to one of the following error values:
DSERR_INVALIDCALL |
DSERR_INVALIDPARAM |
DSERR_PRIOLEVELNEEDED |
This method cannot be called on primary sound buffers.
If the buffer is playing, it will immediately move to the new position and continue. If it is not playing, it will begin from the new position the next time the DirectSoundBuffer.Play method is called.
DirectSoundBuffer, DirectSoundBuffer.GetCurrentPosition, DirectSoundBuffer.Play