PIBIO_ENGINE_QUERY_PREFERRED_FORMAT_FN回呼函式 (winbio_adapter.h)

由生物特徵辨識單位上的感應器配接器呼叫,以判斷引擎配接器慣用的輸入資料格式。

語法

PIBIO_ENGINE_QUERY_PREFERRED_FORMAT_FN PibioEngineQueryPreferredFormatFn;

HRESULT PibioEngineQueryPreferredFormatFn(
  [in, out] PWINBIO_PIPELINE Pipeline,
  [out]     PWINBIO_REGISTERED_FORMAT StandardFormat,
  [out]     PWINBIO_UUID VendorFormat
)
{...}

參數

[in, out] Pipeline

與執行作業之生物特徵辨識單位相關聯的 WINBIO_PIPELINE 結構的指標。

[out] StandardFormat

WINBIO_REGISTERED_FORMAT結構的指標,指定WINBIO_BIR物件之 StandardDataBlock成員中的資料格式。 格式是 IBIA 註冊的名稱/值組。

[out] VendorFormat

GUID 的指標,該 GUID 會接收WINBIO_BIR物件之 VendorDataBlock成員中廠商定義之資料的格式。

傳回值

如果函式成功,它會傳回S_OK。 如果函式失敗,它必須傳回下列其中一個 HRESULT 值,以指出錯誤。

傳回碼 描述
E_POINTER
強制指標參數為 Null

備註

感應器配接器會呼叫此函式來判斷生物特徵辨識擷取格式。

範例

下列虛擬程式碼顯示此函式的一個可能實作。 此範例不會編譯。 您必須調整它以符合您的用途。

//////////////////////////////////////////////////////////////////////////////////////////
//
// EngineAdapterQueryPreferredFormat
//
// Purpose:
//      Called by the sensor adapter on the biometric unit to determine the 
//      input data format preferred by the engine adapter.
//
// Parameters:
//      Pipeline        - Pointer to a WINBIO_PIPELINE structure associated 
//                        with the biometric unit performing the operation.
//      StandardFormat  - Pointer to a WINBIO_REGISTERED_FORMAT structure 
//                        that specifies the format of the data in the 
//                        StandardDataBlock member of the WINBIO_BIR object. 
//                        The format is an IBIA-registered name/value pair.
//      VendorFormat    - Pointer to a GUID that receives the vendor-defined 
//                        format of the data in the VendorDataBlock member of 
//                        the WINBIO_BIR object.
//
static HRESULT
WINAPI
EngineAdapterQueryPreferredFormat(
    __inout PWINBIO_PIPELINE Pipeline,
    __out PWINBIO_REGISTERED_FORMAT StandardFormat,
    __out PWINBIO_UUID VendorFormat
    )
{
   HRESULT hr = S_OK;

   // Verify that pointer arguments are not NULL.
   if (!ARGUMENT_PRESENT(Pipeline) ||
       !ARGUMENT_PRESENT(StandardFormat) ||
       !ARGUMENT_PRESENT(VendorFormat))
   {
        hr = E_POINTER;
        goto cleanup;
   }

   // Specify the preferred data formats.
   StandardFormat->Owner = WINBIO_ANSI_381_FORMAT_OWNER;
   StandardFormat->Type = WINBIO_ANSI_381_FORMAT_TYPE;
   *VendorFormat = VENDOR_UUID_VALUE;

cleanup:

    return hr;
}

規格需求

   
最低支援的用戶端 Windows 7 [僅限傳統型應用程式]
最低支援的伺服器 Windows Server 2008 R2 [僅限傳統型應用程式]
目標平台 Windows
標頭 winbio_adapter.h (包含 Winbio_adapter.h)

另請參閱

外掛程式函式