Win32 API 日本語リファレンス
ホームMedia.MediaFoundation › DXVA_PictureParameters

DXVA_PictureParameters

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

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

フィールド

フィールドサイズx64x86説明
wDecodedPictureIndexWORD2+0+0デコード先ピクチャのサーフェスインデックスである。
wDeblockedPictureIndexWORD2+2+2デブロッキング後ピクチャのサーフェスインデックスである。
wForwardRefPictureIndexWORD2+4+4前方参照ピクチャのサーフェスインデックスである。
wBackwardRefPictureIndexWORD2+6+6後方参照ピクチャのサーフェスインデックスである。
wPicWidthInMBminus1WORD2+8+8ピクチャ幅をマクロブロック単位で表した値から1を引いた値である。
wPicHeightInMBminus1WORD2+10+10ピクチャ高さをマクロブロック単位で表した値から1を引いた値である。
bMacroblockWidthMinus1BYTE1+12+12マクロブロックの幅から1を引いた値である。
bMacroblockHeightMinus1BYTE1+13+13マクロブロックの高さから1を引いた値である。
bBlockWidthMinus1BYTE1+14+14ブロックの幅から1を引いた値である。
bBlockHeightMinus1BYTE1+15+15ブロックの高さから1を引いた値である。
bBPPminus1BYTE1+16+161サンプルあたりのビット数から1を引いた値である。
bPicStructureBYTE1+17+17ピクチャ構造(フレーム/トップフィールド/ボトムフィールド)を示す。
bSecondFieldBYTE1+18+18インターレースの第2フィールドか否かを示す。
bPicIntraBYTE1+19+19ピクチャがイントラ符号化か否かを示す。
bPicBackwardPredictionBYTE1+20+20後方予測を含むか否か(Bピクチャか)を示す。
bBidirectionalAveragingModeBYTE1+21+21双方向予測時の平均化モードを示す。
bMVprecisionAndChromaRelationBYTE1+22+22動きベクトル精度と色差の関係を示す設定値である。
bChromaFormatBYTE1+23+23色差サンプリング形式(4:2:0/4:2:2/4:4:4等)を示す。
bPicScanFixedBYTE1+24+24スキャン順序が固定か否かを示す。
bPicScanMethodBYTE1+25+25係数スキャン方式(ジグザグ/代替等)を示す。
bPicReadbackRequestsBYTE1+26+26ピクチャ単位の読み戻し要求設定を示す。
bRcontrolBYTE1+27+27丸め制御(Rounding control)の値を示す。
bPicSpatialResid8BYTE1+28+28空間領域残差を8ビットで扱うか否かを示す。
bPicOverflowBlocksBYTE1+29+29オーバーフローブロックの扱いを示す設定値である。
bPicExtrapolationBYTE1+30+30境界外画素の外挿処理設定を示す。
bPicDeblockedBYTE1+31+31デブロッキングフィルタを適用するか否かを示す。
bPicDeblockConfinedBYTE1+32+32デブロッキングをピクチャ内に限定するか否かを示す。
bPic4MVallowedBYTE1+33+331マクロブロックあたり4動きベクトルを許可するか否かを示す。
bPicOBMCBYTE1+34+34重複ブロック動き補償(OBMC)を使用するか否かを示す。
bPicBinPBBYTE1+35+35PBフレーム(H.263)のBピクチャ部分か否かを示す。
bMV_RPSBYTE1+36+36動きベクトルの参照ピクチャ選択(RPS)設定を示す。
bReservedBitsBYTE1+37+37予約ビット。将来拡張用で0を設定する。
wBitstreamFcodesWORD2+38+38動きベクトル範囲を示すFコード値である。
wBitstreamPCEelementsWORD2+40+40ピクチャ符号化拡張(PCE)要素のビット値である。
bBitstreamConcealmentNeedBYTE1+42+42エラー隠蔽が必要か否かを示す設定値である。
bBitstreamConcealmentMethodBYTE1+43+43エラー隠蔽に用いる方式を示す設定値である。

各言語での定義

#include <windows.h>

// DXVA_PictureParameters  (x64 44 / x86 44 バイト)
#pragma pack(push, 1)
typedef struct DXVA_PictureParameters {
    WORD wDecodedPictureIndex;
    WORD wDeblockedPictureIndex;
    WORD wForwardRefPictureIndex;
    WORD wBackwardRefPictureIndex;
    WORD wPicWidthInMBminus1;
    WORD wPicHeightInMBminus1;
    BYTE bMacroblockWidthMinus1;
    BYTE bMacroblockHeightMinus1;
    BYTE bBlockWidthMinus1;
    BYTE bBlockHeightMinus1;
    BYTE bBPPminus1;
    BYTE bPicStructure;
    BYTE bSecondField;
    BYTE bPicIntra;
    BYTE bPicBackwardPrediction;
    BYTE bBidirectionalAveragingMode;
    BYTE bMVprecisionAndChromaRelation;
    BYTE bChromaFormat;
    BYTE bPicScanFixed;
    BYTE bPicScanMethod;
    BYTE bPicReadbackRequests;
    BYTE bRcontrol;
    BYTE bPicSpatialResid8;
    BYTE bPicOverflowBlocks;
    BYTE bPicExtrapolation;
    BYTE bPicDeblocked;
    BYTE bPicDeblockConfined;
    BYTE bPic4MVallowed;
    BYTE bPicOBMC;
    BYTE bPicBinPB;
    BYTE bMV_RPS;
    BYTE bReservedBits;
    WORD wBitstreamFcodes;
    WORD wBitstreamPCEelements;
    BYTE bBitstreamConcealmentNeed;
    BYTE bBitstreamConcealmentMethod;
} DXVA_PictureParameters;
#pragma pack(pop)
using System;
using System.Runtime.InteropServices;

[StructLayout(LayoutKind.Sequential, Pack = 1, CharSet = CharSet.Unicode)]
public struct DXVA_PictureParameters
{
    public ushort wDecodedPictureIndex;
    public ushort wDeblockedPictureIndex;
    public ushort wForwardRefPictureIndex;
    public ushort wBackwardRefPictureIndex;
    public ushort wPicWidthInMBminus1;
    public ushort wPicHeightInMBminus1;
    public byte bMacroblockWidthMinus1;
    public byte bMacroblockHeightMinus1;
    public byte bBlockWidthMinus1;
    public byte bBlockHeightMinus1;
    public byte bBPPminus1;
    public byte bPicStructure;
    public byte bSecondField;
    public byte bPicIntra;
    public byte bPicBackwardPrediction;
    public byte bBidirectionalAveragingMode;
    public byte bMVprecisionAndChromaRelation;
    public byte bChromaFormat;
    public byte bPicScanFixed;
    public byte bPicScanMethod;
    public byte bPicReadbackRequests;
    public byte bRcontrol;
    public byte bPicSpatialResid8;
    public byte bPicOverflowBlocks;
    public byte bPicExtrapolation;
    public byte bPicDeblocked;
    public byte bPicDeblockConfined;
    public byte bPic4MVallowed;
    public byte bPicOBMC;
    public byte bPicBinPB;
    public byte bMV_RPS;
    public byte bReservedBits;
    public ushort wBitstreamFcodes;
    public ushort wBitstreamPCEelements;
    public byte bBitstreamConcealmentNeed;
    public byte bBitstreamConcealmentMethod;
}
Imports System.Runtime.InteropServices

<StructLayout(LayoutKind.Sequential, Pack:=1, CharSet:=CharSet.Unicode)>
Public Structure DXVA_PictureParameters
    Public wDecodedPictureIndex As UShort
    Public wDeblockedPictureIndex As UShort
    Public wForwardRefPictureIndex As UShort
    Public wBackwardRefPictureIndex As UShort
    Public wPicWidthInMBminus1 As UShort
    Public wPicHeightInMBminus1 As UShort
    Public bMacroblockWidthMinus1 As Byte
    Public bMacroblockHeightMinus1 As Byte
    Public bBlockWidthMinus1 As Byte
    Public bBlockHeightMinus1 As Byte
    Public bBPPminus1 As Byte
    Public bPicStructure As Byte
    Public bSecondField As Byte
    Public bPicIntra As Byte
    Public bPicBackwardPrediction As Byte
    Public bBidirectionalAveragingMode As Byte
    Public bMVprecisionAndChromaRelation As Byte
    Public bChromaFormat As Byte
    Public bPicScanFixed As Byte
    Public bPicScanMethod As Byte
    Public bPicReadbackRequests As Byte
    Public bRcontrol As Byte
    Public bPicSpatialResid8 As Byte
    Public bPicOverflowBlocks As Byte
    Public bPicExtrapolation As Byte
    Public bPicDeblocked As Byte
    Public bPicDeblockConfined As Byte
    Public bPic4MVallowed As Byte
    Public bPicOBMC As Byte
    Public bPicBinPB As Byte
    Public bMV_RPS As Byte
    Public bReservedBits As Byte
    Public wBitstreamFcodes As UShort
    Public wBitstreamPCEelements As UShort
    Public bBitstreamConcealmentNeed As Byte
    Public bBitstreamConcealmentMethod As Byte
End Structure
import ctypes
from ctypes import wintypes

class DXVA_PictureParameters(ctypes.Structure):
    _pack_ = 1
    _fields_ = [
        ("wDecodedPictureIndex", ctypes.c_ushort),
        ("wDeblockedPictureIndex", ctypes.c_ushort),
        ("wForwardRefPictureIndex", ctypes.c_ushort),
        ("wBackwardRefPictureIndex", ctypes.c_ushort),
        ("wPicWidthInMBminus1", ctypes.c_ushort),
        ("wPicHeightInMBminus1", ctypes.c_ushort),
        ("bMacroblockWidthMinus1", ctypes.c_ubyte),
        ("bMacroblockHeightMinus1", ctypes.c_ubyte),
        ("bBlockWidthMinus1", ctypes.c_ubyte),
        ("bBlockHeightMinus1", ctypes.c_ubyte),
        ("bBPPminus1", ctypes.c_ubyte),
        ("bPicStructure", ctypes.c_ubyte),
        ("bSecondField", ctypes.c_ubyte),
        ("bPicIntra", ctypes.c_ubyte),
        ("bPicBackwardPrediction", ctypes.c_ubyte),
        ("bBidirectionalAveragingMode", ctypes.c_ubyte),
        ("bMVprecisionAndChromaRelation", ctypes.c_ubyte),
        ("bChromaFormat", ctypes.c_ubyte),
        ("bPicScanFixed", ctypes.c_ubyte),
        ("bPicScanMethod", ctypes.c_ubyte),
        ("bPicReadbackRequests", ctypes.c_ubyte),
        ("bRcontrol", ctypes.c_ubyte),
        ("bPicSpatialResid8", ctypes.c_ubyte),
        ("bPicOverflowBlocks", ctypes.c_ubyte),
        ("bPicExtrapolation", ctypes.c_ubyte),
        ("bPicDeblocked", ctypes.c_ubyte),
        ("bPicDeblockConfined", ctypes.c_ubyte),
        ("bPic4MVallowed", ctypes.c_ubyte),
        ("bPicOBMC", ctypes.c_ubyte),
        ("bPicBinPB", ctypes.c_ubyte),
        ("bMV_RPS", ctypes.c_ubyte),
        ("bReservedBits", ctypes.c_ubyte),
        ("wBitstreamFcodes", ctypes.c_ushort),
        ("wBitstreamPCEelements", ctypes.c_ushort),
        ("bBitstreamConcealmentNeed", ctypes.c_ubyte),
        ("bBitstreamConcealmentMethod", ctypes.c_ubyte),
    ]
#[repr(C, packed(1))]
pub struct DXVA_PictureParameters {
    pub wDecodedPictureIndex: u16,
    pub wDeblockedPictureIndex: u16,
    pub wForwardRefPictureIndex: u16,
    pub wBackwardRefPictureIndex: u16,
    pub wPicWidthInMBminus1: u16,
    pub wPicHeightInMBminus1: u16,
    pub bMacroblockWidthMinus1: u8,
    pub bMacroblockHeightMinus1: u8,
    pub bBlockWidthMinus1: u8,
    pub bBlockHeightMinus1: u8,
    pub bBPPminus1: u8,
    pub bPicStructure: u8,
    pub bSecondField: u8,
    pub bPicIntra: u8,
    pub bPicBackwardPrediction: u8,
    pub bBidirectionalAveragingMode: u8,
    pub bMVprecisionAndChromaRelation: u8,
    pub bChromaFormat: u8,
    pub bPicScanFixed: u8,
    pub bPicScanMethod: u8,
    pub bPicReadbackRequests: u8,
    pub bRcontrol: u8,
    pub bPicSpatialResid8: u8,
    pub bPicOverflowBlocks: u8,
    pub bPicExtrapolation: u8,
    pub bPicDeblocked: u8,
    pub bPicDeblockConfined: u8,
    pub bPic4MVallowed: u8,
    pub bPicOBMC: u8,
    pub bPicBinPB: u8,
    pub bMV_RPS: u8,
    pub bReservedBits: u8,
    pub wBitstreamFcodes: u16,
    pub wBitstreamPCEelements: u16,
    pub bBitstreamConcealmentNeed: u8,
    pub bBitstreamConcealmentMethod: u8,
}
import "golang.org/x/sys/windows"

type DXVA_PictureParameters struct {
	wDecodedPictureIndex uint16
	wDeblockedPictureIndex uint16
	wForwardRefPictureIndex uint16
	wBackwardRefPictureIndex uint16
	wPicWidthInMBminus1 uint16
	wPicHeightInMBminus1 uint16
	bMacroblockWidthMinus1 byte
	bMacroblockHeightMinus1 byte
	bBlockWidthMinus1 byte
	bBlockHeightMinus1 byte
	bBPPminus1 byte
	bPicStructure byte
	bSecondField byte
	bPicIntra byte
	bPicBackwardPrediction byte
	bBidirectionalAveragingMode byte
	bMVprecisionAndChromaRelation byte
	bChromaFormat byte
	bPicScanFixed byte
	bPicScanMethod byte
	bPicReadbackRequests byte
	bRcontrol byte
	bPicSpatialResid8 byte
	bPicOverflowBlocks byte
	bPicExtrapolation byte
	bPicDeblocked byte
	bPicDeblockConfined byte
	bPic4MVallowed byte
	bPicOBMC byte
	bPicBinPB byte
	bMV_RPS byte
	bReservedBits byte
	wBitstreamFcodes uint16
	wBitstreamPCEelements uint16
	bBitstreamConcealmentNeed byte
	bBitstreamConcealmentMethod byte
}
type
  DXVA_PictureParameters = packed record
    wDecodedPictureIndex: Word;
    wDeblockedPictureIndex: Word;
    wForwardRefPictureIndex: Word;
    wBackwardRefPictureIndex: Word;
    wPicWidthInMBminus1: Word;
    wPicHeightInMBminus1: Word;
    bMacroblockWidthMinus1: Byte;
    bMacroblockHeightMinus1: Byte;
    bBlockWidthMinus1: Byte;
    bBlockHeightMinus1: Byte;
    bBPPminus1: Byte;
    bPicStructure: Byte;
    bSecondField: Byte;
    bPicIntra: Byte;
    bPicBackwardPrediction: Byte;
    bBidirectionalAveragingMode: Byte;
    bMVprecisionAndChromaRelation: Byte;
    bChromaFormat: Byte;
    bPicScanFixed: Byte;
    bPicScanMethod: Byte;
    bPicReadbackRequests: Byte;
    bRcontrol: Byte;
    bPicSpatialResid8: Byte;
    bPicOverflowBlocks: Byte;
    bPicExtrapolation: Byte;
    bPicDeblocked: Byte;
    bPicDeblockConfined: Byte;
    bPic4MVallowed: Byte;
    bPicOBMC: Byte;
    bPicBinPB: Byte;
    bMV_RPS: Byte;
    bReservedBits: Byte;
    wBitstreamFcodes: Word;
    wBitstreamPCEelements: Word;
    bBitstreamConcealmentNeed: Byte;
    bBitstreamConcealmentMethod: Byte;
  end;
const DXVA_PictureParameters = extern struct {
    wDecodedPictureIndex: u16,
    wDeblockedPictureIndex: u16,
    wForwardRefPictureIndex: u16,
    wBackwardRefPictureIndex: u16,
    wPicWidthInMBminus1: u16,
    wPicHeightInMBminus1: u16,
    bMacroblockWidthMinus1: u8,
    bMacroblockHeightMinus1: u8,
    bBlockWidthMinus1: u8,
    bBlockHeightMinus1: u8,
    bBPPminus1: u8,
    bPicStructure: u8,
    bSecondField: u8,
    bPicIntra: u8,
    bPicBackwardPrediction: u8,
    bBidirectionalAveragingMode: u8,
    bMVprecisionAndChromaRelation: u8,
    bChromaFormat: u8,
    bPicScanFixed: u8,
    bPicScanMethod: u8,
    bPicReadbackRequests: u8,
    bRcontrol: u8,
    bPicSpatialResid8: u8,
    bPicOverflowBlocks: u8,
    bPicExtrapolation: u8,
    bPicDeblocked: u8,
    bPicDeblockConfined: u8,
    bPic4MVallowed: u8,
    bPicOBMC: u8,
    bPicBinPB: u8,
    bMV_RPS: u8,
    bReservedBits: u8,
    wBitstreamFcodes: u16,
    wBitstreamPCEelements: u16,
    bBitstreamConcealmentNeed: u8,
    bBitstreamConcealmentMethod: u8,
};
type
  DXVA_PictureParameters {.packed.} = object
    wDecodedPictureIndex: uint16
    wDeblockedPictureIndex: uint16
    wForwardRefPictureIndex: uint16
    wBackwardRefPictureIndex: uint16
    wPicWidthInMBminus1: uint16
    wPicHeightInMBminus1: uint16
    bMacroblockWidthMinus1: uint8
    bMacroblockHeightMinus1: uint8
    bBlockWidthMinus1: uint8
    bBlockHeightMinus1: uint8
    bBPPminus1: uint8
    bPicStructure: uint8
    bSecondField: uint8
    bPicIntra: uint8
    bPicBackwardPrediction: uint8
    bBidirectionalAveragingMode: uint8
    bMVprecisionAndChromaRelation: uint8
    bChromaFormat: uint8
    bPicScanFixed: uint8
    bPicScanMethod: uint8
    bPicReadbackRequests: uint8
    bRcontrol: uint8
    bPicSpatialResid8: uint8
    bPicOverflowBlocks: uint8
    bPicExtrapolation: uint8
    bPicDeblocked: uint8
    bPicDeblockConfined: uint8
    bPic4MVallowed: uint8
    bPicOBMC: uint8
    bPicBinPB: uint8
    bMV_RPS: uint8
    bReservedBits: uint8
    wBitstreamFcodes: uint16
    wBitstreamPCEelements: uint16
    bBitstreamConcealmentNeed: uint8
    bBitstreamConcealmentMethod: uint8
align(1)
struct DXVA_PictureParameters
{
    ushort wDecodedPictureIndex;
    ushort wDeblockedPictureIndex;
    ushort wForwardRefPictureIndex;
    ushort wBackwardRefPictureIndex;
    ushort wPicWidthInMBminus1;
    ushort wPicHeightInMBminus1;
    ubyte bMacroblockWidthMinus1;
    ubyte bMacroblockHeightMinus1;
    ubyte bBlockWidthMinus1;
    ubyte bBlockHeightMinus1;
    ubyte bBPPminus1;
    ubyte bPicStructure;
    ubyte bSecondField;
    ubyte bPicIntra;
    ubyte bPicBackwardPrediction;
    ubyte bBidirectionalAveragingMode;
    ubyte bMVprecisionAndChromaRelation;
    ubyte bChromaFormat;
    ubyte bPicScanFixed;
    ubyte bPicScanMethod;
    ubyte bPicReadbackRequests;
    ubyte bRcontrol;
    ubyte bPicSpatialResid8;
    ubyte bPicOverflowBlocks;
    ubyte bPicExtrapolation;
    ubyte bPicDeblocked;
    ubyte bPicDeblockConfined;
    ubyte bPic4MVallowed;
    ubyte bPicOBMC;
    ubyte bPicBinPB;
    ubyte bMV_RPS;
    ubyte bReservedBits;
    ushort wBitstreamFcodes;
    ushort wBitstreamPCEelements;
    ubyte bBitstreamConcealmentNeed;
    ubyte bBitstreamConcealmentMethod;
}

HSP用 定義

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

; HSP3.7/3.8 は構造体機能が無いため、4byte整数の配列変数で操作します。(x64 レイアウト)
; DXVA_PictureParameters サイズ: 44 バイト(x64)
dim st, 11    ; 4byte整数×11(構造体サイズ 44 / 4 切り上げ)
; wDecodedPictureIndex : WORD (+0, 2byte)  wpoke st,0,値  /  値 = wpeek(st,0)
; wDeblockedPictureIndex : WORD (+2, 2byte)  wpoke st,2,値  /  値 = wpeek(st,2)
; wForwardRefPictureIndex : WORD (+4, 2byte)  wpoke st,4,値  /  値 = wpeek(st,4)
; wBackwardRefPictureIndex : WORD (+6, 2byte)  wpoke st,6,値  /  値 = wpeek(st,6)
; wPicWidthInMBminus1 : WORD (+8, 2byte)  wpoke st,8,値  /  値 = wpeek(st,8)
; wPicHeightInMBminus1 : WORD (+10, 2byte)  wpoke st,10,値  /  値 = wpeek(st,10)
; bMacroblockWidthMinus1 : BYTE (+12, 1byte)  poke st,12,値  /  値 = peek(st,12)
; bMacroblockHeightMinus1 : BYTE (+13, 1byte)  poke st,13,値  /  値 = peek(st,13)
; bBlockWidthMinus1 : BYTE (+14, 1byte)  poke st,14,値  /  値 = peek(st,14)
; bBlockHeightMinus1 : BYTE (+15, 1byte)  poke st,15,値  /  値 = peek(st,15)
; bBPPminus1 : BYTE (+16, 1byte)  poke st,16,値  /  値 = peek(st,16)
; bPicStructure : BYTE (+17, 1byte)  poke st,17,値  /  値 = peek(st,17)
; bSecondField : BYTE (+18, 1byte)  poke st,18,値  /  値 = peek(st,18)
; bPicIntra : BYTE (+19, 1byte)  poke st,19,値  /  値 = peek(st,19)
; bPicBackwardPrediction : BYTE (+20, 1byte)  poke st,20,値  /  値 = peek(st,20)
; bBidirectionalAveragingMode : BYTE (+21, 1byte)  poke st,21,値  /  値 = peek(st,21)
; bMVprecisionAndChromaRelation : BYTE (+22, 1byte)  poke st,22,値  /  値 = peek(st,22)
; bChromaFormat : BYTE (+23, 1byte)  poke st,23,値  /  値 = peek(st,23)
; bPicScanFixed : BYTE (+24, 1byte)  poke st,24,値  /  値 = peek(st,24)
; bPicScanMethod : BYTE (+25, 1byte)  poke st,25,値  /  値 = peek(st,25)
; bPicReadbackRequests : BYTE (+26, 1byte)  poke st,26,値  /  値 = peek(st,26)
; bRcontrol : BYTE (+27, 1byte)  poke st,27,値  /  値 = peek(st,27)
; bPicSpatialResid8 : BYTE (+28, 1byte)  poke st,28,値  /  値 = peek(st,28)
; bPicOverflowBlocks : BYTE (+29, 1byte)  poke st,29,値  /  値 = peek(st,29)
; bPicExtrapolation : BYTE (+30, 1byte)  poke st,30,値  /  値 = peek(st,30)
; bPicDeblocked : BYTE (+31, 1byte)  poke st,31,値  /  値 = peek(st,31)
; bPicDeblockConfined : BYTE (+32, 1byte)  poke st,32,値  /  値 = peek(st,32)
; bPic4MVallowed : BYTE (+33, 1byte)  poke st,33,値  /  値 = peek(st,33)
; bPicOBMC : BYTE (+34, 1byte)  poke st,34,値  /  値 = peek(st,34)
; bPicBinPB : BYTE (+35, 1byte)  poke st,35,値  /  値 = peek(st,35)
; bMV_RPS : BYTE (+36, 1byte)  poke st,36,値  /  値 = peek(st,36)
; bReservedBits : BYTE (+37, 1byte)  poke st,37,値  /  値 = peek(st,37)
; wBitstreamFcodes : WORD (+38, 2byte)  wpoke st,38,値  /  値 = wpeek(st,38)
; wBitstreamPCEelements : WORD (+40, 2byte)  wpoke st,40,値  /  値 = wpeek(st,40)
; bBitstreamConcealmentNeed : BYTE (+42, 1byte)  poke st,42,値  /  値 = peek(st,42)
; bBitstreamConcealmentMethod : BYTE (+43, 1byte)  poke st,43,値  /  値 = peek(st,43)
; ※4byte境界の整数は添字 st.N(N=オフセット/4)で読み書き可。それ以外は peek/poke 系を使用。
; IronHSP は NSTRUCT(構造体)をサポート。32bit/64bit どちらでも同じコードで動作します。
#defstruct global DXVA_PictureParameters, pack=1
    #field short wDecodedPictureIndex
    #field short wDeblockedPictureIndex
    #field short wForwardRefPictureIndex
    #field short wBackwardRefPictureIndex
    #field short wPicWidthInMBminus1
    #field short wPicHeightInMBminus1
    #field byte bMacroblockWidthMinus1
    #field byte bMacroblockHeightMinus1
    #field byte bBlockWidthMinus1
    #field byte bBlockHeightMinus1
    #field byte bBPPminus1
    #field byte bPicStructure
    #field byte bSecondField
    #field byte bPicIntra
    #field byte bPicBackwardPrediction
    #field byte bBidirectionalAveragingMode
    #field byte bMVprecisionAndChromaRelation
    #field byte bChromaFormat
    #field byte bPicScanFixed
    #field byte bPicScanMethod
    #field byte bPicReadbackRequests
    #field byte bRcontrol
    #field byte bPicSpatialResid8
    #field byte bPicOverflowBlocks
    #field byte bPicExtrapolation
    #field byte bPicDeblocked
    #field byte bPicDeblockConfined
    #field byte bPic4MVallowed
    #field byte bPicOBMC
    #field byte bPicBinPB
    #field byte bMV_RPS
    #field byte bReservedBits
    #field short wBitstreamFcodes
    #field short wBitstreamPCEelements
    #field byte bBitstreamConcealmentNeed
    #field byte bBitstreamConcealmentMethod
#endstruct

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