ホーム › Graphics.DirectDraw › DDCAPS_DX3
DDCAPS_DX3
構造体サイズ=各フィールドのバイト数(x64/x86 で異なる場合は x64/x86 と併記)。x64/x86 列=フィールドのバイトオフセット(HSPで dupptr / lpoke / wpoke 等に使用)。
フィールド
| フィールド | 型 | サイズ | x64 | x86 | 説明 |
|---|---|---|---|---|---|
| dwSize | DWORD | 4 | +0 | +0 | 構造体サイズ(バイト数)。呼び出し前に設定する。 |
| dwCaps | DWORD | 4 | +4 | +4 | ドライバの一般能力を示すDDCAPS_系フラグ。 |
| dwCaps2 | DWORD | 4 | +8 | +8 | ドライバの追加能力フラグ(その2)を示す。 |
| dwCKeyCaps | DWORD | 4 | +12 | +12 | カラーキー機能の対応状況を示すフラグ。 |
| dwFXCaps | DWORD | 4 | +16 | +16 | Bltの拡張効果の対応フラグを示す。 |
| dwFXAlphaCaps | DWORD | 4 | +20 | +20 | アルファ関連効果の対応状況を示すフラグ。 |
| dwPalCaps | DWORD | 4 | +24 | +24 | パレット機能の対応状況を示すフラグ。 |
| dwSVCaps | DWORD | 4 | +28 | +28 | ステレオビジョンの対応状況を示すフラグ。 |
| dwAlphaBltConstBitDepths | DWORD | 4 | +32 | +32 | Blt定数アルファの対応ビット深度を示す。 |
| dwAlphaBltPixelBitDepths | DWORD | 4 | +36 | +36 | Bltピクセルアルファの対応ビット深度を示す。 |
| dwAlphaBltSurfaceBitDepths | DWORD | 4 | +40 | +40 | Bltサーフェスアルファの対応ビット深度を示す。 |
| dwAlphaOverlayConstBitDepths | DWORD | 4 | +44 | +44 | オーバーレイ定数アルファの対応ビット深度を示す。 |
| dwAlphaOverlayPixelBitDepths | DWORD | 4 | +48 | +48 | オーバーレイピクセルアルファの対応ビット深度を示す。 |
| dwAlphaOverlaySurfaceBitDepths | DWORD | 4 | +52 | +52 | オーバーレイサーフェスアルファの対応ビット深度を示す。 |
| dwZBufferBitDepths | DWORD | 4 | +56 | +56 | Zバッファの対応ビット深度を示す。 |
| dwVidMemTotal | DWORD | 4 | +60 | +60 | ビデオメモリの総容量(バイト)を示す。 |
| dwVidMemFree | DWORD | 4 | +64 | +64 | 空きビデオメモリ容量(バイト)を示す。 |
| dwMaxVisibleOverlays | DWORD | 4 | +68 | +68 | 同時表示可能なオーバーレイの最大数を示す。 |
| dwCurrVisibleOverlays | DWORD | 4 | +72 | +72 | 現在表示中のオーバーレイ数を示す。 |
| dwNumFourCCCodes | DWORD | 4 | +76 | +76 | 対応するFourCCコードの数を示す。 |
| dwAlignBoundarySrc | DWORD | 4 | +80 | +80 | 転送元矩形の境界アライメント要件を示す。 |
| dwAlignSizeSrc | DWORD | 4 | +84 | +84 | 転送元矩形のサイズアライメント要件を示す。 |
| dwAlignBoundaryDest | DWORD | 4 | +88 | +88 | 転送先矩形の境界アライメント要件を示す。 |
| dwAlignSizeDest | DWORD | 4 | +92 | +92 | 転送先矩形のサイズアライメント要件を示す。 |
| dwAlignStrideAlign | DWORD | 4 | +96 | +96 | サーフェスストライドのアライメント要件を示す。 |
| dwRops | DWORD | 32 | +100 | +100 | 対応ROPを表すビット集合(配列)を示す。 |
| ddsCaps | DDSCAPS | 4 | +132 | +132 | ドライバがサポートするサーフェス能力(DDSCAPS)。 |
| dwMinOverlayStretch | DWORD | 4 | +136 | +136 | オーバーレイ最小拡大率を1000倍値で示す。 |
| dwMaxOverlayStretch | DWORD | 4 | +140 | +140 | オーバーレイ最大拡大率を1000倍値で示す。 |
| dwMinLiveVideoStretch | DWORD | 4 | +144 | +144 | ライブ映像の最小拡大率(廃止)を示す。 |
| dwMaxLiveVideoStretch | DWORD | 4 | +148 | +148 | ライブ映像の最大拡大率(廃止)を示す。 |
| dwMinHwCodecStretch | DWORD | 4 | +152 | +152 | ハードウェアコーデックの最小拡大率(廃止)を示す。 |
| dwMaxHwCodecStretch | DWORD | 4 | +156 | +156 | ハードウェアコーデックの最大拡大率(廃止)を示す。 |
| dwReserved1 | DWORD | 4 | +160 | +160 | 予約フィールド。0とする。 |
| dwReserved2 | DWORD | 4 | +164 | +164 | 予約フィールド。0とする。 |
| dwReserved3 | DWORD | 4 | +168 | +168 | 予約フィールド。0とする。 |
| dwSVBCaps | DWORD | 4 | +172 | +172 | システム→ビデオメモリBltの対応能力フラグを示す。 |
| dwSVBCKeyCaps | DWORD | 4 | +176 | +176 | システム→ビデオBltのカラーキー対応フラグを示す。 |
| dwSVBFXCaps | DWORD | 4 | +180 | +180 | システム→ビデオBltの効果対応フラグを示す。 |
| dwSVBRops | DWORD | 32 | +184 | +184 | システム→ビデオBltで対応するROP集合を示す。 |
| dwVSBCaps | DWORD | 4 | +216 | +216 | ビデオ→システムメモリBltの対応能力フラグを示す。 |
| dwVSBCKeyCaps | DWORD | 4 | +220 | +220 | ビデオ→システムBltのカラーキー対応フラグを示す。 |
| dwVSBFXCaps | DWORD | 4 | +224 | +224 | ビデオ→システムBltの効果対応フラグを示す。 |
| dwVSBRops | DWORD | 32 | +228 | +228 | ビデオ→システムBltで対応するROP集合を示す。 |
| dwSSBCaps | DWORD | 4 | +260 | +260 | システム→システムメモリBltの対応能力フラグを示す。 |
| dwSSBCKeyCaps | DWORD | 4 | +264 | +264 | システム→システムBltのカラーキー対応フラグを示す。 |
| dwSSBFXCaps | DWORD | 4 | +268 | +268 | システム→システムBltの効果対応フラグを示す。 |
| dwSSBRops | DWORD | 32 | +272 | +272 | システム→システムBltで対応するROP集合を示す。 |
| dwReserved4 | DWORD | 4 | +304 | +304 | 予約フィールド。0とする。 |
| dwReserved5 | DWORD | 4 | +308 | +308 | 予約フィールド。0とする。 |
| dwReserved6 | DWORD | 4 | +312 | +312 | 予約フィールド。0とする。 |
各言語での定義
#include <windows.h>
// DDSCAPS (x64 4 / x86 4 バイト)
typedef struct DDSCAPS {
DWORD dwCaps;
} DDSCAPS;
// DDCAPS_DX3 (x64 316 / x86 316 バイト)
typedef struct DDCAPS_DX3 {
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 ddsCaps;
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 dwReserved4;
DWORD dwReserved5;
DWORD dwReserved6;
} DDCAPS_DX3;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 DDCAPS_DX3
{
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 ddsCaps;
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 dwReserved4;
public uint dwReserved5;
public uint dwReserved6;
}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 DDCAPS_DX3
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 ddsCaps 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 dwReserved4 As UInteger
Public dwReserved5 As UInteger
Public dwReserved6 As UInteger
End Structureimport ctypes
from ctypes import wintypes
class DDSCAPS(ctypes.Structure):
_fields_ = [
("dwCaps", wintypes.DWORD),
]
class DDCAPS_DX3(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),
("ddsCaps", 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),
("dwReserved4", wintypes.DWORD),
("dwReserved5", wintypes.DWORD),
("dwReserved6", wintypes.DWORD),
]#[repr(C)]
pub struct DDSCAPS {
pub dwCaps: u32,
}
#[repr(C)]
pub struct DDCAPS_DX3 {
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 ddsCaps: 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 dwReserved4: u32,
pub dwReserved5: u32,
pub dwReserved6: u32,
}import "golang.org/x/sys/windows"
type DDSCAPS struct {
dwCaps uint32
}
type DDCAPS_DX3 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
ddsCaps 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
dwReserved4 uint32
dwReserved5 uint32
dwReserved6 uint32
}type
DDSCAPS = record
dwCaps: DWORD;
end;
DDCAPS_DX3 = 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;
ddsCaps: 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;
dwReserved4: DWORD;
dwReserved5: DWORD;
dwReserved6: DWORD;
end;const DDSCAPS = extern struct {
dwCaps: u32,
};
const DDCAPS_DX3 = 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,
ddsCaps: 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,
dwReserved4: u32,
dwReserved5: u32,
dwReserved6: u32,
};type
DDSCAPS {.bycopy.} = object
dwCaps: uint32
DDCAPS_DX3 {.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]
ddsCaps: 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]
dwReserved4: uint32
dwReserved5: uint32
dwReserved6: uint32struct DDSCAPS
{
uint dwCaps;
}
struct DDCAPS_DX3
{
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 ddsCaps;
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 dwReserved4;
uint dwReserved5;
uint dwReserved6;
}HSP用 定義
HSP3.7/3.8 は構造体機能が無いため4byte整数配列(dim)+peek/poke で操作(32/64bitでサイズ・位置が異なる場合はタブで分割)。IronHSP は NSTRUCT(#defstruct/stdim/->)で32/64bit共通。
; HSP3.7/3.8 は構造体機能が無いため、4byte整数の配列変数で操作します。(x64 レイアウト)
; DDCAPS_DX3 サイズ: 316 バイト(x64)
dim st, 79 ; 4byte整数×79(構造体サイズ 316 / 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:入れ子/配列)
; ddsCaps : 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:入れ子/配列)
; dwReserved4 : DWORD (+304, 4byte) st.76 = 値 / 値 = st.76 (lpoke/lpeek も可)
; dwReserved5 : DWORD (+308, 4byte) st.77 = 値 / 値 = st.77 (lpoke/lpeek も可)
; dwReserved6 : DWORD (+312, 4byte) st.78 = 値 / 値 = st.78 (lpoke/lpeek も可)
; ※4byte境界の整数は添字 st.N(N=オフセット/4)で読み書き可。それ以外は peek/poke 系を使用。; IronHSP は NSTRUCT(構造体)をサポート。32bit/64bit どちらでも同じコードで動作します。
; ※GUID・入れ子構造体はデフォルト型でないため、依存する #defstruct を先に定義(下記に同梱)。
#defstruct global DDSCAPS
#field int dwCaps
#endstruct
#defstruct global DDCAPS_DX3
#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 ddsCaps
#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 dwReserved4
#field int dwReserved5
#field int dwReserved6
#endstruct
stdim st, DDCAPS_DX3 ; NSTRUCT 変数を確保
st->dwSize = 100
mes "dwSize=" + st->dwSize