Share via


ISpSREngineSite::DataAvailable (SAPI 5.3)

Microsoft Speech API 5.3

ISpSREngineSite::DataAvailable

ISpSREngineSite::DataAvailable retrieves the amount of data that can be read using ISpSREngineSite::Read without blocking.

This method can only be called while the SR engine is inside a ISpSREngine::RecognizeStream call, although it can be called on any thread.

  
    HRESULT DataAvailable(
   ULONG   *pcb
);

Parameters

  • pcb
    [out] The amount, in bytes, of data available. For real-time audio streams this is the actual amount of data currently available. For non real-time streams this method will always return the value INFINITE. Using the fRealTimeAudio parameter on the RecognizeStream method, engines can determine whether this is a real-time stream.

Return values

Value
S_OK
E_POINTER
SPERR_STREAM_NOT_ACTIVE
FAILED(hr)