Win32 API 日本語リファレンス
ホームMedia.DirectShow.Tv › MPEG2_FILTER

MPEG2_FILTER

構造体
サイズx64: 124 バイト / x86: 124 バイトパッキング1

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

フィールド

フィールドサイズx64x86説明
bVersionNumberBYTE1+0+0フィルタ構造体のバージョン番号。
wFilterSizeWORD2+1+1フィルタ・マスクの有効バイト数。
fUseRawFilteringBitsBOOL4+3+3生のフィルタリングビットを使うか否か(BOOL)。
FilterBYTE16+7+7比較に用いるフィルタパターン配列。
MaskBYTE16+23+23比較対象ビットを選ぶマスク配列。
fSpecifyTableIdExtensionBOOL4+39+39テーブルID拡張でフィルタするか否か(BOOL)。
TableIdExtensionWORD2+43+43フィルタ対象のテーブルID拡張値。
fSpecifyVersionBOOL4+45+45バージョンでフィルタするか否か(BOOL)。
VersionBYTE1+49+49フィルタ対象のバージョン番号。
fSpecifySectionNumberBOOL4+50+50セクション番号でフィルタするか否か(BOOL)。
SectionNumberBYTE1+54+54フィルタ対象のセクション番号。
fSpecifyCurrentNextBOOL4+55+55カレント/ネクスト指定でフィルタするか否か(BOOL)。
fNextBOOL4+59+59次バージョン(TRUE)か現行(FALSE)かを示す。
fSpecifyDsmccOptionsBOOL4+63+63DSM-CCオプションでフィルタするか否か(BOOL)。
DsmccDSMCC_FILTER_OPTIONS45+67+67DSM-CCフィルタオプション(DSMCC_FILTER_OPTIONS)。
fSpecifyAtscOptionsBOOL4+112+112ATSCオプションでフィルタするか否か(BOOL)。
AtscATSC_FILTER_OPTIONS8+116+116ATSCフィルタオプション(ATSC_FILTER_OPTIONS)。

各言語での定義

#include <windows.h>

// DSMCC_FILTER_OPTIONS  (x64 45 / x86 45 バイト)
#pragma pack(push, 1)
typedef struct DSMCC_FILTER_OPTIONS {
    BOOL fSpecifyProtocol;
    BYTE Protocol;
    BOOL fSpecifyType;
    BYTE Type;
    BOOL fSpecifyMessageId;
    WORD MessageId;
    BOOL fSpecifyTransactionId;
    BOOL fUseTrxIdMessageIdMask;
    DWORD TransactionId;
    BOOL fSpecifyModuleVersion;
    BYTE ModuleVersion;
    BOOL fSpecifyBlockNumber;
    WORD BlockNumber;
    BOOL fGetModuleCall;
    WORD NumberOfBlocksInModule;
} DSMCC_FILTER_OPTIONS;
#pragma pack(pop)

// ATSC_FILTER_OPTIONS  (x64 8 / x86 8 バイト)
#pragma pack(push, 1)
typedef struct ATSC_FILTER_OPTIONS {
    BOOL fSpecifyEtmId;
    DWORD EtmId;
} ATSC_FILTER_OPTIONS;
#pragma pack(pop)

// MPEG2_FILTER  (x64 124 / x86 124 バイト)
#pragma pack(push, 1)
typedef struct MPEG2_FILTER {
    BYTE bVersionNumber;
    WORD wFilterSize;
    BOOL fUseRawFilteringBits;
    BYTE Filter[16];
    BYTE Mask[16];
    BOOL fSpecifyTableIdExtension;
    WORD TableIdExtension;
    BOOL fSpecifyVersion;
    BYTE Version;
    BOOL fSpecifySectionNumber;
    BYTE SectionNumber;
    BOOL fSpecifyCurrentNext;
    BOOL fNext;
    BOOL fSpecifyDsmccOptions;
    DSMCC_FILTER_OPTIONS Dsmcc;
    BOOL fSpecifyAtscOptions;
    ATSC_FILTER_OPTIONS Atsc;
} MPEG2_FILTER;
#pragma pack(pop)
using System;
using System.Runtime.InteropServices;

[StructLayout(LayoutKind.Sequential, Pack = 1, CharSet = CharSet.Unicode)]
public struct DSMCC_FILTER_OPTIONS
{
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyProtocol;
    public byte Protocol;
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyType;
    public byte Type;
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyMessageId;
    public ushort MessageId;
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyTransactionId;
    [MarshalAs(UnmanagedType.Bool)] public bool fUseTrxIdMessageIdMask;
    public uint TransactionId;
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyModuleVersion;
    public byte ModuleVersion;
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyBlockNumber;
    public ushort BlockNumber;
    [MarshalAs(UnmanagedType.Bool)] public bool fGetModuleCall;
    public ushort NumberOfBlocksInModule;
}

[StructLayout(LayoutKind.Sequential, Pack = 1, CharSet = CharSet.Unicode)]
public struct ATSC_FILTER_OPTIONS
{
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyEtmId;
    public uint EtmId;
}

[StructLayout(LayoutKind.Sequential, Pack = 1, CharSet = CharSet.Unicode)]
public struct MPEG2_FILTER
{
    public byte bVersionNumber;
    public ushort wFilterSize;
    [MarshalAs(UnmanagedType.Bool)] public bool fUseRawFilteringBits;
    [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)] public byte[] Filter;
    [MarshalAs(UnmanagedType.ByValArray, SizeConst = 16)] public byte[] Mask;
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyTableIdExtension;
    public ushort TableIdExtension;
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyVersion;
    public byte Version;
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifySectionNumber;
    public byte SectionNumber;
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyCurrentNext;
    [MarshalAs(UnmanagedType.Bool)] public bool fNext;
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyDsmccOptions;
    public DSMCC_FILTER_OPTIONS Dsmcc;
    [MarshalAs(UnmanagedType.Bool)] public bool fSpecifyAtscOptions;
    public ATSC_FILTER_OPTIONS Atsc;
}
Imports System.Runtime.InteropServices

<StructLayout(LayoutKind.Sequential, Pack:=1, CharSet:=CharSet.Unicode)>
Public Structure DSMCC_FILTER_OPTIONS
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyProtocol As Boolean
    Public Protocol As Byte
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyType As Boolean
    Public Type As Byte
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyMessageId As Boolean
    Public MessageId As UShort
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyTransactionId As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public fUseTrxIdMessageIdMask As Boolean
    Public TransactionId As UInteger
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyModuleVersion As Boolean
    Public ModuleVersion As Byte
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyBlockNumber As Boolean
    Public BlockNumber As UShort
    <MarshalAs(UnmanagedType.Bool)> Public fGetModuleCall As Boolean
    Public NumberOfBlocksInModule As UShort
End Structure

<StructLayout(LayoutKind.Sequential, Pack:=1, CharSet:=CharSet.Unicode)>
Public Structure ATSC_FILTER_OPTIONS
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyEtmId As Boolean
    Public EtmId As UInteger
End Structure

<StructLayout(LayoutKind.Sequential, Pack:=1, CharSet:=CharSet.Unicode)>
Public Structure MPEG2_FILTER
    Public bVersionNumber As Byte
    Public wFilterSize As UShort
    <MarshalAs(UnmanagedType.Bool)> Public fUseRawFilteringBits As Boolean
    <MarshalAs(UnmanagedType.ByValArray, SizeConst:=16)> Public Filter() As Byte
    <MarshalAs(UnmanagedType.ByValArray, SizeConst:=16)> Public Mask() As Byte
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyTableIdExtension As Boolean
    Public TableIdExtension As UShort
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyVersion As Boolean
    Public Version As Byte
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifySectionNumber As Boolean
    Public SectionNumber As Byte
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyCurrentNext As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public fNext As Boolean
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyDsmccOptions As Boolean
    Public Dsmcc As DSMCC_FILTER_OPTIONS
    <MarshalAs(UnmanagedType.Bool)> Public fSpecifyAtscOptions As Boolean
    Public Atsc As ATSC_FILTER_OPTIONS
End Structure
import ctypes
from ctypes import wintypes

class DSMCC_FILTER_OPTIONS(ctypes.Structure):
    _pack_ = 1
    _fields_ = [
        ("fSpecifyProtocol", wintypes.BOOL),
        ("Protocol", ctypes.c_ubyte),
        ("fSpecifyType", wintypes.BOOL),
        ("Type", ctypes.c_ubyte),
        ("fSpecifyMessageId", wintypes.BOOL),
        ("MessageId", ctypes.c_ushort),
        ("fSpecifyTransactionId", wintypes.BOOL),
        ("fUseTrxIdMessageIdMask", wintypes.BOOL),
        ("TransactionId", wintypes.DWORD),
        ("fSpecifyModuleVersion", wintypes.BOOL),
        ("ModuleVersion", ctypes.c_ubyte),
        ("fSpecifyBlockNumber", wintypes.BOOL),
        ("BlockNumber", ctypes.c_ushort),
        ("fGetModuleCall", wintypes.BOOL),
        ("NumberOfBlocksInModule", ctypes.c_ushort),
    ]

class ATSC_FILTER_OPTIONS(ctypes.Structure):
    _pack_ = 1
    _fields_ = [
        ("fSpecifyEtmId", wintypes.BOOL),
        ("EtmId", wintypes.DWORD),
    ]

class MPEG2_FILTER(ctypes.Structure):
    _pack_ = 1
    _fields_ = [
        ("bVersionNumber", ctypes.c_ubyte),
        ("wFilterSize", ctypes.c_ushort),
        ("fUseRawFilteringBits", wintypes.BOOL),
        ("Filter", ctypes.c_ubyte * 16),
        ("Mask", ctypes.c_ubyte * 16),
        ("fSpecifyTableIdExtension", wintypes.BOOL),
        ("TableIdExtension", ctypes.c_ushort),
        ("fSpecifyVersion", wintypes.BOOL),
        ("Version", ctypes.c_ubyte),
        ("fSpecifySectionNumber", wintypes.BOOL),
        ("SectionNumber", ctypes.c_ubyte),
        ("fSpecifyCurrentNext", wintypes.BOOL),
        ("fNext", wintypes.BOOL),
        ("fSpecifyDsmccOptions", wintypes.BOOL),
        ("Dsmcc", DSMCC_FILTER_OPTIONS),
        ("fSpecifyAtscOptions", wintypes.BOOL),
        ("Atsc", ATSC_FILTER_OPTIONS),
    ]
#[repr(C, packed(1))]
pub struct DSMCC_FILTER_OPTIONS {
    pub fSpecifyProtocol: i32,
    pub Protocol: u8,
    pub fSpecifyType: i32,
    pub Type: u8,
    pub fSpecifyMessageId: i32,
    pub MessageId: u16,
    pub fSpecifyTransactionId: i32,
    pub fUseTrxIdMessageIdMask: i32,
    pub TransactionId: u32,
    pub fSpecifyModuleVersion: i32,
    pub ModuleVersion: u8,
    pub fSpecifyBlockNumber: i32,
    pub BlockNumber: u16,
    pub fGetModuleCall: i32,
    pub NumberOfBlocksInModule: u16,
}

#[repr(C, packed(1))]
pub struct ATSC_FILTER_OPTIONS {
    pub fSpecifyEtmId: i32,
    pub EtmId: u32,
}

#[repr(C, packed(1))]
pub struct MPEG2_FILTER {
    pub bVersionNumber: u8,
    pub wFilterSize: u16,
    pub fUseRawFilteringBits: i32,
    pub Filter: [u8; 16],
    pub Mask: [u8; 16],
    pub fSpecifyTableIdExtension: i32,
    pub TableIdExtension: u16,
    pub fSpecifyVersion: i32,
    pub Version: u8,
    pub fSpecifySectionNumber: i32,
    pub SectionNumber: u8,
    pub fSpecifyCurrentNext: i32,
    pub fNext: i32,
    pub fSpecifyDsmccOptions: i32,
    pub Dsmcc: DSMCC_FILTER_OPTIONS,
    pub fSpecifyAtscOptions: i32,
    pub Atsc: ATSC_FILTER_OPTIONS,
}
import "golang.org/x/sys/windows"

type DSMCC_FILTER_OPTIONS struct {
	fSpecifyProtocol int32
	Protocol byte
	fSpecifyType int32
	Type byte
	fSpecifyMessageId int32
	MessageId uint16
	fSpecifyTransactionId int32
	fUseTrxIdMessageIdMask int32
	TransactionId uint32
	fSpecifyModuleVersion int32
	ModuleVersion byte
	fSpecifyBlockNumber int32
	BlockNumber uint16
	fGetModuleCall int32
	NumberOfBlocksInModule uint16
}

type ATSC_FILTER_OPTIONS struct {
	fSpecifyEtmId int32
	EtmId uint32
}

type MPEG2_FILTER struct {
	bVersionNumber byte
	wFilterSize uint16
	fUseRawFilteringBits int32
	Filter [16]byte
	Mask [16]byte
	fSpecifyTableIdExtension int32
	TableIdExtension uint16
	fSpecifyVersion int32
	Version byte
	fSpecifySectionNumber int32
	SectionNumber byte
	fSpecifyCurrentNext int32
	fNext int32
	fSpecifyDsmccOptions int32
	Dsmcc DSMCC_FILTER_OPTIONS
	fSpecifyAtscOptions int32
	Atsc ATSC_FILTER_OPTIONS
}
type
  DSMCC_FILTER_OPTIONS = packed record
    fSpecifyProtocol: BOOL;
    Protocol: Byte;
    fSpecifyType: BOOL;
    Type: Byte;
    fSpecifyMessageId: BOOL;
    MessageId: Word;
    fSpecifyTransactionId: BOOL;
    fUseTrxIdMessageIdMask: BOOL;
    TransactionId: DWORD;
    fSpecifyModuleVersion: BOOL;
    ModuleVersion: Byte;
    fSpecifyBlockNumber: BOOL;
    BlockNumber: Word;
    fGetModuleCall: BOOL;
    NumberOfBlocksInModule: Word;
  end;

  ATSC_FILTER_OPTIONS = packed record
    fSpecifyEtmId: BOOL;
    EtmId: DWORD;
  end;

  MPEG2_FILTER = packed record
    bVersionNumber: Byte;
    wFilterSize: Word;
    fUseRawFilteringBits: BOOL;
    Filter: array[0..15] of Byte;
    Mask: array[0..15] of Byte;
    fSpecifyTableIdExtension: BOOL;
    TableIdExtension: Word;
    fSpecifyVersion: BOOL;
    Version: Byte;
    fSpecifySectionNumber: BOOL;
    SectionNumber: Byte;
    fSpecifyCurrentNext: BOOL;
    fNext: BOOL;
    fSpecifyDsmccOptions: BOOL;
    Dsmcc: DSMCC_FILTER_OPTIONS;
    fSpecifyAtscOptions: BOOL;
    Atsc: ATSC_FILTER_OPTIONS;
  end;
const DSMCC_FILTER_OPTIONS = extern struct {
    fSpecifyProtocol: i32,
    Protocol: u8,
    fSpecifyType: i32,
    Type: u8,
    fSpecifyMessageId: i32,
    MessageId: u16,
    fSpecifyTransactionId: i32,
    fUseTrxIdMessageIdMask: i32,
    TransactionId: u32,
    fSpecifyModuleVersion: i32,
    ModuleVersion: u8,
    fSpecifyBlockNumber: i32,
    BlockNumber: u16,
    fGetModuleCall: i32,
    NumberOfBlocksInModule: u16,
};

const ATSC_FILTER_OPTIONS = extern struct {
    fSpecifyEtmId: i32,
    EtmId: u32,
};

const MPEG2_FILTER = extern struct {
    bVersionNumber: u8,
    wFilterSize: u16,
    fUseRawFilteringBits: i32,
    Filter: [16]u8,
    Mask: [16]u8,
    fSpecifyTableIdExtension: i32,
    TableIdExtension: u16,
    fSpecifyVersion: i32,
    Version: u8,
    fSpecifySectionNumber: i32,
    SectionNumber: u8,
    fSpecifyCurrentNext: i32,
    fNext: i32,
    fSpecifyDsmccOptions: i32,
    Dsmcc: DSMCC_FILTER_OPTIONS,
    fSpecifyAtscOptions: i32,
    Atsc: ATSC_FILTER_OPTIONS,
};
type
  DSMCC_FILTER_OPTIONS {.packed.} = object
    fSpecifyProtocol: int32
    Protocol: uint8
    fSpecifyType: int32
    Type: uint8
    fSpecifyMessageId: int32
    MessageId: uint16
    fSpecifyTransactionId: int32
    fUseTrxIdMessageIdMask: int32
    TransactionId: uint32
    fSpecifyModuleVersion: int32
    ModuleVersion: uint8
    fSpecifyBlockNumber: int32
    BlockNumber: uint16
    fGetModuleCall: int32
    NumberOfBlocksInModule: uint16

  ATSC_FILTER_OPTIONS {.packed.} = object
    fSpecifyEtmId: int32
    EtmId: uint32

  MPEG2_FILTER {.packed.} = object
    bVersionNumber: uint8
    wFilterSize: uint16
    fUseRawFilteringBits: int32
    Filter: array[16, uint8]
    Mask: array[16, uint8]
    fSpecifyTableIdExtension: int32
    TableIdExtension: uint16
    fSpecifyVersion: int32
    Version: uint8
    fSpecifySectionNumber: int32
    SectionNumber: uint8
    fSpecifyCurrentNext: int32
    fNext: int32
    fSpecifyDsmccOptions: int32
    Dsmcc: DSMCC_FILTER_OPTIONS
    fSpecifyAtscOptions: int32
    Atsc: ATSC_FILTER_OPTIONS
align(1)
struct DSMCC_FILTER_OPTIONS
{
    int fSpecifyProtocol;
    ubyte Protocol;
    int fSpecifyType;
    ubyte Type;
    int fSpecifyMessageId;
    ushort MessageId;
    int fSpecifyTransactionId;
    int fUseTrxIdMessageIdMask;
    uint TransactionId;
    int fSpecifyModuleVersion;
    ubyte ModuleVersion;
    int fSpecifyBlockNumber;
    ushort BlockNumber;
    int fGetModuleCall;
    ushort NumberOfBlocksInModule;
}

align(1)
struct ATSC_FILTER_OPTIONS
{
    int fSpecifyEtmId;
    uint EtmId;
}

align(1)
struct MPEG2_FILTER
{
    ubyte bVersionNumber;
    ushort wFilterSize;
    int fUseRawFilteringBits;
    ubyte[16] Filter;
    ubyte[16] Mask;
    int fSpecifyTableIdExtension;
    ushort TableIdExtension;
    int fSpecifyVersion;
    ubyte Version;
    int fSpecifySectionNumber;
    ubyte SectionNumber;
    int fSpecifyCurrentNext;
    int fNext;
    int fSpecifyDsmccOptions;
    DSMCC_FILTER_OPTIONS Dsmcc;
    int fSpecifyAtscOptions;
    ATSC_FILTER_OPTIONS Atsc;
}

HSP用 定義

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

; HSP3.7/3.8 は構造体機能が無いため、4byte整数の配列変数で操作します。(x64 レイアウト)
; MPEG2_FILTER サイズ: 124 バイト(x64)
dim st, 31    ; 4byte整数×31(構造体サイズ 124 / 4 切り上げ)
; bVersionNumber : BYTE (+0, 1byte)  poke st,0,値  /  値 = peek(st,0)
; wFilterSize : WORD (+1, 2byte)  wpoke st,1,値  /  値 = wpeek(st,1)
; fUseRawFilteringBits : BOOL (+3, 4byte)  lpoke st,3,値  /  値 = lpeek(st,3)
; Filter : BYTE (+7, 16byte)  varptr(st)+7 を基点に操作(16byte:入れ子/配列)
; Mask : BYTE (+23, 16byte)  varptr(st)+23 を基点に操作(16byte:入れ子/配列)
; fSpecifyTableIdExtension : BOOL (+39, 4byte)  lpoke st,39,値  /  値 = lpeek(st,39)
; TableIdExtension : WORD (+43, 2byte)  wpoke st,43,値  /  値 = wpeek(st,43)
; fSpecifyVersion : BOOL (+45, 4byte)  lpoke st,45,値  /  値 = lpeek(st,45)
; Version : BYTE (+49, 1byte)  poke st,49,値  /  値 = peek(st,49)
; fSpecifySectionNumber : BOOL (+50, 4byte)  lpoke st,50,値  /  値 = lpeek(st,50)
; SectionNumber : BYTE (+54, 1byte)  poke st,54,値  /  値 = peek(st,54)
; fSpecifyCurrentNext : BOOL (+55, 4byte)  lpoke st,55,値  /  値 = lpeek(st,55)
; fNext : BOOL (+59, 4byte)  lpoke st,59,値  /  値 = lpeek(st,59)
; fSpecifyDsmccOptions : BOOL (+63, 4byte)  lpoke st,63,値  /  値 = lpeek(st,63)
; Dsmcc : DSMCC_FILTER_OPTIONS (+67, 45byte)  varptr(st)+67 を基点に操作(45byte:入れ子/配列)
; fSpecifyAtscOptions : BOOL (+112, 4byte)  st.28 = 値  /  値 = st.28   (lpoke/lpeek も可)
; Atsc : ATSC_FILTER_OPTIONS (+116, 8byte)  varptr(st)+116 を基点に操作(8byte:入れ子/配列)
; ※4byte境界の整数は添字 st.N(N=オフセット/4)で読み書き可。それ以外は peek/poke 系を使用。
; IronHSP は NSTRUCT(構造体)をサポート。32bit/64bit どちらでも同じコードで動作します。
; ※GUID・入れ子構造体はデフォルト型でないため、依存する #defstruct を先に定義(下記に同梱)。
#defstruct global DSMCC_FILTER_OPTIONS, pack=1
    #field bool fSpecifyProtocol
    #field byte Protocol
    #field bool fSpecifyType
    #field byte Type
    #field bool fSpecifyMessageId
    #field short MessageId
    #field bool fSpecifyTransactionId
    #field bool fUseTrxIdMessageIdMask
    #field int TransactionId
    #field bool fSpecifyModuleVersion
    #field byte ModuleVersion
    #field bool fSpecifyBlockNumber
    #field short BlockNumber
    #field bool fGetModuleCall
    #field short NumberOfBlocksInModule
#endstruct

#defstruct global ATSC_FILTER_OPTIONS, pack=1
    #field bool fSpecifyEtmId
    #field int EtmId
#endstruct

#defstruct global MPEG2_FILTER, pack=1
    #field byte bVersionNumber
    #field short wFilterSize
    #field bool fUseRawFilteringBits
    #field byte Filter 16
    #field byte Mask 16
    #field bool fSpecifyTableIdExtension
    #field short TableIdExtension
    #field bool fSpecifyVersion
    #field byte Version
    #field bool fSpecifySectionNumber
    #field byte SectionNumber
    #field bool fSpecifyCurrentNext
    #field bool fNext
    #field bool fSpecifyDsmccOptions
    #field DSMCC_FILTER_OPTIONS Dsmcc
    #field bool fSpecifyAtscOptions
    #field ATSC_FILTER_OPTIONS Atsc
#endstruct

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