ホーム › Devices.BiometricFramework › WINBIO_BDB_ANSI_381_RECORD
WINBIO_BDB_ANSI_381_RECORD
構造体サイズ=各フィールドのバイト数(x64/x86 で異なる場合は x64/x86 と併記)。x64/x86 列=フィールドのバイトオフセット(HSPで dupptr / lpoke / wpoke 等に使用)。
フィールド
| フィールド | 型 | サイズ | x64 | x86 | 説明 |
|---|---|---|---|---|---|
| BlockLength | DWORD | 4 | +0 | +0 | このレコードブロックのバイト数。 |
| HorizontalLineLength | WORD | 2 | +4 | +4 | 画像の水平方向の画素数(幅)。 |
| VerticalLineLength | WORD | 2 | +6 | +6 | 画像の垂直方向の画素数(高さ)。 |
| Position | BYTE | 1 | +8 | +8 | 指紋採取位置(どの指か)を示すバイト値。 |
| CountOfViews | BYTE | 1 | +9 | +9 | このレコードに含まれるビュー数。 |
| ViewNumber | BYTE | 1 | +10 | +10 | ビューの番号。 |
| ImageQuality | BYTE | 1 | +11 | +11 | 画像の品質スコア(バイト)。 |
| ImpressionType | BYTE | 1 | +12 | +12 | 押捺の種別(ライブスキャン等)を示すバイト値。 |
| Reserved | BYTE | 1 | +13 | +13 | 予約フィールド。 |
各言語での定義
#include <windows.h>
// WINBIO_BDB_ANSI_381_RECORD (x64 16 / x86 16 バイト)
typedef struct WINBIO_BDB_ANSI_381_RECORD {
DWORD BlockLength;
WORD HorizontalLineLength;
WORD VerticalLineLength;
BYTE Position;
BYTE CountOfViews;
BYTE ViewNumber;
BYTE ImageQuality;
BYTE ImpressionType;
BYTE Reserved;
} WINBIO_BDB_ANSI_381_RECORD;using System;
using System.Runtime.InteropServices;
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct WINBIO_BDB_ANSI_381_RECORD
{
public uint BlockLength;
public ushort HorizontalLineLength;
public ushort VerticalLineLength;
public byte Position;
public byte CountOfViews;
public byte ViewNumber;
public byte ImageQuality;
public byte ImpressionType;
public byte Reserved;
}Imports System.Runtime.InteropServices
<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure WINBIO_BDB_ANSI_381_RECORD
Public BlockLength As UInteger
Public HorizontalLineLength As UShort
Public VerticalLineLength As UShort
Public Position As Byte
Public CountOfViews As Byte
Public ViewNumber As Byte
Public ImageQuality As Byte
Public ImpressionType As Byte
Public Reserved As Byte
End Structureimport ctypes
from ctypes import wintypes
class WINBIO_BDB_ANSI_381_RECORD(ctypes.Structure):
_fields_ = [
("BlockLength", wintypes.DWORD),
("HorizontalLineLength", ctypes.c_ushort),
("VerticalLineLength", ctypes.c_ushort),
("Position", ctypes.c_ubyte),
("CountOfViews", ctypes.c_ubyte),
("ViewNumber", ctypes.c_ubyte),
("ImageQuality", ctypes.c_ubyte),
("ImpressionType", ctypes.c_ubyte),
("Reserved", ctypes.c_ubyte),
]#[repr(C)]
pub struct WINBIO_BDB_ANSI_381_RECORD {
pub BlockLength: u32,
pub HorizontalLineLength: u16,
pub VerticalLineLength: u16,
pub Position: u8,
pub CountOfViews: u8,
pub ViewNumber: u8,
pub ImageQuality: u8,
pub ImpressionType: u8,
pub Reserved: u8,
}import "golang.org/x/sys/windows"
type WINBIO_BDB_ANSI_381_RECORD struct {
BlockLength uint32
HorizontalLineLength uint16
VerticalLineLength uint16
Position byte
CountOfViews byte
ViewNumber byte
ImageQuality byte
ImpressionType byte
Reserved byte
}type
WINBIO_BDB_ANSI_381_RECORD = record
BlockLength: DWORD;
HorizontalLineLength: Word;
VerticalLineLength: Word;
Position: Byte;
CountOfViews: Byte;
ViewNumber: Byte;
ImageQuality: Byte;
ImpressionType: Byte;
Reserved: Byte;
end;const WINBIO_BDB_ANSI_381_RECORD = extern struct {
BlockLength: u32,
HorizontalLineLength: u16,
VerticalLineLength: u16,
Position: u8,
CountOfViews: u8,
ViewNumber: u8,
ImageQuality: u8,
ImpressionType: u8,
Reserved: u8,
};type
WINBIO_BDB_ANSI_381_RECORD {.bycopy.} = object
BlockLength: uint32
HorizontalLineLength: uint16
VerticalLineLength: uint16
Position: uint8
CountOfViews: uint8
ViewNumber: uint8
ImageQuality: uint8
ImpressionType: uint8
Reserved: uint8struct WINBIO_BDB_ANSI_381_RECORD
{
uint BlockLength;
ushort HorizontalLineLength;
ushort VerticalLineLength;
ubyte Position;
ubyte CountOfViews;
ubyte ViewNumber;
ubyte ImageQuality;
ubyte ImpressionType;
ubyte Reserved;
}HSP用 定義
HSP3.7/3.8 は構造体機能が無いため4byte整数配列(dim)+peek/poke で操作(32/64bitでサイズ・位置が異なる場合はタブで分割)。IronHSP は NSTRUCT(#defstruct/stdim/->)で32/64bit共通。
; HSP3.7/3.8 は構造体機能が無いため、4byte整数の配列変数で操作します。(x64 レイアウト)
; WINBIO_BDB_ANSI_381_RECORD サイズ: 16 バイト(x64)
dim st, 4 ; 4byte整数×4(構造体サイズ 16 / 4 切り上げ)
; BlockLength : DWORD (+0, 4byte) st.0 = 値 / 値 = st.0 (lpoke/lpeek も可)
; HorizontalLineLength : WORD (+4, 2byte) wpoke st,4,値 / 値 = wpeek(st,4)
; VerticalLineLength : WORD (+6, 2byte) wpoke st,6,値 / 値 = wpeek(st,6)
; Position : BYTE (+8, 1byte) poke st,8,値 / 値 = peek(st,8)
; CountOfViews : BYTE (+9, 1byte) poke st,9,値 / 値 = peek(st,9)
; ViewNumber : BYTE (+10, 1byte) poke st,10,値 / 値 = peek(st,10)
; ImageQuality : BYTE (+11, 1byte) poke st,11,値 / 値 = peek(st,11)
; ImpressionType : BYTE (+12, 1byte) poke st,12,値 / 値 = peek(st,12)
; Reserved : BYTE (+13, 1byte) poke st,13,値 / 値 = peek(st,13)
; ※4byte境界の整数は添字 st.N(N=オフセット/4)で読み書き可。それ以外は peek/poke 系を使用。; IronHSP は NSTRUCT(構造体)をサポート。32bit/64bit どちらでも同じコードで動作します。
#defstruct global WINBIO_BDB_ANSI_381_RECORD
#field int BlockLength
#field short HorizontalLineLength
#field short VerticalLineLength
#field byte Position
#field byte CountOfViews
#field byte ViewNumber
#field byte ImageQuality
#field byte ImpressionType
#field byte Reserved
#endstruct
stdim st, WINBIO_BDB_ANSI_381_RECORD ; NSTRUCT 変数を確保
st->BlockLength = 100
mes "BlockLength=" + st->BlockLength