Win32 API 日本語リファレンス
ホームDevices.BiometricFramework › WINBIO_SENSOR_INTERFACE

WINBIO_SENSOR_INTERFACE

構造体
サイズx64: 280 バイト / x86: 152 バイト

サイズ=各フィールドのバイト数(x64/x86 で異なる場合は x64/x86 と併記)。x64/x86 列=フィールドのバイトオフセット(HSPで dupptr / lpoke / wpoke 等に使用)。

フィールド

フィールドサイズx64x86説明
VersionWINBIO_ADAPTER_INTERFACE_VERSION4+0+0このセンサアダプタインターフェースのバージョン。
TypeDWORD4+4+4アダプタの種別(センサ)を示す値。
SizeUINT_PTR8/4+8+8この構造体のサイズ(バイト)。
AdapterIdGUID16+16+12アダプタを一意に識別するGUID。
AttachPIBIO_SENSOR_ATTACH_FN8/4+32+28ユニットへのアタッチ時に呼ばれる関数ポインタ。
DetachPIBIO_SENSOR_DETACH_FN8/4+40+32ユニットからのデタッチ時に呼ばれる関数ポインタ。
ClearContextPIBIO_SENSOR_CLEAR_CONTEXT_FN8/4+48+36コンテキストをクリアする関数ポインタ。
QueryStatusPIBIO_SENSOR_QUERY_STATUS_FN8/4+56+40センサの状態を問い合わせる関数ポインタ。
ResetPIBIO_SENSOR_RESET_FN8/4+64+44センサをリセットする関数ポインタ。
SetModePIBIO_SENSOR_SET_MODE_FN8/4+72+48センサの動作モードを設定する関数ポインタ。
SetIndicatorStatusPIBIO_SENSOR_SET_INDICATOR_STATUS_FN8/4+80+52センサのインジケータ表示を設定する関数ポインタ。
GetIndicatorStatusPIBIO_SENSOR_GET_INDICATOR_STATUS_FN8/4+88+56センサのインジケータ表示状態を取得する関数ポインタ。
StartCapturePIBIO_SENSOR_START_CAPTURE_FN8/4+96+60サンプルのキャプチャを開始する関数ポインタ。
FinishCapturePIBIO_SENSOR_FINISH_CAPTURE_FN8/4+104+64キャプチャを完了する関数ポインタ。
ExportSensorDataPIBIO_SENSOR_EXPORT_SENSOR_DATA_FN8/4+112+68センサデータをエクスポートする関数ポインタ。
CancelPIBIO_SENSOR_CANCEL_FN8/4+120+72進行中の操作をキャンセルする関数ポインタ。
PushDataToEnginePIBIO_SENSOR_PUSH_DATA_TO_ENGINE_FN8/4+128+76取得データをエンジンへ送る関数ポインタ。
ControlUnitPIBIO_SENSOR_CONTROL_UNIT_FN8/4+136+80ユニットへ制御コマンドを送る関数ポインタ。
ControlUnitPrivilegedPIBIO_SENSOR_CONTROL_UNIT_PRIVILEGED_FN8/4+144+84特権付きの制御コマンドを送る関数ポインタ。
NotifyPowerChangePIBIO_SENSOR_NOTIFY_POWER_CHANGE_FN8/4+152+88電源状態変化を通知する関数ポインタ。
PipelineInitPIBIO_SENSOR_PIPELINE_INIT_FN8/4+160+92パイプラインを初期化する関数ポインタ。
PipelineCleanupPIBIO_SENSOR_PIPELINE_CLEANUP_FN8/4+168+96パイプラインを後始末する関数ポインタ。
ActivatePIBIO_SENSOR_ACTIVATE_FN8/4+176+100センサを有効化する関数ポインタ。
DeactivatePIBIO_SENSOR_DEACTIVATE_FN8/4+184+104センサを無効化する関数ポインタ。
QueryExtendedInfoPIBIO_SENSOR_QUERY_EXTENDED_INFO_FN8/4+192+108拡張センサ情報を問い合わせる関数ポインタ。
QueryCalibrationFormatsPIBIO_SENSOR_QUERY_CALIBRATION_FORMATS_FN8/4+200+112対応する校正形式を問い合わせる関数ポインタ。
SetCalibrationFormatPIBIO_SENSOR_SET_CALIBRATION_FORMAT_FN8/4+208+116校正形式を設定する関数ポインタ。
AcceptCalibrationDataPIBIO_SENSOR_ACCEPT_CALIBRATION_DATA_FN8/4+216+120校正データを受け取る関数ポインタ。
AsyncImportRawBufferPIBIO_SENSOR_ASYNC_IMPORT_RAW_BUFFER_FN8/4+224+124生バッファを非同期にインポートする関数ポインタ。
AsyncImportSecureBufferPIBIO_SENSOR_ASYNC_IMPORT_SECURE_BUFFER_FN8/4+232+128セキュアバッファを非同期にインポートする関数ポインタ。
QueryPrivateSensorTypePIBIO_SENSOR_QUERY_PRIVATE_SENSOR_TYPE_FN8/4+240+132プライベートセンサ種別を問い合わせる関数ポインタ。
ConnectSecurePIBIO_SENSOR_CONNECT_SECURE_FN8/4+248+136センサとのセキュア接続を確立する関数ポインタ。
StartCaptureExPIBIO_SENSOR_START_CAPTURE_EX_FN8/4+256+140拡張オプション付きでキャプチャを開始する関数ポインタ。
StartNotifyWakePIBIO_SENSOR_START_NOTIFY_WAKE_FN8/4+264+144ウェイク通知の待機を開始する関数ポインタ。
FinishNotifyWakePIBIO_SENSOR_FINISH_NOTIFY_WAKE_FN8/4+272+148ウェイク通知の待機を完了する関数ポインタ。

各言語での定義

#include <windows.h>

// WINBIO_ADAPTER_INTERFACE_VERSION  (x64 4 / x86 4 バイト)
typedef struct WINBIO_ADAPTER_INTERFACE_VERSION {
    WORD MajorVersion;
    WORD MinorVersion;
} WINBIO_ADAPTER_INTERFACE_VERSION;

// WINBIO_SENSOR_INTERFACE  (x64 280 / x86 152 バイト)
typedef struct WINBIO_SENSOR_INTERFACE {
    WINBIO_ADAPTER_INTERFACE_VERSION Version;
    DWORD Type;
    UINT_PTR Size;
    GUID AdapterId;
    PIBIO_SENSOR_ATTACH_FN Attach;
    PIBIO_SENSOR_DETACH_FN Detach;
    PIBIO_SENSOR_CLEAR_CONTEXT_FN ClearContext;
    PIBIO_SENSOR_QUERY_STATUS_FN QueryStatus;
    PIBIO_SENSOR_RESET_FN Reset;
    PIBIO_SENSOR_SET_MODE_FN SetMode;
    PIBIO_SENSOR_SET_INDICATOR_STATUS_FN SetIndicatorStatus;
    PIBIO_SENSOR_GET_INDICATOR_STATUS_FN GetIndicatorStatus;
    PIBIO_SENSOR_START_CAPTURE_FN StartCapture;
    PIBIO_SENSOR_FINISH_CAPTURE_FN FinishCapture;
    PIBIO_SENSOR_EXPORT_SENSOR_DATA_FN ExportSensorData;
    PIBIO_SENSOR_CANCEL_FN Cancel;
    PIBIO_SENSOR_PUSH_DATA_TO_ENGINE_FN PushDataToEngine;
    PIBIO_SENSOR_CONTROL_UNIT_FN ControlUnit;
    PIBIO_SENSOR_CONTROL_UNIT_PRIVILEGED_FN ControlUnitPrivileged;
    PIBIO_SENSOR_NOTIFY_POWER_CHANGE_FN NotifyPowerChange;
    PIBIO_SENSOR_PIPELINE_INIT_FN PipelineInit;
    PIBIO_SENSOR_PIPELINE_CLEANUP_FN PipelineCleanup;
    PIBIO_SENSOR_ACTIVATE_FN Activate;
    PIBIO_SENSOR_DEACTIVATE_FN Deactivate;
    PIBIO_SENSOR_QUERY_EXTENDED_INFO_FN QueryExtendedInfo;
    PIBIO_SENSOR_QUERY_CALIBRATION_FORMATS_FN QueryCalibrationFormats;
    PIBIO_SENSOR_SET_CALIBRATION_FORMAT_FN SetCalibrationFormat;
    PIBIO_SENSOR_ACCEPT_CALIBRATION_DATA_FN AcceptCalibrationData;
    PIBIO_SENSOR_ASYNC_IMPORT_RAW_BUFFER_FN AsyncImportRawBuffer;
    PIBIO_SENSOR_ASYNC_IMPORT_SECURE_BUFFER_FN AsyncImportSecureBuffer;
    PIBIO_SENSOR_QUERY_PRIVATE_SENSOR_TYPE_FN QueryPrivateSensorType;
    PIBIO_SENSOR_CONNECT_SECURE_FN ConnectSecure;
    PIBIO_SENSOR_START_CAPTURE_EX_FN StartCaptureEx;
    PIBIO_SENSOR_START_NOTIFY_WAKE_FN StartNotifyWake;
    PIBIO_SENSOR_FINISH_NOTIFY_WAKE_FN FinishNotifyWake;
} WINBIO_SENSOR_INTERFACE;
using System;
using System.Runtime.InteropServices;

[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct WINBIO_ADAPTER_INTERFACE_VERSION
{
    public ushort MajorVersion;
    public ushort MinorVersion;
}

[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct WINBIO_SENSOR_INTERFACE
{
    public WINBIO_ADAPTER_INTERFACE_VERSION Version;
    public uint Type;
    public UIntPtr Size;
    public Guid AdapterId;
    public IntPtr Attach;
    public IntPtr Detach;
    public IntPtr ClearContext;
    public IntPtr QueryStatus;
    public IntPtr Reset;
    public IntPtr SetMode;
    public IntPtr SetIndicatorStatus;
    public IntPtr GetIndicatorStatus;
    public IntPtr StartCapture;
    public IntPtr FinishCapture;
    public IntPtr ExportSensorData;
    public IntPtr Cancel;
    public IntPtr PushDataToEngine;
    public IntPtr ControlUnit;
    public IntPtr ControlUnitPrivileged;
    public IntPtr NotifyPowerChange;
    public IntPtr PipelineInit;
    public IntPtr PipelineCleanup;
    public IntPtr Activate;
    public IntPtr Deactivate;
    public IntPtr QueryExtendedInfo;
    public IntPtr QueryCalibrationFormats;
    public IntPtr SetCalibrationFormat;
    public IntPtr AcceptCalibrationData;
    public IntPtr AsyncImportRawBuffer;
    public IntPtr AsyncImportSecureBuffer;
    public IntPtr QueryPrivateSensorType;
    public IntPtr ConnectSecure;
    public IntPtr StartCaptureEx;
    public IntPtr StartNotifyWake;
    public IntPtr FinishNotifyWake;
}
Imports System.Runtime.InteropServices

<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure WINBIO_ADAPTER_INTERFACE_VERSION
    Public MajorVersion As UShort
    Public MinorVersion As UShort
End Structure

<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure WINBIO_SENSOR_INTERFACE
    Public Version As WINBIO_ADAPTER_INTERFACE_VERSION
    Public Type As UInteger
    Public Size As UIntPtr
    Public AdapterId As Guid
    Public Attach As IntPtr
    Public Detach As IntPtr
    Public ClearContext As IntPtr
    Public QueryStatus As IntPtr
    Public Reset As IntPtr
    Public SetMode As IntPtr
    Public SetIndicatorStatus As IntPtr
    Public GetIndicatorStatus As IntPtr
    Public StartCapture As IntPtr
    Public FinishCapture As IntPtr
    Public ExportSensorData As IntPtr
    Public Cancel As IntPtr
    Public PushDataToEngine As IntPtr
    Public ControlUnit As IntPtr
    Public ControlUnitPrivileged As IntPtr
    Public NotifyPowerChange As IntPtr
    Public PipelineInit As IntPtr
    Public PipelineCleanup As IntPtr
    Public Activate As IntPtr
    Public Deactivate As IntPtr
    Public QueryExtendedInfo As IntPtr
    Public QueryCalibrationFormats As IntPtr
    Public SetCalibrationFormat As IntPtr
    Public AcceptCalibrationData As IntPtr
    Public AsyncImportRawBuffer As IntPtr
    Public AsyncImportSecureBuffer As IntPtr
    Public QueryPrivateSensorType As IntPtr
    Public ConnectSecure As IntPtr
    Public StartCaptureEx As IntPtr
    Public StartNotifyWake As IntPtr
    Public FinishNotifyWake As IntPtr
End Structure
import ctypes
from ctypes import wintypes

class WINBIO_ADAPTER_INTERFACE_VERSION(ctypes.Structure):
    _fields_ = [
        ("MajorVersion", ctypes.c_ushort),
        ("MinorVersion", ctypes.c_ushort),
    ]

class WINBIO_SENSOR_INTERFACE(ctypes.Structure):
    _fields_ = [
        ("Version", WINBIO_ADAPTER_INTERFACE_VERSION),
        ("Type", wintypes.DWORD),
        ("Size", ctypes.c_size_t),
        ("AdapterId", GUID),
        ("Attach", ctypes.c_void_p),
        ("Detach", ctypes.c_void_p),
        ("ClearContext", ctypes.c_void_p),
        ("QueryStatus", ctypes.c_void_p),
        ("Reset", ctypes.c_void_p),
        ("SetMode", ctypes.c_void_p),
        ("SetIndicatorStatus", ctypes.c_void_p),
        ("GetIndicatorStatus", ctypes.c_void_p),
        ("StartCapture", ctypes.c_void_p),
        ("FinishCapture", ctypes.c_void_p),
        ("ExportSensorData", ctypes.c_void_p),
        ("Cancel", ctypes.c_void_p),
        ("PushDataToEngine", ctypes.c_void_p),
        ("ControlUnit", ctypes.c_void_p),
        ("ControlUnitPrivileged", ctypes.c_void_p),
        ("NotifyPowerChange", ctypes.c_void_p),
        ("PipelineInit", ctypes.c_void_p),
        ("PipelineCleanup", ctypes.c_void_p),
        ("Activate", ctypes.c_void_p),
        ("Deactivate", ctypes.c_void_p),
        ("QueryExtendedInfo", ctypes.c_void_p),
        ("QueryCalibrationFormats", ctypes.c_void_p),
        ("SetCalibrationFormat", ctypes.c_void_p),
        ("AcceptCalibrationData", ctypes.c_void_p),
        ("AsyncImportRawBuffer", ctypes.c_void_p),
        ("AsyncImportSecureBuffer", ctypes.c_void_p),
        ("QueryPrivateSensorType", ctypes.c_void_p),
        ("ConnectSecure", ctypes.c_void_p),
        ("StartCaptureEx", ctypes.c_void_p),
        ("StartNotifyWake", ctypes.c_void_p),
        ("FinishNotifyWake", ctypes.c_void_p),
    ]
#[repr(C)]
pub struct WINBIO_ADAPTER_INTERFACE_VERSION {
    pub MajorVersion: u16,
    pub MinorVersion: u16,
}

#[repr(C)]
pub struct WINBIO_SENSOR_INTERFACE {
    pub Version: WINBIO_ADAPTER_INTERFACE_VERSION,
    pub Type: u32,
    pub Size: usize,
    pub AdapterId: GUID,
    pub Attach: *mut core::ffi::c_void,
    pub Detach: *mut core::ffi::c_void,
    pub ClearContext: *mut core::ffi::c_void,
    pub QueryStatus: *mut core::ffi::c_void,
    pub Reset: *mut core::ffi::c_void,
    pub SetMode: *mut core::ffi::c_void,
    pub SetIndicatorStatus: *mut core::ffi::c_void,
    pub GetIndicatorStatus: *mut core::ffi::c_void,
    pub StartCapture: *mut core::ffi::c_void,
    pub FinishCapture: *mut core::ffi::c_void,
    pub ExportSensorData: *mut core::ffi::c_void,
    pub Cancel: *mut core::ffi::c_void,
    pub PushDataToEngine: *mut core::ffi::c_void,
    pub ControlUnit: *mut core::ffi::c_void,
    pub ControlUnitPrivileged: *mut core::ffi::c_void,
    pub NotifyPowerChange: *mut core::ffi::c_void,
    pub PipelineInit: *mut core::ffi::c_void,
    pub PipelineCleanup: *mut core::ffi::c_void,
    pub Activate: *mut core::ffi::c_void,
    pub Deactivate: *mut core::ffi::c_void,
    pub QueryExtendedInfo: *mut core::ffi::c_void,
    pub QueryCalibrationFormats: *mut core::ffi::c_void,
    pub SetCalibrationFormat: *mut core::ffi::c_void,
    pub AcceptCalibrationData: *mut core::ffi::c_void,
    pub AsyncImportRawBuffer: *mut core::ffi::c_void,
    pub AsyncImportSecureBuffer: *mut core::ffi::c_void,
    pub QueryPrivateSensorType: *mut core::ffi::c_void,
    pub ConnectSecure: *mut core::ffi::c_void,
    pub StartCaptureEx: *mut core::ffi::c_void,
    pub StartNotifyWake: *mut core::ffi::c_void,
    pub FinishNotifyWake: *mut core::ffi::c_void,
}
import "golang.org/x/sys/windows"

type WINBIO_ADAPTER_INTERFACE_VERSION struct {
	MajorVersion uint16
	MinorVersion uint16
}

type WINBIO_SENSOR_INTERFACE struct {
	Version WINBIO_ADAPTER_INTERFACE_VERSION
	Type uint32
	Size uintptr
	AdapterId windows.GUID
	Attach uintptr
	Detach uintptr
	ClearContext uintptr
	QueryStatus uintptr
	Reset uintptr
	SetMode uintptr
	SetIndicatorStatus uintptr
	GetIndicatorStatus uintptr
	StartCapture uintptr
	FinishCapture uintptr
	ExportSensorData uintptr
	Cancel uintptr
	PushDataToEngine uintptr
	ControlUnit uintptr
	ControlUnitPrivileged uintptr
	NotifyPowerChange uintptr
	PipelineInit uintptr
	PipelineCleanup uintptr
	Activate uintptr
	Deactivate uintptr
	QueryExtendedInfo uintptr
	QueryCalibrationFormats uintptr
	SetCalibrationFormat uintptr
	AcceptCalibrationData uintptr
	AsyncImportRawBuffer uintptr
	AsyncImportSecureBuffer uintptr
	QueryPrivateSensorType uintptr
	ConnectSecure uintptr
	StartCaptureEx uintptr
	StartNotifyWake uintptr
	FinishNotifyWake uintptr
}
type
  WINBIO_ADAPTER_INTERFACE_VERSION = record
    MajorVersion: Word;
    MinorVersion: Word;
  end;

  WINBIO_SENSOR_INTERFACE = record
    Version: WINBIO_ADAPTER_INTERFACE_VERSION;
    Type: DWORD;
    Size: NativeUInt;
    AdapterId: TGUID;
    Attach: Pointer;
    Detach: Pointer;
    ClearContext: Pointer;
    QueryStatus: Pointer;
    Reset: Pointer;
    SetMode: Pointer;
    SetIndicatorStatus: Pointer;
    GetIndicatorStatus: Pointer;
    StartCapture: Pointer;
    FinishCapture: Pointer;
    ExportSensorData: Pointer;
    Cancel: Pointer;
    PushDataToEngine: Pointer;
    ControlUnit: Pointer;
    ControlUnitPrivileged: Pointer;
    NotifyPowerChange: Pointer;
    PipelineInit: Pointer;
    PipelineCleanup: Pointer;
    Activate: Pointer;
    Deactivate: Pointer;
    QueryExtendedInfo: Pointer;
    QueryCalibrationFormats: Pointer;
    SetCalibrationFormat: Pointer;
    AcceptCalibrationData: Pointer;
    AsyncImportRawBuffer: Pointer;
    AsyncImportSecureBuffer: Pointer;
    QueryPrivateSensorType: Pointer;
    ConnectSecure: Pointer;
    StartCaptureEx: Pointer;
    StartNotifyWake: Pointer;
    FinishNotifyWake: Pointer;
  end;
const WINBIO_ADAPTER_INTERFACE_VERSION = extern struct {
    MajorVersion: u16,
    MinorVersion: u16,
};

const WINBIO_SENSOR_INTERFACE = extern struct {
    Version: WINBIO_ADAPTER_INTERFACE_VERSION,
    Type: u32,
    Size: usize,
    AdapterId: GUID,
    Attach: ?*anyopaque,
    Detach: ?*anyopaque,
    ClearContext: ?*anyopaque,
    QueryStatus: ?*anyopaque,
    Reset: ?*anyopaque,
    SetMode: ?*anyopaque,
    SetIndicatorStatus: ?*anyopaque,
    GetIndicatorStatus: ?*anyopaque,
    StartCapture: ?*anyopaque,
    FinishCapture: ?*anyopaque,
    ExportSensorData: ?*anyopaque,
    Cancel: ?*anyopaque,
    PushDataToEngine: ?*anyopaque,
    ControlUnit: ?*anyopaque,
    ControlUnitPrivileged: ?*anyopaque,
    NotifyPowerChange: ?*anyopaque,
    PipelineInit: ?*anyopaque,
    PipelineCleanup: ?*anyopaque,
    Activate: ?*anyopaque,
    Deactivate: ?*anyopaque,
    QueryExtendedInfo: ?*anyopaque,
    QueryCalibrationFormats: ?*anyopaque,
    SetCalibrationFormat: ?*anyopaque,
    AcceptCalibrationData: ?*anyopaque,
    AsyncImportRawBuffer: ?*anyopaque,
    AsyncImportSecureBuffer: ?*anyopaque,
    QueryPrivateSensorType: ?*anyopaque,
    ConnectSecure: ?*anyopaque,
    StartCaptureEx: ?*anyopaque,
    StartNotifyWake: ?*anyopaque,
    FinishNotifyWake: ?*anyopaque,
};
type
  WINBIO_ADAPTER_INTERFACE_VERSION {.bycopy.} = object
    MajorVersion: uint16
    MinorVersion: uint16

  WINBIO_SENSOR_INTERFACE {.bycopy.} = object
    Version: WINBIO_ADAPTER_INTERFACE_VERSION
    Type: uint32
    Size: uint
    AdapterId: GUID
    Attach: pointer
    Detach: pointer
    ClearContext: pointer
    QueryStatus: pointer
    Reset: pointer
    SetMode: pointer
    SetIndicatorStatus: pointer
    GetIndicatorStatus: pointer
    StartCapture: pointer
    FinishCapture: pointer
    ExportSensorData: pointer
    Cancel: pointer
    PushDataToEngine: pointer
    ControlUnit: pointer
    ControlUnitPrivileged: pointer
    NotifyPowerChange: pointer
    PipelineInit: pointer
    PipelineCleanup: pointer
    Activate: pointer
    Deactivate: pointer
    QueryExtendedInfo: pointer
    QueryCalibrationFormats: pointer
    SetCalibrationFormat: pointer
    AcceptCalibrationData: pointer
    AsyncImportRawBuffer: pointer
    AsyncImportSecureBuffer: pointer
    QueryPrivateSensorType: pointer
    ConnectSecure: pointer
    StartCaptureEx: pointer
    StartNotifyWake: pointer
    FinishNotifyWake: pointer
struct WINBIO_ADAPTER_INTERFACE_VERSION
{
    ushort MajorVersion;
    ushort MinorVersion;
}

struct WINBIO_SENSOR_INTERFACE
{
    WINBIO_ADAPTER_INTERFACE_VERSION Version;
    uint Type;
    size_t Size;
    GUID AdapterId;
    void* Attach;
    void* Detach;
    void* ClearContext;
    void* QueryStatus;
    void* Reset;
    void* SetMode;
    void* SetIndicatorStatus;
    void* GetIndicatorStatus;
    void* StartCapture;
    void* FinishCapture;
    void* ExportSensorData;
    void* Cancel;
    void* PushDataToEngine;
    void* ControlUnit;
    void* ControlUnitPrivileged;
    void* NotifyPowerChange;
    void* PipelineInit;
    void* PipelineCleanup;
    void* Activate;
    void* Deactivate;
    void* QueryExtendedInfo;
    void* QueryCalibrationFormats;
    void* SetCalibrationFormat;
    void* AcceptCalibrationData;
    void* AsyncImportRawBuffer;
    void* AsyncImportSecureBuffer;
    void* QueryPrivateSensorType;
    void* ConnectSecure;
    void* StartCaptureEx;
    void* StartNotifyWake;
    void* FinishNotifyWake;
}

HSP用 定義

HSP3.7/3.8 は構造体機能が無いため4byte整数配列(dim)+peek/poke で操作(32/64bitでサイズ・位置が異なる場合はタブで分割)。IronHSP は NSTRUCT(#defstruct/stdim/->)で32/64bit共通。

; HSP3.7/3.8 は構造体機能が無いため、4byte整数の配列変数で操作します。(x86 レイアウト)
; WINBIO_SENSOR_INTERFACE サイズ: 152 バイト(x86)
dim st, 38    ; 4byte整数×38(構造体サイズ 152 / 4 切り上げ)
; Version : WINBIO_ADAPTER_INTERFACE_VERSION (+0, 4byte)  varptr(st)+0 を基点に操作(4byte:入れ子/配列)
; Type : DWORD (+4, 4byte)  st.1 = 値  /  値 = st.1   (lpoke/lpeek も可)
; Size : UINT_PTR (+8, 4byte)  st.2 = 値  /  値 = st.2   (lpoke/lpeek も可)
; AdapterId : GUID (+12, 16byte)  varptr(st)+12 を基点に操作(16byte:入れ子/配列)
; Attach : PIBIO_SENSOR_ATTACH_FN (+28, 4byte)  st.7 = 値  /  値 = st.7   (lpoke/lpeek も可)
; Detach : PIBIO_SENSOR_DETACH_FN (+32, 4byte)  st.8 = 値  /  値 = st.8   (lpoke/lpeek も可)
; ClearContext : PIBIO_SENSOR_CLEAR_CONTEXT_FN (+36, 4byte)  st.9 = 値  /  値 = st.9   (lpoke/lpeek も可)
; QueryStatus : PIBIO_SENSOR_QUERY_STATUS_FN (+40, 4byte)  st.10 = 値  /  値 = st.10   (lpoke/lpeek も可)
; Reset : PIBIO_SENSOR_RESET_FN (+44, 4byte)  st.11 = 値  /  値 = st.11   (lpoke/lpeek も可)
; SetMode : PIBIO_SENSOR_SET_MODE_FN (+48, 4byte)  st.12 = 値  /  値 = st.12   (lpoke/lpeek も可)
; SetIndicatorStatus : PIBIO_SENSOR_SET_INDICATOR_STATUS_FN (+52, 4byte)  st.13 = 値  /  値 = st.13   (lpoke/lpeek も可)
; GetIndicatorStatus : PIBIO_SENSOR_GET_INDICATOR_STATUS_FN (+56, 4byte)  st.14 = 値  /  値 = st.14   (lpoke/lpeek も可)
; StartCapture : PIBIO_SENSOR_START_CAPTURE_FN (+60, 4byte)  st.15 = 値  /  値 = st.15   (lpoke/lpeek も可)
; FinishCapture : PIBIO_SENSOR_FINISH_CAPTURE_FN (+64, 4byte)  st.16 = 値  /  値 = st.16   (lpoke/lpeek も可)
; ExportSensorData : PIBIO_SENSOR_EXPORT_SENSOR_DATA_FN (+68, 4byte)  st.17 = 値  /  値 = st.17   (lpoke/lpeek も可)
; Cancel : PIBIO_SENSOR_CANCEL_FN (+72, 4byte)  st.18 = 値  /  値 = st.18   (lpoke/lpeek も可)
; PushDataToEngine : PIBIO_SENSOR_PUSH_DATA_TO_ENGINE_FN (+76, 4byte)  st.19 = 値  /  値 = st.19   (lpoke/lpeek も可)
; ControlUnit : PIBIO_SENSOR_CONTROL_UNIT_FN (+80, 4byte)  st.20 = 値  /  値 = st.20   (lpoke/lpeek も可)
; ControlUnitPrivileged : PIBIO_SENSOR_CONTROL_UNIT_PRIVILEGED_FN (+84, 4byte)  st.21 = 値  /  値 = st.21   (lpoke/lpeek も可)
; NotifyPowerChange : PIBIO_SENSOR_NOTIFY_POWER_CHANGE_FN (+88, 4byte)  st.22 = 値  /  値 = st.22   (lpoke/lpeek も可)
; PipelineInit : PIBIO_SENSOR_PIPELINE_INIT_FN (+92, 4byte)  st.23 = 値  /  値 = st.23   (lpoke/lpeek も可)
; PipelineCleanup : PIBIO_SENSOR_PIPELINE_CLEANUP_FN (+96, 4byte)  st.24 = 値  /  値 = st.24   (lpoke/lpeek も可)
; Activate : PIBIO_SENSOR_ACTIVATE_FN (+100, 4byte)  st.25 = 値  /  値 = st.25   (lpoke/lpeek も可)
; Deactivate : PIBIO_SENSOR_DEACTIVATE_FN (+104, 4byte)  st.26 = 値  /  値 = st.26   (lpoke/lpeek も可)
; QueryExtendedInfo : PIBIO_SENSOR_QUERY_EXTENDED_INFO_FN (+108, 4byte)  st.27 = 値  /  値 = st.27   (lpoke/lpeek も可)
; QueryCalibrationFormats : PIBIO_SENSOR_QUERY_CALIBRATION_FORMATS_FN (+112, 4byte)  st.28 = 値  /  値 = st.28   (lpoke/lpeek も可)
; SetCalibrationFormat : PIBIO_SENSOR_SET_CALIBRATION_FORMAT_FN (+116, 4byte)  st.29 = 値  /  値 = st.29   (lpoke/lpeek も可)
; AcceptCalibrationData : PIBIO_SENSOR_ACCEPT_CALIBRATION_DATA_FN (+120, 4byte)  st.30 = 値  /  値 = st.30   (lpoke/lpeek も可)
; AsyncImportRawBuffer : PIBIO_SENSOR_ASYNC_IMPORT_RAW_BUFFER_FN (+124, 4byte)  st.31 = 値  /  値 = st.31   (lpoke/lpeek も可)
; AsyncImportSecureBuffer : PIBIO_SENSOR_ASYNC_IMPORT_SECURE_BUFFER_FN (+128, 4byte)  st.32 = 値  /  値 = st.32   (lpoke/lpeek も可)
; QueryPrivateSensorType : PIBIO_SENSOR_QUERY_PRIVATE_SENSOR_TYPE_FN (+132, 4byte)  st.33 = 値  /  値 = st.33   (lpoke/lpeek も可)
; ConnectSecure : PIBIO_SENSOR_CONNECT_SECURE_FN (+136, 4byte)  st.34 = 値  /  値 = st.34   (lpoke/lpeek も可)
; StartCaptureEx : PIBIO_SENSOR_START_CAPTURE_EX_FN (+140, 4byte)  st.35 = 値  /  値 = st.35   (lpoke/lpeek も可)
; StartNotifyWake : PIBIO_SENSOR_START_NOTIFY_WAKE_FN (+144, 4byte)  st.36 = 値  /  値 = st.36   (lpoke/lpeek も可)
; FinishNotifyWake : PIBIO_SENSOR_FINISH_NOTIFY_WAKE_FN (+148, 4byte)  st.37 = 値  /  値 = st.37   (lpoke/lpeek も可)
; ※4byte境界の整数は添字 st.N(N=オフセット/4)で読み書き可。それ以外は peek/poke 系を使用。
; HSP3.7/3.8 は構造体機能が無いため、4byte整数の配列変数で操作します。(x64 レイアウト)
; WINBIO_SENSOR_INTERFACE サイズ: 280 バイト(x64)
dim st, 70    ; 4byte整数×70(構造体サイズ 280 / 4 切り上げ)
; Version : WINBIO_ADAPTER_INTERFACE_VERSION (+0, 4byte)  varptr(st)+0 を基点に操作(4byte:入れ子/配列)
; Type : DWORD (+4, 4byte)  st.1 = 値  /  値 = st.1   (lpoke/lpeek も可)
; Size : UINT_PTR (+8, 8byte)  qpoke st,8,値 / qpeek(st,8)  ※IronHSPのみ。3.7/3.8は lpoke st,8,下位 : lpoke st,12,上位
; AdapterId : GUID (+16, 16byte)  varptr(st)+16 を基点に操作(16byte:入れ子/配列)
; Attach : PIBIO_SENSOR_ATTACH_FN (+32, 8byte)  qpoke st,32,値 / qpeek(st,32)  ※IronHSPのみ。3.7/3.8は lpoke st,32,下位 : lpoke st,36,上位
; Detach : PIBIO_SENSOR_DETACH_FN (+40, 8byte)  qpoke st,40,値 / qpeek(st,40)  ※IronHSPのみ。3.7/3.8は lpoke st,40,下位 : lpoke st,44,上位
; ClearContext : PIBIO_SENSOR_CLEAR_CONTEXT_FN (+48, 8byte)  qpoke st,48,値 / qpeek(st,48)  ※IronHSPのみ。3.7/3.8は lpoke st,48,下位 : lpoke st,52,上位
; QueryStatus : PIBIO_SENSOR_QUERY_STATUS_FN (+56, 8byte)  qpoke st,56,値 / qpeek(st,56)  ※IronHSPのみ。3.7/3.8は lpoke st,56,下位 : lpoke st,60,上位
; Reset : PIBIO_SENSOR_RESET_FN (+64, 8byte)  qpoke st,64,値 / qpeek(st,64)  ※IronHSPのみ。3.7/3.8は lpoke st,64,下位 : lpoke st,68,上位
; SetMode : PIBIO_SENSOR_SET_MODE_FN (+72, 8byte)  qpoke st,72,値 / qpeek(st,72)  ※IronHSPのみ。3.7/3.8は lpoke st,72,下位 : lpoke st,76,上位
; SetIndicatorStatus : PIBIO_SENSOR_SET_INDICATOR_STATUS_FN (+80, 8byte)  qpoke st,80,値 / qpeek(st,80)  ※IronHSPのみ。3.7/3.8は lpoke st,80,下位 : lpoke st,84,上位
; GetIndicatorStatus : PIBIO_SENSOR_GET_INDICATOR_STATUS_FN (+88, 8byte)  qpoke st,88,値 / qpeek(st,88)  ※IronHSPのみ。3.7/3.8は lpoke st,88,下位 : lpoke st,92,上位
; StartCapture : PIBIO_SENSOR_START_CAPTURE_FN (+96, 8byte)  qpoke st,96,値 / qpeek(st,96)  ※IronHSPのみ。3.7/3.8は lpoke st,96,下位 : lpoke st,100,上位
; FinishCapture : PIBIO_SENSOR_FINISH_CAPTURE_FN (+104, 8byte)  qpoke st,104,値 / qpeek(st,104)  ※IronHSPのみ。3.7/3.8は lpoke st,104,下位 : lpoke st,108,上位
; ExportSensorData : PIBIO_SENSOR_EXPORT_SENSOR_DATA_FN (+112, 8byte)  qpoke st,112,値 / qpeek(st,112)  ※IronHSPのみ。3.7/3.8は lpoke st,112,下位 : lpoke st,116,上位
; Cancel : PIBIO_SENSOR_CANCEL_FN (+120, 8byte)  qpoke st,120,値 / qpeek(st,120)  ※IronHSPのみ。3.7/3.8は lpoke st,120,下位 : lpoke st,124,上位
; PushDataToEngine : PIBIO_SENSOR_PUSH_DATA_TO_ENGINE_FN (+128, 8byte)  qpoke st,128,値 / qpeek(st,128)  ※IronHSPのみ。3.7/3.8は lpoke st,128,下位 : lpoke st,132,上位
; ControlUnit : PIBIO_SENSOR_CONTROL_UNIT_FN (+136, 8byte)  qpoke st,136,値 / qpeek(st,136)  ※IronHSPのみ。3.7/3.8は lpoke st,136,下位 : lpoke st,140,上位
; ControlUnitPrivileged : PIBIO_SENSOR_CONTROL_UNIT_PRIVILEGED_FN (+144, 8byte)  qpoke st,144,値 / qpeek(st,144)  ※IronHSPのみ。3.7/3.8は lpoke st,144,下位 : lpoke st,148,上位
; NotifyPowerChange : PIBIO_SENSOR_NOTIFY_POWER_CHANGE_FN (+152, 8byte)  qpoke st,152,値 / qpeek(st,152)  ※IronHSPのみ。3.7/3.8は lpoke st,152,下位 : lpoke st,156,上位
; PipelineInit : PIBIO_SENSOR_PIPELINE_INIT_FN (+160, 8byte)  qpoke st,160,値 / qpeek(st,160)  ※IronHSPのみ。3.7/3.8は lpoke st,160,下位 : lpoke st,164,上位
; PipelineCleanup : PIBIO_SENSOR_PIPELINE_CLEANUP_FN (+168, 8byte)  qpoke st,168,値 / qpeek(st,168)  ※IronHSPのみ。3.7/3.8は lpoke st,168,下位 : lpoke st,172,上位
; Activate : PIBIO_SENSOR_ACTIVATE_FN (+176, 8byte)  qpoke st,176,値 / qpeek(st,176)  ※IronHSPのみ。3.7/3.8は lpoke st,176,下位 : lpoke st,180,上位
; Deactivate : PIBIO_SENSOR_DEACTIVATE_FN (+184, 8byte)  qpoke st,184,値 / qpeek(st,184)  ※IronHSPのみ。3.7/3.8は lpoke st,184,下位 : lpoke st,188,上位
; QueryExtendedInfo : PIBIO_SENSOR_QUERY_EXTENDED_INFO_FN (+192, 8byte)  qpoke st,192,値 / qpeek(st,192)  ※IronHSPのみ。3.7/3.8は lpoke st,192,下位 : lpoke st,196,上位
; QueryCalibrationFormats : PIBIO_SENSOR_QUERY_CALIBRATION_FORMATS_FN (+200, 8byte)  qpoke st,200,値 / qpeek(st,200)  ※IronHSPのみ。3.7/3.8は lpoke st,200,下位 : lpoke st,204,上位
; SetCalibrationFormat : PIBIO_SENSOR_SET_CALIBRATION_FORMAT_FN (+208, 8byte)  qpoke st,208,値 / qpeek(st,208)  ※IronHSPのみ。3.7/3.8は lpoke st,208,下位 : lpoke st,212,上位
; AcceptCalibrationData : PIBIO_SENSOR_ACCEPT_CALIBRATION_DATA_FN (+216, 8byte)  qpoke st,216,値 / qpeek(st,216)  ※IronHSPのみ。3.7/3.8は lpoke st,216,下位 : lpoke st,220,上位
; AsyncImportRawBuffer : PIBIO_SENSOR_ASYNC_IMPORT_RAW_BUFFER_FN (+224, 8byte)  qpoke st,224,値 / qpeek(st,224)  ※IronHSPのみ。3.7/3.8は lpoke st,224,下位 : lpoke st,228,上位
; AsyncImportSecureBuffer : PIBIO_SENSOR_ASYNC_IMPORT_SECURE_BUFFER_FN (+232, 8byte)  qpoke st,232,値 / qpeek(st,232)  ※IronHSPのみ。3.7/3.8は lpoke st,232,下位 : lpoke st,236,上位
; QueryPrivateSensorType : PIBIO_SENSOR_QUERY_PRIVATE_SENSOR_TYPE_FN (+240, 8byte)  qpoke st,240,値 / qpeek(st,240)  ※IronHSPのみ。3.7/3.8は lpoke st,240,下位 : lpoke st,244,上位
; ConnectSecure : PIBIO_SENSOR_CONNECT_SECURE_FN (+248, 8byte)  qpoke st,248,値 / qpeek(st,248)  ※IronHSPのみ。3.7/3.8は lpoke st,248,下位 : lpoke st,252,上位
; StartCaptureEx : PIBIO_SENSOR_START_CAPTURE_EX_FN (+256, 8byte)  qpoke st,256,値 / qpeek(st,256)  ※IronHSPのみ。3.7/3.8は lpoke st,256,下位 : lpoke st,260,上位
; StartNotifyWake : PIBIO_SENSOR_START_NOTIFY_WAKE_FN (+264, 8byte)  qpoke st,264,値 / qpeek(st,264)  ※IronHSPのみ。3.7/3.8は lpoke st,264,下位 : lpoke st,268,上位
; FinishNotifyWake : PIBIO_SENSOR_FINISH_NOTIFY_WAKE_FN (+272, 8byte)  qpoke st,272,値 / qpeek(st,272)  ※IronHSPのみ。3.7/3.8は lpoke st,272,下位 : lpoke st,276,上位
; ※4byte境界の整数は添字 st.N(N=オフセット/4)で読み書き可。それ以外は peek/poke 系を使用。
; IronHSP は NSTRUCT(構造体)をサポート。32bit/64bit どちらでも同じコードで動作します。
; ※GUID・入れ子構造体はデフォルト型でないため、依存する #defstruct を先に定義(下記に同梱)。
#defstruct global WINBIO_ADAPTER_INTERFACE_VERSION
    #field short MajorVersion
    #field short MinorVersion
#endstruct

#defstruct global GUID, pack=1
    #field int Data1
    #field short Data2
    #field short Data3
    #field byte Data4 8
#endstruct

#defstruct global WINBIO_SENSOR_INTERFACE
    #field WINBIO_ADAPTER_INTERFACE_VERSION Version
    #field int Type
    #field intptr Size
    #field GUID AdapterId
    #field intptr Attach
    #field intptr Detach
    #field intptr ClearContext
    #field intptr QueryStatus
    #field intptr Reset
    #field intptr SetMode
    #field intptr SetIndicatorStatus
    #field intptr GetIndicatorStatus
    #field intptr StartCapture
    #field intptr FinishCapture
    #field intptr ExportSensorData
    #field intptr Cancel
    #field intptr PushDataToEngine
    #field intptr ControlUnit
    #field intptr ControlUnitPrivileged
    #field intptr NotifyPowerChange
    #field intptr PipelineInit
    #field intptr PipelineCleanup
    #field intptr Activate
    #field intptr Deactivate
    #field intptr QueryExtendedInfo
    #field intptr QueryCalibrationFormats
    #field intptr SetCalibrationFormat
    #field intptr AcceptCalibrationData
    #field intptr AsyncImportRawBuffer
    #field intptr AsyncImportSecureBuffer
    #field intptr QueryPrivateSensorType
    #field intptr ConnectSecure
    #field intptr StartCaptureEx
    #field intptr StartNotifyWake
    #field intptr FinishNotifyWake
#endstruct

stdim st, WINBIO_SENSOR_INTERFACE        ; NSTRUCT 変数を確保
st->Type = 100
mes "Type=" + st->Type