ISpTTSEngineSite::Write (Windows CE 5.0)

Send Feedback

This method sends output data (typically audio) to SAPI, which then routes it to the correct output destination. Before calling this method, the TTS engine must queue any events associated with the output data by calling the ISpEventSink::AddEvents method. This ensures proper synchronization of event firing and data rendering.

HRESULT Write(const void* pBuff,ULONG cb,ULONG* pcbWritten);

Parameters

  • pBuff
    [in] Pointer to synthesized speech audio data. The output format is specified by SAPI in a call to the ISpTTSEngine::Speak call method.
  • cb
    [in] Size, in bytes (not samples), of the buffer specified by pBuff.
  • pcbWritten
    [out] Pointer to the number of bytes actually copied.

Return Values

The following table shows the possible return values.

Value Description
S_OK Function completed successfully.
E_INVALIDARG pBuff is bad or invalid.
E_POINTER pcbWritten is bad or invalid.
SPERR_UNINITIALIZED Output stream cannot be initialized.

Requirements

OS Versions: Windows CE .NET 4.1 and later.
Header: Sapiddk.h, Sapiddk.idl.
Link Library: Sapilib.lib.

See Also

ISpTTSEngineSite | SAPI Interfaces

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.