Share via


ISpSREngine::PrivateCall (Windows Embedded CE 6.0)

1/6/2010

This method handles an engine extension call to the SR engine. SAPI marshals the data supplied and calls this method when the engine extension COM object calls _ISpPrivateEngineCall::CallEngine.

To support this method, the engine must implement an engine extension COM object that supports any interfaces the engine requires. Support of this extension object allows an application to call IUnknown::QueryInterface on the speech recognition context object (ISpRecoContext) for these interfaces.

The appropriate engine extension object can then query for the _ISpPrivateEngineCall interface from the recognition context. If it needs to communicate with the main engine, the extension object calls _ISpPrivateEngineCall::CallEngine, which passes the provided data to ISpSREngine::PrivateCall.

Syntax

HRESULT PrivateCall(
  void* pvEngineContext, 
  PVOID* pCallFrame,
  ULONG ulCallFrameSize
);

Parameters

  • pvEngineContext
    [in] Pointer to the speech recognition context for the engine. The pointer is retrieved by a prior call to the ISpSREngine::OnCreateRecoContext method.
  • pCallFrame
    [in, out] Pointer to engine-specific data. On input, this value indicates data for the engine to use. On output, it indicates data from the engine. The retrieved data must be the same size as the input data.
  • ulCallFrameSize
    [in] Size, in bytes, of the engine-specific data indicated by pCallFrame.

Return Value

The following table shows the possible return values.

Value Description

S_OK

Function completed successfully.

FAILED(hr)

Appropriate error message.

Requirements

Header sapiddk.h, sapiddk.idl
Library sapilib.lib
Windows Embedded CE Windows CE .NET 4.1 and later

See Also

Reference

ISpSREngine
SAPI Interfaces