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

DXVA_COPPStatusSignalingCmdData

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

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

フィールド

フィールドサイズx64x86説明
rAppGUID16+0+0アプリケーションが指定した乱数GUID。応答の真正性検証に使う。
dwFlagsDWORD4+16+16ステータス情報のフラグ。
AvailableTVProtectionStandardsDWORD4+20+20利用可能なTV保護規格の集合を示す値。
ActiveTVProtectionStandardDWORD4+24+24現在有効なTV保護規格を示す値。
TVTypeDWORD4+28+28接続されているTVの種別を示す値。
AspectRatioValidMask1DWORD4+32+32アスペクト比シグナリング1の有効ビットマスク。
AspectRatioData1DWORD4+36+36アスペクト比シグナリング1のデータ値。
AspectRatioValidMask2DWORD4+40+40アスペクト比シグナリング2の有効ビットマスク。
AspectRatioData2DWORD4+44+44アスペクト比シグナリング2のデータ値。
AspectRatioValidMask3DWORD4+48+48アスペクト比シグナリング3の有効ビットマスク。
AspectRatioData3DWORD4+52+52アスペクト比シグナリング3のデータ値。
ExtendedInfoValidMaskDWORD16+56+56拡張情報の有効ビットを示すマスク。
ExtendedInfoDataDWORD16+72+72拡張情報のデータ値。

各言語での定義

#include <windows.h>

// DXVA_COPPStatusSignalingCmdData  (x64 88 / x86 88 バイト)
typedef struct DXVA_COPPStatusSignalingCmdData {
    GUID rApp;
    DWORD dwFlags;
    DWORD AvailableTVProtectionStandards;
    DWORD ActiveTVProtectionStandard;
    DWORD TVType;
    DWORD AspectRatioValidMask1;
    DWORD AspectRatioData1;
    DWORD AspectRatioValidMask2;
    DWORD AspectRatioData2;
    DWORD AspectRatioValidMask3;
    DWORD AspectRatioData3;
    DWORD ExtendedInfoValidMask[4];
    DWORD ExtendedInfoData[4];
} DXVA_COPPStatusSignalingCmdData;
using System;
using System.Runtime.InteropServices;

[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct DXVA_COPPStatusSignalingCmdData
{
    public Guid rApp;
    public uint dwFlags;
    public uint AvailableTVProtectionStandards;
    public uint ActiveTVProtectionStandard;
    public uint TVType;
    public uint AspectRatioValidMask1;
    public uint AspectRatioData1;
    public uint AspectRatioValidMask2;
    public uint AspectRatioData2;
    public uint AspectRatioValidMask3;
    public uint AspectRatioData3;
    [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)] public uint[] ExtendedInfoValidMask;
    [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)] public uint[] ExtendedInfoData;
}
Imports System.Runtime.InteropServices

<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure DXVA_COPPStatusSignalingCmdData
    Public rApp As Guid
    Public dwFlags As UInteger
    Public AvailableTVProtectionStandards As UInteger
    Public ActiveTVProtectionStandard As UInteger
    Public TVType As UInteger
    Public AspectRatioValidMask1 As UInteger
    Public AspectRatioData1 As UInteger
    Public AspectRatioValidMask2 As UInteger
    Public AspectRatioData2 As UInteger
    Public AspectRatioValidMask3 As UInteger
    Public AspectRatioData3 As UInteger
    <MarshalAs(UnmanagedType.ByValArray, SizeConst:=4)> Public ExtendedInfoValidMask() As UInteger
    <MarshalAs(UnmanagedType.ByValArray, SizeConst:=4)> Public ExtendedInfoData() As UInteger
End Structure
import ctypes
from ctypes import wintypes

class DXVA_COPPStatusSignalingCmdData(ctypes.Structure):
    _fields_ = [
        ("rApp", GUID),
        ("dwFlags", wintypes.DWORD),
        ("AvailableTVProtectionStandards", wintypes.DWORD),
        ("ActiveTVProtectionStandard", wintypes.DWORD),
        ("TVType", wintypes.DWORD),
        ("AspectRatioValidMask1", wintypes.DWORD),
        ("AspectRatioData1", wintypes.DWORD),
        ("AspectRatioValidMask2", wintypes.DWORD),
        ("AspectRatioData2", wintypes.DWORD),
        ("AspectRatioValidMask3", wintypes.DWORD),
        ("AspectRatioData3", wintypes.DWORD),
        ("ExtendedInfoValidMask", wintypes.DWORD * 4),
        ("ExtendedInfoData", wintypes.DWORD * 4),
    ]
#[repr(C)]
pub struct DXVA_COPPStatusSignalingCmdData {
    pub rApp: GUID,
    pub dwFlags: u32,
    pub AvailableTVProtectionStandards: u32,
    pub ActiveTVProtectionStandard: u32,
    pub TVType: u32,
    pub AspectRatioValidMask1: u32,
    pub AspectRatioData1: u32,
    pub AspectRatioValidMask2: u32,
    pub AspectRatioData2: u32,
    pub AspectRatioValidMask3: u32,
    pub AspectRatioData3: u32,
    pub ExtendedInfoValidMask: [u32; 4],
    pub ExtendedInfoData: [u32; 4],
}
import "golang.org/x/sys/windows"

type DXVA_COPPStatusSignalingCmdData struct {
	rApp windows.GUID
	dwFlags uint32
	AvailableTVProtectionStandards uint32
	ActiveTVProtectionStandard uint32
	TVType uint32
	AspectRatioValidMask1 uint32
	AspectRatioData1 uint32
	AspectRatioValidMask2 uint32
	AspectRatioData2 uint32
	AspectRatioValidMask3 uint32
	AspectRatioData3 uint32
	ExtendedInfoValidMask [4]uint32
	ExtendedInfoData [4]uint32
}
type
  DXVA_COPPStatusSignalingCmdData = record
    rApp: TGUID;
    dwFlags: DWORD;
    AvailableTVProtectionStandards: DWORD;
    ActiveTVProtectionStandard: DWORD;
    TVType: DWORD;
    AspectRatioValidMask1: DWORD;
    AspectRatioData1: DWORD;
    AspectRatioValidMask2: DWORD;
    AspectRatioData2: DWORD;
    AspectRatioValidMask3: DWORD;
    AspectRatioData3: DWORD;
    ExtendedInfoValidMask: array[0..3] of DWORD;
    ExtendedInfoData: array[0..3] of DWORD;
  end;
const DXVA_COPPStatusSignalingCmdData = extern struct {
    rApp: GUID,
    dwFlags: u32,
    AvailableTVProtectionStandards: u32,
    ActiveTVProtectionStandard: u32,
    TVType: u32,
    AspectRatioValidMask1: u32,
    AspectRatioData1: u32,
    AspectRatioValidMask2: u32,
    AspectRatioData2: u32,
    AspectRatioValidMask3: u32,
    AspectRatioData3: u32,
    ExtendedInfoValidMask: [4]u32,
    ExtendedInfoData: [4]u32,
};
type
  DXVA_COPPStatusSignalingCmdData {.bycopy.} = object
    rApp: GUID
    dwFlags: uint32
    AvailableTVProtectionStandards: uint32
    ActiveTVProtectionStandard: uint32
    TVType: uint32
    AspectRatioValidMask1: uint32
    AspectRatioData1: uint32
    AspectRatioValidMask2: uint32
    AspectRatioData2: uint32
    AspectRatioValidMask3: uint32
    AspectRatioData3: uint32
    ExtendedInfoValidMask: array[4, uint32]
    ExtendedInfoData: array[4, uint32]
struct DXVA_COPPStatusSignalingCmdData
{
    GUID rApp;
    uint dwFlags;
    uint AvailableTVProtectionStandards;
    uint ActiveTVProtectionStandard;
    uint TVType;
    uint AspectRatioValidMask1;
    uint AspectRatioData1;
    uint AspectRatioValidMask2;
    uint AspectRatioData2;
    uint AspectRatioValidMask3;
    uint AspectRatioData3;
    uint[4] ExtendedInfoValidMask;
    uint[4] ExtendedInfoData;
}

HSP用 定義

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

; HSP3.7/3.8 は構造体機能が無いため、4byte整数の配列変数で操作します。(x64 レイアウト)
; DXVA_COPPStatusSignalingCmdData サイズ: 88 バイト(x64)
dim st, 22    ; 4byte整数×22(構造体サイズ 88 / 4 切り上げ)
; rApp : GUID (+0, 16byte)  varptr(st)+0 を基点に操作(16byte:入れ子/配列)
; dwFlags : DWORD (+16, 4byte)  st.4 = 値  /  値 = st.4   (lpoke/lpeek も可)
; AvailableTVProtectionStandards : DWORD (+20, 4byte)  st.5 = 値  /  値 = st.5   (lpoke/lpeek も可)
; ActiveTVProtectionStandard : DWORD (+24, 4byte)  st.6 = 値  /  値 = st.6   (lpoke/lpeek も可)
; TVType : DWORD (+28, 4byte)  st.7 = 値  /  値 = st.7   (lpoke/lpeek も可)
; AspectRatioValidMask1 : DWORD (+32, 4byte)  st.8 = 値  /  値 = st.8   (lpoke/lpeek も可)
; AspectRatioData1 : DWORD (+36, 4byte)  st.9 = 値  /  値 = st.9   (lpoke/lpeek も可)
; AspectRatioValidMask2 : DWORD (+40, 4byte)  st.10 = 値  /  値 = st.10   (lpoke/lpeek も可)
; AspectRatioData2 : DWORD (+44, 4byte)  st.11 = 値  /  値 = st.11   (lpoke/lpeek も可)
; AspectRatioValidMask3 : DWORD (+48, 4byte)  st.12 = 値  /  値 = st.12   (lpoke/lpeek も可)
; AspectRatioData3 : DWORD (+52, 4byte)  st.13 = 値  /  値 = st.13   (lpoke/lpeek も可)
; ExtendedInfoValidMask : DWORD (+56, 16byte)  varptr(st)+56 を基点に操作(16byte:入れ子/配列)
; ExtendedInfoData : DWORD (+72, 16byte)  varptr(st)+72 を基点に操作(16byte:入れ子/配列)
; ※4byte境界の整数は添字 st.N(N=オフセット/4)で読み書き可。それ以外は peek/poke 系を使用。
; IronHSP は NSTRUCT(構造体)をサポート。32bit/64bit どちらでも同じコードで動作します。
; ※GUID・入れ子構造体はデフォルト型でないため、依存する #defstruct を先に定義(下記に同梱)。
#defstruct global GUID, pack=1
    #field int Data1
    #field short Data2
    #field short Data3
    #field byte Data4 8
#endstruct

#defstruct global DXVA_COPPStatusSignalingCmdData
    #field GUID rApp
    #field int dwFlags
    #field int AvailableTVProtectionStandards
    #field int ActiveTVProtectionStandard
    #field int TVType
    #field int AspectRatioValidMask1
    #field int AspectRatioData1
    #field int AspectRatioValidMask2
    #field int AspectRatioData2
    #field int AspectRatioValidMask3
    #field int AspectRatioData3
    #field int ExtendedInfoValidMask 4
    #field int ExtendedInfoData 4
#endstruct

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