ISpStreamFormatConverter::SetBaseStream (Windows CE 5.0)
This method sets an audio stream to be wrapped by the format converter. The format converter is a stream object that encapsulates the base (unconverted) stream and does dynamic format conversion during read/write operations.
HRESULT SetBaseStream(ISpStreamFormat* pStream,BOOL fSetFormatToBaseStreamFormat,BOOL fWriteToBaseStream);
Parameters
- pStream
[in] Pointer to the ISpStreamFormat object for the stream to be wrapped. If NULL, the current base stream is released and any associated resources are released. - fSetFormatToBaseStreamFormat
[in] Value specifying if the format converter is to set the converter stream format to the format used by the base stream (set up as a pass-through). Set this value to TRUE to set the converter stream format to the base stream format, and to FALSE otherwise. If pStream is set to NULL and this parameter is set to TRUE, the format converter resets the stream format to be undefined. - fWriteToBaseStream
[in] Value specifying how the format converter is to handle I/O for the base stream. Set this value to TRUE if the format converter writes data to the base stream, and to FALSE if the format converter reads data from the base stream. The format converter can only be in one I/O mode at a time.
Return Values
The following table shows the possible return values.
Value | Description |
---|---|
S_OK | Function completed successfully. |
E_INVALIDARG | pStream was invalid. |
Requirements
OS Versions: Windows CE .NET 4.1 and later.
Header: Sapi.h, Sapi.idl.
Link Library: Sapilib.lib.
See Also
ISpStreamFormatConverter | SAPI Interfaces
Send Feedback on this topic to the authors