Microsoft Windows CE 3.0  

IDirectSoundNotify::SetNotificationPositions

Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

The IDirectSoundCaptureBuffer::SetNotificationPositionsmethod sets the notification positions. During capture or playback, whenever the position reaches an offset specified in one of the DSBPOSITIONNOTIFYstructures in the caller-supplied array, the associated event will be signaled. The position tracked in playback is the current play position; in capture it is the current read position.

HRESULT SetNotificationPositions(
DWORD
cPositionNotifies
,
LPCDSBPOSITIONNOTIFY
lpcPositionNotifies
);

Parameters

cPositionNotifies
Number of DSBPOSITIONNOTIFYstructures.
lpcPositionNotifies
Pointer to an array of DSBPOSITIONNOTIFYstructures. This array must be sorted in ascending order. This is true for both capture and playback.

Return Values

If the method succeeds, the return value is DS_OK.

If the method fails, the return value may be one of the following error values:

Remarks

The value DSBPN_OFFSETSTOP can be specified in the dwOffsetmember to tell DirectSound to signal the associated event when the IDirectSoundBuffer::Stopor IDirectSoundCaptureBuffer::Stopmethod is called or when the end of the buffer has been reached and the playback is not looping. If it is used, this should be the last item in the position-notify array.

If a position-notify array has already been set, calling this function again will replace the previous position-notify array.

The buffer must be stopped when this method is called.

To clear all previously set notifications, set cPositionNotifiesto 0 and lpcPositionNotifiesto NULL.

Requirements

Runs On Versions Defined in Include Link to
Windows CE OS 2.12 or later. Version 2.12 requires DXPAK 1.0 or later. dsound.h   dsound.lib
Note   This API is part of the complete Windows CE OS package as provided by Microsoft. The functionality of a particular platform is determined by the original equipment manufacturer (OEM) and some devices may not support this API.