Win32 API 日本語リファレンス
ホームGraphics.DirectDraw › DDCAPS_DX6

DDCAPS_DX6

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

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

フィールド

フィールドサイズx64x86説明
dwSizeDWORD4+0+0構造体サイズ(バイト数)。呼び出し前に設定する。
dwCapsDWORD4+4+4ドライバの一般能力を示すDDCAPS_系フラグ。
dwCaps2DWORD4+8+8ドライバの追加能力フラグ(その2)を示す。
dwCKeyCapsDWORD4+12+12カラーキー機能の対応状況を示すフラグ。
dwFXCapsDWORD4+16+16Bltの拡張効果の対応フラグを示す。
dwFXAlphaCapsDWORD4+20+20アルファ関連効果の対応状況を示すフラグ。
dwPalCapsDWORD4+24+24パレット機能の対応状況を示すフラグ。
dwSVCapsDWORD4+28+28ステレオビジョンの対応状況を示すフラグ。
dwAlphaBltConstBitDepthsDWORD4+32+32Blt定数アルファの対応ビット深度を示す。
dwAlphaBltPixelBitDepthsDWORD4+36+36Bltピクセルアルファの対応ビット深度を示す。
dwAlphaBltSurfaceBitDepthsDWORD4+40+40Bltサーフェスアルファの対応ビット深度を示す。
dwAlphaOverlayConstBitDepthsDWORD4+44+44オーバーレイ定数アルファの対応ビット深度を示す。
dwAlphaOverlayPixelBitDepthsDWORD4+48+48オーバーレイピクセルアルファの対応ビット深度を示す。
dwAlphaOverlaySurfaceBitDepthsDWORD4+52+52オーバーレイサーフェスアルファの対応ビット深度を示す。
dwZBufferBitDepthsDWORD4+56+56Zバッファの対応ビット深度を示す。
dwVidMemTotalDWORD4+60+60ビデオメモリの総容量(バイト)を示す。
dwVidMemFreeDWORD4+64+64空きビデオメモリ容量(バイト)を示す。
dwMaxVisibleOverlaysDWORD4+68+68同時表示可能なオーバーレイの最大数を示す。
dwCurrVisibleOverlaysDWORD4+72+72現在表示中のオーバーレイ数を示す。
dwNumFourCCCodesDWORD4+76+76対応するFourCCコードの数を示す。
dwAlignBoundarySrcDWORD4+80+80転送元矩形の境界アライメント要件を示す。
dwAlignSizeSrcDWORD4+84+84転送元矩形のサイズアライメント要件を示す。
dwAlignBoundaryDestDWORD4+88+88転送先矩形の境界アライメント要件を示す。
dwAlignSizeDestDWORD4+92+92転送先矩形のサイズアライメント要件を示す。
dwAlignStrideAlignDWORD4+96+96サーフェスストライドのアライメント要件を示す。
dwRopsDWORD32+100+100対応ROPを表すビット集合(配列)を示す。
ddsOldCapsDDSCAPS4+132+132旧形式のサーフェス能力(DDSCAPS)。互換用に保持する。
dwMinOverlayStretchDWORD4+136+136オーバーレイ最小拡大率を1000倍値で示す。
dwMaxOverlayStretchDWORD4+140+140オーバーレイ最大拡大率を1000倍値で示す。
dwMinLiveVideoStretchDWORD4+144+144ライブ映像の最小拡大率(廃止)を示す。
dwMaxLiveVideoStretchDWORD4+148+148ライブ映像の最大拡大率(廃止)を示す。
dwMinHwCodecStretchDWORD4+152+152ハードウェアコーデックの最小拡大率(廃止)を示す。
dwMaxHwCodecStretchDWORD4+156+156ハードウェアコーデックの最大拡大率(廃止)を示す。
dwReserved1DWORD4+160+160予約フィールド。0とする。
dwReserved2DWORD4+164+164予約フィールド。0とする。
dwReserved3DWORD4+168+168予約フィールド。0とする。
dwSVBCapsDWORD4+172+172システム→ビデオメモリBltの対応能力フラグを示す。
dwSVBCKeyCapsDWORD4+176+176システム→ビデオBltのカラーキー対応フラグを示す。
dwSVBFXCapsDWORD4+180+180システム→ビデオBltの効果対応フラグを示す。
dwSVBRopsDWORD32+184+184システム→ビデオBltで対応するROP集合を示す。
dwVSBCapsDWORD4+216+216ビデオ→システムメモリBltの対応能力フラグを示す。
dwVSBCKeyCapsDWORD4+220+220ビデオ→システムBltのカラーキー対応フラグを示す。
dwVSBFXCapsDWORD4+224+224ビデオ→システムBltの効果対応フラグを示す。
dwVSBRopsDWORD32+228+228ビデオ→システムBltで対応するROP集合を示す。
dwSSBCapsDWORD4+260+260システム→システムメモリBltの対応能力フラグを示す。
dwSSBCKeyCapsDWORD4+264+264システム→システムBltのカラーキー対応フラグを示す。
dwSSBFXCapsDWORD4+268+268システム→システムBltの効果対応フラグを示す。
dwSSBRopsDWORD32+272+272システム→システムBltで対応するROP集合を示す。
dwMaxVideoPortsDWORD4+304+304サポートされるビデオポートの最大数を示す。
dwCurrVideoPortsDWORD4+308+308現在使用中のビデオポート数を示す。
dwSVBCaps2DWORD4+312+312システム→ビデオBltの追加能力フラグ(その2)を示す。
dwNLVBCapsDWORD4+316+316非ローカルビデオメモリBltの対応能力フラグを示す。
dwNLVBCaps2DWORD4+320+320非ローカルビデオBltの追加能力フラグ(その2)を示す。
dwNLVBCKeyCapsDWORD4+324+324非ローカルビデオBltのカラーキー対応フラグを示す。
dwNLVBFXCapsDWORD4+328+328非ローカルビデオBltの効果対応フラグを示す。
dwNLVBRopsDWORD32+332+332非ローカルビデオBltで対応するROP集合を示す。
ddsCapsDDSCAPS216+364+364現行形式の拡張サーフェス能力(DDSCAPS2)。

各言語での定義

#include <windows.h>

// DDSCAPS  (x64 4 / x86 4 バイト)
typedef struct DDSCAPS {
    DWORD dwCaps;
} DDSCAPS;

// DDSCAPS2  (x64 16 / x86 16 バイト)
typedef struct DDSCAPS2 {
    DWORD dwCaps;
    DWORD dwCaps2;
    DWORD dwCaps3;
    _Anonymous_e__Union Anonymous;
} DDSCAPS2;

// DDCAPS_DX6  (x64 380 / x86 380 バイト)
typedef struct DDCAPS_DX6 {
    DWORD dwSize;
    DWORD dwCaps;
    DWORD dwCaps2;
    DWORD dwCKeyCaps;
    DWORD dwFXCaps;
    DWORD dwFXAlphaCaps;
    DWORD dwPalCaps;
    DWORD dwSVCaps;
    DWORD dwAlphaBltConstBitDepths;
    DWORD dwAlphaBltPixelBitDepths;
    DWORD dwAlphaBltSurfaceBitDepths;
    DWORD dwAlphaOverlayConstBitDepths;
    DWORD dwAlphaOverlayPixelBitDepths;
    DWORD dwAlphaOverlaySurfaceBitDepths;
    DWORD dwZBufferBitDepths;
    DWORD dwVidMemTotal;
    DWORD dwVidMemFree;
    DWORD dwMaxVisibleOverlays;
    DWORD dwCurrVisibleOverlays;
    DWORD dwNumFourCCCodes;
    DWORD dwAlignBoundarySrc;
    DWORD dwAlignSizeSrc;
    DWORD dwAlignBoundaryDest;
    DWORD dwAlignSizeDest;
    DWORD dwAlignStrideAlign;
    DWORD dwRops[8];
    DDSCAPS ddsOldCaps;
    DWORD dwMinOverlayStretch;
    DWORD dwMaxOverlayStretch;
    DWORD dwMinLiveVideoStretch;
    DWORD dwMaxLiveVideoStretch;
    DWORD dwMinHwCodecStretch;
    DWORD dwMaxHwCodecStretch;
    DWORD dwReserved1;
    DWORD dwReserved2;
    DWORD dwReserved3;
    DWORD dwSVBCaps;
    DWORD dwSVBCKeyCaps;
    DWORD dwSVBFXCaps;
    DWORD dwSVBRops[8];
    DWORD dwVSBCaps;
    DWORD dwVSBCKeyCaps;
    DWORD dwVSBFXCaps;
    DWORD dwVSBRops[8];
    DWORD dwSSBCaps;
    DWORD dwSSBCKeyCaps;
    DWORD dwSSBFXCaps;
    DWORD dwSSBRops[8];
    DWORD dwMaxVideoPorts;
    DWORD dwCurrVideoPorts;
    DWORD dwSVBCaps2;
    DWORD dwNLVBCaps;
    DWORD dwNLVBCaps2;
    DWORD dwNLVBCKeyCaps;
    DWORD dwNLVBFXCaps;
    DWORD dwNLVBRops[8];
    DDSCAPS2 ddsCaps;
} DDCAPS_DX6;
using System;
using System.Runtime.InteropServices;

[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct DDSCAPS
{
    public uint dwCaps;
}

[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct DDSCAPS2
{
    public uint dwCaps;
    public uint dwCaps2;
    public uint dwCaps3;
    public _Anonymous_e__Union Anonymous;
}

[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
public struct DDCAPS_DX6
{
    public uint dwSize;
    public uint dwCaps;
    public uint dwCaps2;
    public uint dwCKeyCaps;
    public uint dwFXCaps;
    public uint dwFXAlphaCaps;
    public uint dwPalCaps;
    public uint dwSVCaps;
    public uint dwAlphaBltConstBitDepths;
    public uint dwAlphaBltPixelBitDepths;
    public uint dwAlphaBltSurfaceBitDepths;
    public uint dwAlphaOverlayConstBitDepths;
    public uint dwAlphaOverlayPixelBitDepths;
    public uint dwAlphaOverlaySurfaceBitDepths;
    public uint dwZBufferBitDepths;
    public uint dwVidMemTotal;
    public uint dwVidMemFree;
    public uint dwMaxVisibleOverlays;
    public uint dwCurrVisibleOverlays;
    public uint dwNumFourCCCodes;
    public uint dwAlignBoundarySrc;
    public uint dwAlignSizeSrc;
    public uint dwAlignBoundaryDest;
    public uint dwAlignSizeDest;
    public uint dwAlignStrideAlign;
    [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)] public uint[] dwRops;
    public DDSCAPS ddsOldCaps;
    public uint dwMinOverlayStretch;
    public uint dwMaxOverlayStretch;
    public uint dwMinLiveVideoStretch;
    public uint dwMaxLiveVideoStretch;
    public uint dwMinHwCodecStretch;
    public uint dwMaxHwCodecStretch;
    public uint dwReserved1;
    public uint dwReserved2;
    public uint dwReserved3;
    public uint dwSVBCaps;
    public uint dwSVBCKeyCaps;
    public uint dwSVBFXCaps;
    [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)] public uint[] dwSVBRops;
    public uint dwVSBCaps;
    public uint dwVSBCKeyCaps;
    public uint dwVSBFXCaps;
    [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)] public uint[] dwVSBRops;
    public uint dwSSBCaps;
    public uint dwSSBCKeyCaps;
    public uint dwSSBFXCaps;
    [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)] public uint[] dwSSBRops;
    public uint dwMaxVideoPorts;
    public uint dwCurrVideoPorts;
    public uint dwSVBCaps2;
    public uint dwNLVBCaps;
    public uint dwNLVBCaps2;
    public uint dwNLVBCKeyCaps;
    public uint dwNLVBFXCaps;
    [MarshalAs(UnmanagedType.ByValArray, SizeConst = 8)] public uint[] dwNLVBRops;
    public DDSCAPS2 ddsCaps;
}
Imports System.Runtime.InteropServices

<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure DDSCAPS
    Public dwCaps As UInteger
End Structure

<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure DDSCAPS2
    Public dwCaps As UInteger
    Public dwCaps2 As UInteger
    Public dwCaps3 As UInteger
    Public Anonymous As _Anonymous_e__Union
End Structure

<StructLayout(LayoutKind.Sequential, CharSet:=CharSet.Unicode)>
Public Structure DDCAPS_DX6
    Public dwSize As UInteger
    Public dwCaps As UInteger
    Public dwCaps2 As UInteger
    Public dwCKeyCaps As UInteger
    Public dwFXCaps As UInteger
    Public dwFXAlphaCaps As UInteger
    Public dwPalCaps As UInteger
    Public dwSVCaps As UInteger
    Public dwAlphaBltConstBitDepths As UInteger
    Public dwAlphaBltPixelBitDepths As UInteger
    Public dwAlphaBltSurfaceBitDepths As UInteger
    Public dwAlphaOverlayConstBitDepths As UInteger
    Public dwAlphaOverlayPixelBitDepths As UInteger
    Public dwAlphaOverlaySurfaceBitDepths As UInteger
    Public dwZBufferBitDepths As UInteger
    Public dwVidMemTotal As UInteger
    Public dwVidMemFree As UInteger
    Public dwMaxVisibleOverlays As UInteger
    Public dwCurrVisibleOverlays As UInteger
    Public dwNumFourCCCodes As UInteger
    Public dwAlignBoundarySrc As UInteger
    Public dwAlignSizeSrc As UInteger
    Public dwAlignBoundaryDest As UInteger
    Public dwAlignSizeDest As UInteger
    Public dwAlignStrideAlign As UInteger
    <MarshalAs(UnmanagedType.ByValArray, SizeConst:=8)> Public dwRops() As UInteger
    Public ddsOldCaps As DDSCAPS
    Public dwMinOverlayStretch As UInteger
    Public dwMaxOverlayStretch As UInteger
    Public dwMinLiveVideoStretch As UInteger
    Public dwMaxLiveVideoStretch As UInteger
    Public dwMinHwCodecStretch As UInteger
    Public dwMaxHwCodecStretch As UInteger
    Public dwReserved1 As UInteger
    Public dwReserved2 As UInteger
    Public dwReserved3 As UInteger
    Public dwSVBCaps As UInteger
    Public dwSVBCKeyCaps As UInteger
    Public dwSVBFXCaps As UInteger
    <MarshalAs(UnmanagedType.ByValArray, SizeConst:=8)> Public dwSVBRops() As UInteger
    Public dwVSBCaps As UInteger
    Public dwVSBCKeyCaps As UInteger
    Public dwVSBFXCaps As UInteger
    <MarshalAs(UnmanagedType.ByValArray, SizeConst:=8)> Public dwVSBRops() As UInteger
    Public dwSSBCaps As UInteger
    Public dwSSBCKeyCaps As UInteger
    Public dwSSBFXCaps As UInteger
    <MarshalAs(UnmanagedType.ByValArray, SizeConst:=8)> Public dwSSBRops() As UInteger
    Public dwMaxVideoPorts As UInteger
    Public dwCurrVideoPorts As UInteger
    Public dwSVBCaps2 As UInteger
    Public dwNLVBCaps As UInteger
    Public dwNLVBCaps2 As UInteger
    Public dwNLVBCKeyCaps As UInteger
    Public dwNLVBFXCaps As UInteger
    <MarshalAs(UnmanagedType.ByValArray, SizeConst:=8)> Public dwNLVBRops() As UInteger
    Public ddsCaps As DDSCAPS2
End Structure
import ctypes
from ctypes import wintypes

class DDSCAPS(ctypes.Structure):
    _fields_ = [
        ("dwCaps", wintypes.DWORD),
    ]

class DDSCAPS2(ctypes.Structure):
    _fields_ = [
        ("dwCaps", wintypes.DWORD),
        ("dwCaps2", wintypes.DWORD),
        ("dwCaps3", wintypes.DWORD),
        ("Anonymous", _Anonymous_e__Union),
    ]

class DDCAPS_DX6(ctypes.Structure):
    _fields_ = [
        ("dwSize", wintypes.DWORD),
        ("dwCaps", wintypes.DWORD),
        ("dwCaps2", wintypes.DWORD),
        ("dwCKeyCaps", wintypes.DWORD),
        ("dwFXCaps", wintypes.DWORD),
        ("dwFXAlphaCaps", wintypes.DWORD),
        ("dwPalCaps", wintypes.DWORD),
        ("dwSVCaps", wintypes.DWORD),
        ("dwAlphaBltConstBitDepths", wintypes.DWORD),
        ("dwAlphaBltPixelBitDepths", wintypes.DWORD),
        ("dwAlphaBltSurfaceBitDepths", wintypes.DWORD),
        ("dwAlphaOverlayConstBitDepths", wintypes.DWORD),
        ("dwAlphaOverlayPixelBitDepths", wintypes.DWORD),
        ("dwAlphaOverlaySurfaceBitDepths", wintypes.DWORD),
        ("dwZBufferBitDepths", wintypes.DWORD),
        ("dwVidMemTotal", wintypes.DWORD),
        ("dwVidMemFree", wintypes.DWORD),
        ("dwMaxVisibleOverlays", wintypes.DWORD),
        ("dwCurrVisibleOverlays", wintypes.DWORD),
        ("dwNumFourCCCodes", wintypes.DWORD),
        ("dwAlignBoundarySrc", wintypes.DWORD),
        ("dwAlignSizeSrc", wintypes.DWORD),
        ("dwAlignBoundaryDest", wintypes.DWORD),
        ("dwAlignSizeDest", wintypes.DWORD),
        ("dwAlignStrideAlign", wintypes.DWORD),
        ("dwRops", wintypes.DWORD * 8),
        ("ddsOldCaps", DDSCAPS),
        ("dwMinOverlayStretch", wintypes.DWORD),
        ("dwMaxOverlayStretch", wintypes.DWORD),
        ("dwMinLiveVideoStretch", wintypes.DWORD),
        ("dwMaxLiveVideoStretch", wintypes.DWORD),
        ("dwMinHwCodecStretch", wintypes.DWORD),
        ("dwMaxHwCodecStretch", wintypes.DWORD),
        ("dwReserved1", wintypes.DWORD),
        ("dwReserved2", wintypes.DWORD),
        ("dwReserved3", wintypes.DWORD),
        ("dwSVBCaps", wintypes.DWORD),
        ("dwSVBCKeyCaps", wintypes.DWORD),
        ("dwSVBFXCaps", wintypes.DWORD),
        ("dwSVBRops", wintypes.DWORD * 8),
        ("dwVSBCaps", wintypes.DWORD),
        ("dwVSBCKeyCaps", wintypes.DWORD),
        ("dwVSBFXCaps", wintypes.DWORD),
        ("dwVSBRops", wintypes.DWORD * 8),
        ("dwSSBCaps", wintypes.DWORD),
        ("dwSSBCKeyCaps", wintypes.DWORD),
        ("dwSSBFXCaps", wintypes.DWORD),
        ("dwSSBRops", wintypes.DWORD * 8),
        ("dwMaxVideoPorts", wintypes.DWORD),
        ("dwCurrVideoPorts", wintypes.DWORD),
        ("dwSVBCaps2", wintypes.DWORD),
        ("dwNLVBCaps", wintypes.DWORD),
        ("dwNLVBCaps2", wintypes.DWORD),
        ("dwNLVBCKeyCaps", wintypes.DWORD),
        ("dwNLVBFXCaps", wintypes.DWORD),
        ("dwNLVBRops", wintypes.DWORD * 8),
        ("ddsCaps", DDSCAPS2),
    ]
#[repr(C)]
pub struct DDSCAPS {
    pub dwCaps: u32,
}

#[repr(C)]
pub struct DDSCAPS2 {
    pub dwCaps: u32,
    pub dwCaps2: u32,
    pub dwCaps3: u32,
    pub Anonymous: _Anonymous_e__Union,
}

#[repr(C)]
pub struct DDCAPS_DX6 {
    pub dwSize: u32,
    pub dwCaps: u32,
    pub dwCaps2: u32,
    pub dwCKeyCaps: u32,
    pub dwFXCaps: u32,
    pub dwFXAlphaCaps: u32,
    pub dwPalCaps: u32,
    pub dwSVCaps: u32,
    pub dwAlphaBltConstBitDepths: u32,
    pub dwAlphaBltPixelBitDepths: u32,
    pub dwAlphaBltSurfaceBitDepths: u32,
    pub dwAlphaOverlayConstBitDepths: u32,
    pub dwAlphaOverlayPixelBitDepths: u32,
    pub dwAlphaOverlaySurfaceBitDepths: u32,
    pub dwZBufferBitDepths: u32,
    pub dwVidMemTotal: u32,
    pub dwVidMemFree: u32,
    pub dwMaxVisibleOverlays: u32,
    pub dwCurrVisibleOverlays: u32,
    pub dwNumFourCCCodes: u32,
    pub dwAlignBoundarySrc: u32,
    pub dwAlignSizeSrc: u32,
    pub dwAlignBoundaryDest: u32,
    pub dwAlignSizeDest: u32,
    pub dwAlignStrideAlign: u32,
    pub dwRops: [u32; 8],
    pub ddsOldCaps: DDSCAPS,
    pub dwMinOverlayStretch: u32,
    pub dwMaxOverlayStretch: u32,
    pub dwMinLiveVideoStretch: u32,
    pub dwMaxLiveVideoStretch: u32,
    pub dwMinHwCodecStretch: u32,
    pub dwMaxHwCodecStretch: u32,
    pub dwReserved1: u32,
    pub dwReserved2: u32,
    pub dwReserved3: u32,
    pub dwSVBCaps: u32,
    pub dwSVBCKeyCaps: u32,
    pub dwSVBFXCaps: u32,
    pub dwSVBRops: [u32; 8],
    pub dwVSBCaps: u32,
    pub dwVSBCKeyCaps: u32,
    pub dwVSBFXCaps: u32,
    pub dwVSBRops: [u32; 8],
    pub dwSSBCaps: u32,
    pub dwSSBCKeyCaps: u32,
    pub dwSSBFXCaps: u32,
    pub dwSSBRops: [u32; 8],
    pub dwMaxVideoPorts: u32,
    pub dwCurrVideoPorts: u32,
    pub dwSVBCaps2: u32,
    pub dwNLVBCaps: u32,
    pub dwNLVBCaps2: u32,
    pub dwNLVBCKeyCaps: u32,
    pub dwNLVBFXCaps: u32,
    pub dwNLVBRops: [u32; 8],
    pub ddsCaps: DDSCAPS2,
}
import "golang.org/x/sys/windows"

type DDSCAPS struct {
	dwCaps uint32
}

type DDSCAPS2 struct {
	dwCaps uint32
	dwCaps2 uint32
	dwCaps3 uint32
	Anonymous _Anonymous_e__Union
}

type DDCAPS_DX6 struct {
	dwSize uint32
	dwCaps uint32
	dwCaps2 uint32
	dwCKeyCaps uint32
	dwFXCaps uint32
	dwFXAlphaCaps uint32
	dwPalCaps uint32
	dwSVCaps uint32
	dwAlphaBltConstBitDepths uint32
	dwAlphaBltPixelBitDepths uint32
	dwAlphaBltSurfaceBitDepths uint32
	dwAlphaOverlayConstBitDepths uint32
	dwAlphaOverlayPixelBitDepths uint32
	dwAlphaOverlaySurfaceBitDepths uint32
	dwZBufferBitDepths uint32
	dwVidMemTotal uint32
	dwVidMemFree uint32
	dwMaxVisibleOverlays uint32
	dwCurrVisibleOverlays uint32
	dwNumFourCCCodes uint32
	dwAlignBoundarySrc uint32
	dwAlignSizeSrc uint32
	dwAlignBoundaryDest uint32
	dwAlignSizeDest uint32
	dwAlignStrideAlign uint32
	dwRops [8]uint32
	ddsOldCaps DDSCAPS
	dwMinOverlayStretch uint32
	dwMaxOverlayStretch uint32
	dwMinLiveVideoStretch uint32
	dwMaxLiveVideoStretch uint32
	dwMinHwCodecStretch uint32
	dwMaxHwCodecStretch uint32
	dwReserved1 uint32
	dwReserved2 uint32
	dwReserved3 uint32
	dwSVBCaps uint32
	dwSVBCKeyCaps uint32
	dwSVBFXCaps uint32
	dwSVBRops [8]uint32
	dwVSBCaps uint32
	dwVSBCKeyCaps uint32
	dwVSBFXCaps uint32
	dwVSBRops [8]uint32
	dwSSBCaps uint32
	dwSSBCKeyCaps uint32
	dwSSBFXCaps uint32
	dwSSBRops [8]uint32
	dwMaxVideoPorts uint32
	dwCurrVideoPorts uint32
	dwSVBCaps2 uint32
	dwNLVBCaps uint32
	dwNLVBCaps2 uint32
	dwNLVBCKeyCaps uint32
	dwNLVBFXCaps uint32
	dwNLVBRops [8]uint32
	ddsCaps DDSCAPS2
}
type
  DDSCAPS = record
    dwCaps: DWORD;
  end;

  DDSCAPS2 = record
    dwCaps: DWORD;
    dwCaps2: DWORD;
    dwCaps3: DWORD;
    Anonymous: _Anonymous_e__Union;
  end;

  DDCAPS_DX6 = record
    dwSize: DWORD;
    dwCaps: DWORD;
    dwCaps2: DWORD;
    dwCKeyCaps: DWORD;
    dwFXCaps: DWORD;
    dwFXAlphaCaps: DWORD;
    dwPalCaps: DWORD;
    dwSVCaps: DWORD;
    dwAlphaBltConstBitDepths: DWORD;
    dwAlphaBltPixelBitDepths: DWORD;
    dwAlphaBltSurfaceBitDepths: DWORD;
    dwAlphaOverlayConstBitDepths: DWORD;
    dwAlphaOverlayPixelBitDepths: DWORD;
    dwAlphaOverlaySurfaceBitDepths: DWORD;
    dwZBufferBitDepths: DWORD;
    dwVidMemTotal: DWORD;
    dwVidMemFree: DWORD;
    dwMaxVisibleOverlays: DWORD;
    dwCurrVisibleOverlays: DWORD;
    dwNumFourCCCodes: DWORD;
    dwAlignBoundarySrc: DWORD;
    dwAlignSizeSrc: DWORD;
    dwAlignBoundaryDest: DWORD;
    dwAlignSizeDest: DWORD;
    dwAlignStrideAlign: DWORD;
    dwRops: array[0..7] of DWORD;
    ddsOldCaps: DDSCAPS;
    dwMinOverlayStretch: DWORD;
    dwMaxOverlayStretch: DWORD;
    dwMinLiveVideoStretch: DWORD;
    dwMaxLiveVideoStretch: DWORD;
    dwMinHwCodecStretch: DWORD;
    dwMaxHwCodecStretch: DWORD;
    dwReserved1: DWORD;
    dwReserved2: DWORD;
    dwReserved3: DWORD;
    dwSVBCaps: DWORD;
    dwSVBCKeyCaps: DWORD;
    dwSVBFXCaps: DWORD;
    dwSVBRops: array[0..7] of DWORD;
    dwVSBCaps: DWORD;
    dwVSBCKeyCaps: DWORD;
    dwVSBFXCaps: DWORD;
    dwVSBRops: array[0..7] of DWORD;
    dwSSBCaps: DWORD;
    dwSSBCKeyCaps: DWORD;
    dwSSBFXCaps: DWORD;
    dwSSBRops: array[0..7] of DWORD;
    dwMaxVideoPorts: DWORD;
    dwCurrVideoPorts: DWORD;
    dwSVBCaps2: DWORD;
    dwNLVBCaps: DWORD;
    dwNLVBCaps2: DWORD;
    dwNLVBCKeyCaps: DWORD;
    dwNLVBFXCaps: DWORD;
    dwNLVBRops: array[0..7] of DWORD;
    ddsCaps: DDSCAPS2;
  end;
const DDSCAPS = extern struct {
    dwCaps: u32,
};

const DDSCAPS2 = extern struct {
    dwCaps: u32,
    dwCaps2: u32,
    dwCaps3: u32,
    Anonymous: _Anonymous_e__Union,
};

const DDCAPS_DX6 = extern struct {
    dwSize: u32,
    dwCaps: u32,
    dwCaps2: u32,
    dwCKeyCaps: u32,
    dwFXCaps: u32,
    dwFXAlphaCaps: u32,
    dwPalCaps: u32,
    dwSVCaps: u32,
    dwAlphaBltConstBitDepths: u32,
    dwAlphaBltPixelBitDepths: u32,
    dwAlphaBltSurfaceBitDepths: u32,
    dwAlphaOverlayConstBitDepths: u32,
    dwAlphaOverlayPixelBitDepths: u32,
    dwAlphaOverlaySurfaceBitDepths: u32,
    dwZBufferBitDepths: u32,
    dwVidMemTotal: u32,
    dwVidMemFree: u32,
    dwMaxVisibleOverlays: u32,
    dwCurrVisibleOverlays: u32,
    dwNumFourCCCodes: u32,
    dwAlignBoundarySrc: u32,
    dwAlignSizeSrc: u32,
    dwAlignBoundaryDest: u32,
    dwAlignSizeDest: u32,
    dwAlignStrideAlign: u32,
    dwRops: [8]u32,
    ddsOldCaps: DDSCAPS,
    dwMinOverlayStretch: u32,
    dwMaxOverlayStretch: u32,
    dwMinLiveVideoStretch: u32,
    dwMaxLiveVideoStretch: u32,
    dwMinHwCodecStretch: u32,
    dwMaxHwCodecStretch: u32,
    dwReserved1: u32,
    dwReserved2: u32,
    dwReserved3: u32,
    dwSVBCaps: u32,
    dwSVBCKeyCaps: u32,
    dwSVBFXCaps: u32,
    dwSVBRops: [8]u32,
    dwVSBCaps: u32,
    dwVSBCKeyCaps: u32,
    dwVSBFXCaps: u32,
    dwVSBRops: [8]u32,
    dwSSBCaps: u32,
    dwSSBCKeyCaps: u32,
    dwSSBFXCaps: u32,
    dwSSBRops: [8]u32,
    dwMaxVideoPorts: u32,
    dwCurrVideoPorts: u32,
    dwSVBCaps2: u32,
    dwNLVBCaps: u32,
    dwNLVBCaps2: u32,
    dwNLVBCKeyCaps: u32,
    dwNLVBFXCaps: u32,
    dwNLVBRops: [8]u32,
    ddsCaps: DDSCAPS2,
};
type
  DDSCAPS {.bycopy.} = object
    dwCaps: uint32

  DDSCAPS2 {.bycopy.} = object
    dwCaps: uint32
    dwCaps2: uint32
    dwCaps3: uint32
    Anonymous: _Anonymous_e__Union

  DDCAPS_DX6 {.bycopy.} = object
    dwSize: uint32
    dwCaps: uint32
    dwCaps2: uint32
    dwCKeyCaps: uint32
    dwFXCaps: uint32
    dwFXAlphaCaps: uint32
    dwPalCaps: uint32
    dwSVCaps: uint32
    dwAlphaBltConstBitDepths: uint32
    dwAlphaBltPixelBitDepths: uint32
    dwAlphaBltSurfaceBitDepths: uint32
    dwAlphaOverlayConstBitDepths: uint32
    dwAlphaOverlayPixelBitDepths: uint32
    dwAlphaOverlaySurfaceBitDepths: uint32
    dwZBufferBitDepths: uint32
    dwVidMemTotal: uint32
    dwVidMemFree: uint32
    dwMaxVisibleOverlays: uint32
    dwCurrVisibleOverlays: uint32
    dwNumFourCCCodes: uint32
    dwAlignBoundarySrc: uint32
    dwAlignSizeSrc: uint32
    dwAlignBoundaryDest: uint32
    dwAlignSizeDest: uint32
    dwAlignStrideAlign: uint32
    dwRops: array[8, uint32]
    ddsOldCaps: DDSCAPS
    dwMinOverlayStretch: uint32
    dwMaxOverlayStretch: uint32
    dwMinLiveVideoStretch: uint32
    dwMaxLiveVideoStretch: uint32
    dwMinHwCodecStretch: uint32
    dwMaxHwCodecStretch: uint32
    dwReserved1: uint32
    dwReserved2: uint32
    dwReserved3: uint32
    dwSVBCaps: uint32
    dwSVBCKeyCaps: uint32
    dwSVBFXCaps: uint32
    dwSVBRops: array[8, uint32]
    dwVSBCaps: uint32
    dwVSBCKeyCaps: uint32
    dwVSBFXCaps: uint32
    dwVSBRops: array[8, uint32]
    dwSSBCaps: uint32
    dwSSBCKeyCaps: uint32
    dwSSBFXCaps: uint32
    dwSSBRops: array[8, uint32]
    dwMaxVideoPorts: uint32
    dwCurrVideoPorts: uint32
    dwSVBCaps2: uint32
    dwNLVBCaps: uint32
    dwNLVBCaps2: uint32
    dwNLVBCKeyCaps: uint32
    dwNLVBFXCaps: uint32
    dwNLVBRops: array[8, uint32]
    ddsCaps: DDSCAPS2
struct DDSCAPS
{
    uint dwCaps;
}

struct DDSCAPS2
{
    uint dwCaps;
    uint dwCaps2;
    uint dwCaps3;
    _Anonymous_e__Union Anonymous;
}

struct DDCAPS_DX6
{
    uint dwSize;
    uint dwCaps;
    uint dwCaps2;
    uint dwCKeyCaps;
    uint dwFXCaps;
    uint dwFXAlphaCaps;
    uint dwPalCaps;
    uint dwSVCaps;
    uint dwAlphaBltConstBitDepths;
    uint dwAlphaBltPixelBitDepths;
    uint dwAlphaBltSurfaceBitDepths;
    uint dwAlphaOverlayConstBitDepths;
    uint dwAlphaOverlayPixelBitDepths;
    uint dwAlphaOverlaySurfaceBitDepths;
    uint dwZBufferBitDepths;
    uint dwVidMemTotal;
    uint dwVidMemFree;
    uint dwMaxVisibleOverlays;
    uint dwCurrVisibleOverlays;
    uint dwNumFourCCCodes;
    uint dwAlignBoundarySrc;
    uint dwAlignSizeSrc;
    uint dwAlignBoundaryDest;
    uint dwAlignSizeDest;
    uint dwAlignStrideAlign;
    uint[8] dwRops;
    DDSCAPS ddsOldCaps;
    uint dwMinOverlayStretch;
    uint dwMaxOverlayStretch;
    uint dwMinLiveVideoStretch;
    uint dwMaxLiveVideoStretch;
    uint dwMinHwCodecStretch;
    uint dwMaxHwCodecStretch;
    uint dwReserved1;
    uint dwReserved2;
    uint dwReserved3;
    uint dwSVBCaps;
    uint dwSVBCKeyCaps;
    uint dwSVBFXCaps;
    uint[8] dwSVBRops;
    uint dwVSBCaps;
    uint dwVSBCKeyCaps;
    uint dwVSBFXCaps;
    uint[8] dwVSBRops;
    uint dwSSBCaps;
    uint dwSSBCKeyCaps;
    uint dwSSBFXCaps;
    uint[8] dwSSBRops;
    uint dwMaxVideoPorts;
    uint dwCurrVideoPorts;
    uint dwSVBCaps2;
    uint dwNLVBCaps;
    uint dwNLVBCaps2;
    uint dwNLVBCKeyCaps;
    uint dwNLVBFXCaps;
    uint[8] dwNLVBRops;
    DDSCAPS2 ddsCaps;
}

HSP用 定義

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

; HSP3.7/3.8 は構造体機能が無いため、4byte整数の配列変数で操作します。(x64 レイアウト)
; DDCAPS_DX6 サイズ: 380 バイト(x64)
dim st, 95    ; 4byte整数×95(構造体サイズ 380 / 4 切り上げ)
; dwSize : DWORD (+0, 4byte)  st.0 = 値  /  値 = st.0   (lpoke/lpeek も可)
; dwCaps : DWORD (+4, 4byte)  st.1 = 値  /  値 = st.1   (lpoke/lpeek も可)
; dwCaps2 : DWORD (+8, 4byte)  st.2 = 値  /  値 = st.2   (lpoke/lpeek も可)
; dwCKeyCaps : DWORD (+12, 4byte)  st.3 = 値  /  値 = st.3   (lpoke/lpeek も可)
; dwFXCaps : DWORD (+16, 4byte)  st.4 = 値  /  値 = st.4   (lpoke/lpeek も可)
; dwFXAlphaCaps : DWORD (+20, 4byte)  st.5 = 値  /  値 = st.5   (lpoke/lpeek も可)
; dwPalCaps : DWORD (+24, 4byte)  st.6 = 値  /  値 = st.6   (lpoke/lpeek も可)
; dwSVCaps : DWORD (+28, 4byte)  st.7 = 値  /  値 = st.7   (lpoke/lpeek も可)
; dwAlphaBltConstBitDepths : DWORD (+32, 4byte)  st.8 = 値  /  値 = st.8   (lpoke/lpeek も可)
; dwAlphaBltPixelBitDepths : DWORD (+36, 4byte)  st.9 = 値  /  値 = st.9   (lpoke/lpeek も可)
; dwAlphaBltSurfaceBitDepths : DWORD (+40, 4byte)  st.10 = 値  /  値 = st.10   (lpoke/lpeek も可)
; dwAlphaOverlayConstBitDepths : DWORD (+44, 4byte)  st.11 = 値  /  値 = st.11   (lpoke/lpeek も可)
; dwAlphaOverlayPixelBitDepths : DWORD (+48, 4byte)  st.12 = 値  /  値 = st.12   (lpoke/lpeek も可)
; dwAlphaOverlaySurfaceBitDepths : DWORD (+52, 4byte)  st.13 = 値  /  値 = st.13   (lpoke/lpeek も可)
; dwZBufferBitDepths : DWORD (+56, 4byte)  st.14 = 値  /  値 = st.14   (lpoke/lpeek も可)
; dwVidMemTotal : DWORD (+60, 4byte)  st.15 = 値  /  値 = st.15   (lpoke/lpeek も可)
; dwVidMemFree : DWORD (+64, 4byte)  st.16 = 値  /  値 = st.16   (lpoke/lpeek も可)
; dwMaxVisibleOverlays : DWORD (+68, 4byte)  st.17 = 値  /  値 = st.17   (lpoke/lpeek も可)
; dwCurrVisibleOverlays : DWORD (+72, 4byte)  st.18 = 値  /  値 = st.18   (lpoke/lpeek も可)
; dwNumFourCCCodes : DWORD (+76, 4byte)  st.19 = 値  /  値 = st.19   (lpoke/lpeek も可)
; dwAlignBoundarySrc : DWORD (+80, 4byte)  st.20 = 値  /  値 = st.20   (lpoke/lpeek も可)
; dwAlignSizeSrc : DWORD (+84, 4byte)  st.21 = 値  /  値 = st.21   (lpoke/lpeek も可)
; dwAlignBoundaryDest : DWORD (+88, 4byte)  st.22 = 値  /  値 = st.22   (lpoke/lpeek も可)
; dwAlignSizeDest : DWORD (+92, 4byte)  st.23 = 値  /  値 = st.23   (lpoke/lpeek も可)
; dwAlignStrideAlign : DWORD (+96, 4byte)  st.24 = 値  /  値 = st.24   (lpoke/lpeek も可)
; dwRops : DWORD (+100, 32byte)  varptr(st)+100 を基点に操作(32byte:入れ子/配列)
; ddsOldCaps : DDSCAPS (+132, 4byte)  varptr(st)+132 を基点に操作(4byte:入れ子/配列)
; dwMinOverlayStretch : DWORD (+136, 4byte)  st.34 = 値  /  値 = st.34   (lpoke/lpeek も可)
; dwMaxOverlayStretch : DWORD (+140, 4byte)  st.35 = 値  /  値 = st.35   (lpoke/lpeek も可)
; dwMinLiveVideoStretch : DWORD (+144, 4byte)  st.36 = 値  /  値 = st.36   (lpoke/lpeek も可)
; dwMaxLiveVideoStretch : DWORD (+148, 4byte)  st.37 = 値  /  値 = st.37   (lpoke/lpeek も可)
; dwMinHwCodecStretch : DWORD (+152, 4byte)  st.38 = 値  /  値 = st.38   (lpoke/lpeek も可)
; dwMaxHwCodecStretch : DWORD (+156, 4byte)  st.39 = 値  /  値 = st.39   (lpoke/lpeek も可)
; dwReserved1 : DWORD (+160, 4byte)  st.40 = 値  /  値 = st.40   (lpoke/lpeek も可)
; dwReserved2 : DWORD (+164, 4byte)  st.41 = 値  /  値 = st.41   (lpoke/lpeek も可)
; dwReserved3 : DWORD (+168, 4byte)  st.42 = 値  /  値 = st.42   (lpoke/lpeek も可)
; dwSVBCaps : DWORD (+172, 4byte)  st.43 = 値  /  値 = st.43   (lpoke/lpeek も可)
; dwSVBCKeyCaps : DWORD (+176, 4byte)  st.44 = 値  /  値 = st.44   (lpoke/lpeek も可)
; dwSVBFXCaps : DWORD (+180, 4byte)  st.45 = 値  /  値 = st.45   (lpoke/lpeek も可)
; dwSVBRops : DWORD (+184, 32byte)  varptr(st)+184 を基点に操作(32byte:入れ子/配列)
; dwVSBCaps : DWORD (+216, 4byte)  st.54 = 値  /  値 = st.54   (lpoke/lpeek も可)
; dwVSBCKeyCaps : DWORD (+220, 4byte)  st.55 = 値  /  値 = st.55   (lpoke/lpeek も可)
; dwVSBFXCaps : DWORD (+224, 4byte)  st.56 = 値  /  値 = st.56   (lpoke/lpeek も可)
; dwVSBRops : DWORD (+228, 32byte)  varptr(st)+228 を基点に操作(32byte:入れ子/配列)
; dwSSBCaps : DWORD (+260, 4byte)  st.65 = 値  /  値 = st.65   (lpoke/lpeek も可)
; dwSSBCKeyCaps : DWORD (+264, 4byte)  st.66 = 値  /  値 = st.66   (lpoke/lpeek も可)
; dwSSBFXCaps : DWORD (+268, 4byte)  st.67 = 値  /  値 = st.67   (lpoke/lpeek も可)
; dwSSBRops : DWORD (+272, 32byte)  varptr(st)+272 を基点に操作(32byte:入れ子/配列)
; dwMaxVideoPorts : DWORD (+304, 4byte)  st.76 = 値  /  値 = st.76   (lpoke/lpeek も可)
; dwCurrVideoPorts : DWORD (+308, 4byte)  st.77 = 値  /  値 = st.77   (lpoke/lpeek も可)
; dwSVBCaps2 : DWORD (+312, 4byte)  st.78 = 値  /  値 = st.78   (lpoke/lpeek も可)
; dwNLVBCaps : DWORD (+316, 4byte)  st.79 = 値  /  値 = st.79   (lpoke/lpeek も可)
; dwNLVBCaps2 : DWORD (+320, 4byte)  st.80 = 値  /  値 = st.80   (lpoke/lpeek も可)
; dwNLVBCKeyCaps : DWORD (+324, 4byte)  st.81 = 値  /  値 = st.81   (lpoke/lpeek も可)
; dwNLVBFXCaps : DWORD (+328, 4byte)  st.82 = 値  /  値 = st.82   (lpoke/lpeek も可)
; dwNLVBRops : DWORD (+332, 32byte)  varptr(st)+332 を基点に操作(32byte:入れ子/配列)
; ddsCaps : DDSCAPS2 (+364, 16byte)  varptr(st)+364 を基点に操作(16byte:入れ子/配列)
; ※4byte境界の整数は添字 st.N(N=オフセット/4)で読み書き可。それ以外は peek/poke 系を使用。
; IronHSP は NSTRUCT(構造体)をサポート。32bit/64bit どちらでも同じコードで動作します。
; ※GUID・入れ子構造体はデフォルト型でないため、依存する #defstruct を先に定義(下記に同梱)。
#defstruct global DDSCAPS
    #field int dwCaps
#endstruct

#defstruct global DDSCAPS2
    #field int dwCaps
    #field int dwCaps2
    #field int dwCaps3
    #field byte Anonymous 4
#endstruct

#defstruct global DDCAPS_DX6
    #field int dwSize
    #field int dwCaps
    #field int dwCaps2
    #field int dwCKeyCaps
    #field int dwFXCaps
    #field int dwFXAlphaCaps
    #field int dwPalCaps
    #field int dwSVCaps
    #field int dwAlphaBltConstBitDepths
    #field int dwAlphaBltPixelBitDepths
    #field int dwAlphaBltSurfaceBitDepths
    #field int dwAlphaOverlayConstBitDepths
    #field int dwAlphaOverlayPixelBitDepths
    #field int dwAlphaOverlaySurfaceBitDepths
    #field int dwZBufferBitDepths
    #field int dwVidMemTotal
    #field int dwVidMemFree
    #field int dwMaxVisibleOverlays
    #field int dwCurrVisibleOverlays
    #field int dwNumFourCCCodes
    #field int dwAlignBoundarySrc
    #field int dwAlignSizeSrc
    #field int dwAlignBoundaryDest
    #field int dwAlignSizeDest
    #field int dwAlignStrideAlign
    #field int dwRops 8
    #field DDSCAPS ddsOldCaps
    #field int dwMinOverlayStretch
    #field int dwMaxOverlayStretch
    #field int dwMinLiveVideoStretch
    #field int dwMaxLiveVideoStretch
    #field int dwMinHwCodecStretch
    #field int dwMaxHwCodecStretch
    #field int dwReserved1
    #field int dwReserved2
    #field int dwReserved3
    #field int dwSVBCaps
    #field int dwSVBCKeyCaps
    #field int dwSVBFXCaps
    #field int dwSVBRops 8
    #field int dwVSBCaps
    #field int dwVSBCKeyCaps
    #field int dwVSBFXCaps
    #field int dwVSBRops 8
    #field int dwSSBCaps
    #field int dwSSBCKeyCaps
    #field int dwSSBFXCaps
    #field int dwSSBRops 8
    #field int dwMaxVideoPorts
    #field int dwCurrVideoPorts
    #field int dwSVBCaps2
    #field int dwNLVBCaps
    #field int dwNLVBCaps2
    #field int dwNLVBCKeyCaps
    #field int dwNLVBFXCaps
    #field int dwNLVBRops 8
    #field DDSCAPS2 ddsCaps
#endstruct

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