Note
Please see Azure Cognitive Services for Speech documentation for the latest supported speech solutions.
Microsoft Speech Platform
ISpStreamFormatConverter::ScaleBaseToConvertedOffset
ISpStreamFormatConverter::ScaleBaseToConvertedOffset converts an offset in the base stream into the equivalent offset in the converted stream. This method is primarily used internally to map event offsets.
<pre IsFakePre="true" xmlns="http://www.w3.org/1999/xhtml"> <strong>HRESULT ScaleBaseToConvertedOffset(</strong> <strong> ULONGLONG</strong> <em>ullOffsetBaseStream</em>, <strong> ULONGLONG</strong> *<em>pullOffsetConvertedStream</em> <strong>);</strong> </pre>
Parameters
- ullOffsetBaseStream
The current offset in the base (unconverted) stream. - pullOffsetConvertedStream
The new offset in the output (converted) stream.
Return Values
Value | Description |
---|---|
S_OK | Function completed successfully. |
E_POINTER | pullOffsetConvertedStream is bad or invalid. |
SPERR_UNINITIALIZED | The base stream is not initialized. |
E_INVALIDARG | ullOffsetBaseStream is less than the initial seek position of the current steam. |
Remarks
When performing a mapping with a compressed format, it is possible to introduce small rounding errors, since the content of the audio is not used to perform the conversion.