d3d9caps.h 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567
  1. /*==========================================================================;
  2. *
  3. * Copyright (C) Microsoft Corporation. All Rights Reserved.
  4. *
  5. * File: d3d9caps.h
  6. * Content: Direct3D capabilities include file
  7. *
  8. ***************************************************************************/
  9. #ifndef _d3d9CAPS_H
  10. #define _d3d9CAPS_H
  11. #ifndef DIRECT3D_VERSION
  12. #define DIRECT3D_VERSION 0x0900
  13. #endif //DIRECT3D_VERSION
  14. // include this file content only if compiling for DX9 interfaces
  15. #if(DIRECT3D_VERSION >= 0x0900)
  16. #if defined(_X86_) || defined(_IA64_)
  17. #pragma pack(4)
  18. #endif
  19. typedef struct _D3DVSHADERCAPS2_0
  20. {
  21. DWORD Caps;
  22. INT DynamicFlowControlDepth;
  23. INT NumTemps;
  24. INT StaticFlowControlDepth;
  25. } D3DVSHADERCAPS2_0;
  26. #define D3DVS20CAPS_PREDICATION (1<<0)
  27. #define D3DVS20_MAX_DYNAMICFLOWCONTROLDEPTH 24
  28. #define D3DVS20_MIN_DYNAMICFLOWCONTROLDEPTH 0
  29. #define D3DVS20_MAX_NUMTEMPS 32
  30. #define D3DVS20_MIN_NUMTEMPS 12
  31. #define D3DVS20_MAX_STATICFLOWCONTROLDEPTH 4
  32. #define D3DVS20_MIN_STATICFLOWCONTROLDEPTH 1
  33. typedef struct _D3DPSHADERCAPS2_0
  34. {
  35. DWORD Caps;
  36. INT DynamicFlowControlDepth;
  37. INT NumTemps;
  38. INT StaticFlowControlDepth;
  39. INT NumInstructionSlots;
  40. } D3DPSHADERCAPS2_0;
  41. #define D3DPS20CAPS_ARBITRARYSWIZZLE (1<<0)
  42. #define D3DPS20CAPS_GRADIENTINSTRUCTIONS (1<<1)
  43. #define D3DPS20CAPS_PREDICATION (1<<2)
  44. #define D3DPS20CAPS_NODEPENDENTREADLIMIT (1<<3)
  45. #define D3DPS20CAPS_NOTEXINSTRUCTIONLIMIT (1<<4)
  46. #define D3DPS20_MAX_DYNAMICFLOWCONTROLDEPTH 24
  47. #define D3DPS20_MIN_DYNAMICFLOWCONTROLDEPTH 0
  48. #define D3DPS20_MAX_NUMTEMPS 32
  49. #define D3DPS20_MIN_NUMTEMPS 12
  50. #define D3DPS20_MAX_STATICFLOWCONTROLDEPTH 4
  51. #define D3DPS20_MIN_STATICFLOWCONTROLDEPTH 0
  52. #define D3DPS20_MAX_NUMINSTRUCTIONSLOTS 512
  53. #define D3DPS20_MIN_NUMINSTRUCTIONSLOTS 96
  54. #define D3DMIN30SHADERINSTRUCTIONS 512
  55. #define D3DMAX30SHADERINSTRUCTIONS 32768
  56. /* D3D9Ex only -- */
  57. #if !defined(D3D_DISABLE_9EX)
  58. typedef struct _D3DOVERLAYCAPS
  59. {
  60. UINT Caps;
  61. UINT MaxOverlayDisplayWidth;
  62. UINT MaxOverlayDisplayHeight;
  63. } D3DOVERLAYCAPS;
  64. #define D3DOVERLAYCAPS_FULLRANGERGB 0x00000001
  65. #define D3DOVERLAYCAPS_LIMITEDRANGERGB 0x00000002
  66. #define D3DOVERLAYCAPS_YCbCr_BT601 0x00000004
  67. #define D3DOVERLAYCAPS_YCbCr_BT709 0x00000008
  68. #define D3DOVERLAYCAPS_YCbCr_BT601_xvYCC 0x00000010
  69. #define D3DOVERLAYCAPS_YCbCr_BT709_xvYCC 0x00000020
  70. #define D3DOVERLAYCAPS_STRETCHX 0x00000040
  71. #define D3DOVERLAYCAPS_STRETCHY 0x00000080
  72. typedef struct _D3DCONTENTPROTECTIONCAPS
  73. {
  74. DWORD Caps;
  75. GUID KeyExchangeType;
  76. UINT BufferAlignmentStart;
  77. UINT BlockAlignmentSize;
  78. ULONGLONG ProtectedMemorySize;
  79. } D3DCONTENTPROTECTIONCAPS;
  80. #define D3DCPCAPS_SOFTWARE 0x00000001
  81. #define D3DCPCAPS_HARDWARE 0x00000002
  82. #define D3DCPCAPS_PROTECTIONALWAYSON 0x00000004
  83. #define D3DCPCAPS_PARTIALDECRYPTION 0x00000008
  84. #define D3DCPCAPS_CONTENTKEY 0x00000010
  85. #define D3DCPCAPS_FRESHENSESSIONKEY 0x00000020
  86. #define D3DCPCAPS_ENCRYPTEDREADBACK 0x00000040
  87. #define D3DCPCAPS_ENCRYPTEDREADBACKKEY 0x00000080
  88. #define D3DCPCAPS_SEQUENTIAL_CTR_IV 0x00000100
  89. #define D3DCPCAPS_ENCRYPTSLICEDATAONLY 0x00000200
  90. DEFINE_GUID(D3DCRYPTOTYPE_AES128_CTR,
  91. 0x9b6bd711, 0x4f74, 0x41c9, 0x9e, 0x7b, 0xb, 0xe2, 0xd7, 0xd9, 0x3b, 0x4f);
  92. DEFINE_GUID(D3DCRYPTOTYPE_PROPRIETARY,
  93. 0xab4e9afd, 0x1d1c, 0x46e6, 0xa7, 0x2f, 0x8, 0x69, 0x91, 0x7b, 0xd, 0xe8);
  94. DEFINE_GUID(D3DKEYEXCHANGE_RSAES_OAEP,
  95. 0xc1949895, 0xd72a, 0x4a1d, 0x8e, 0x5d, 0xed, 0x85, 0x7d, 0x17, 0x15, 0x20);
  96. DEFINE_GUID(D3DKEYEXCHANGE_DXVA,
  97. 0x43d3775c, 0x38e5, 0x4924, 0x8d, 0x86, 0xd3, 0xfc, 0xcf, 0x15, 0x3e, 0x9b);
  98. #endif // !D3D_DISABLE_9EX
  99. /* -- D3D9Ex only */
  100. typedef struct _D3DCAPS9
  101. {
  102. /* Device Info */
  103. D3DDEVTYPE DeviceType;
  104. UINT AdapterOrdinal;
  105. /* Caps from DX7 Draw */
  106. DWORD Caps;
  107. DWORD Caps2;
  108. DWORD Caps3;
  109. DWORD PresentationIntervals;
  110. /* Cursor Caps */
  111. DWORD CursorCaps;
  112. /* 3D Device Caps */
  113. DWORD DevCaps;
  114. DWORD PrimitiveMiscCaps;
  115. DWORD RasterCaps;
  116. DWORD ZCmpCaps;
  117. DWORD SrcBlendCaps;
  118. DWORD DestBlendCaps;
  119. DWORD AlphaCmpCaps;
  120. DWORD ShadeCaps;
  121. DWORD TextureCaps;
  122. DWORD TextureFilterCaps; // D3DPTFILTERCAPS for IDirect3DTexture9's
  123. DWORD CubeTextureFilterCaps; // D3DPTFILTERCAPS for IDirect3DCubeTexture9's
  124. DWORD VolumeTextureFilterCaps; // D3DPTFILTERCAPS for IDirect3DVolumeTexture9's
  125. DWORD TextureAddressCaps; // D3DPTADDRESSCAPS for IDirect3DTexture9's
  126. DWORD VolumeTextureAddressCaps; // D3DPTADDRESSCAPS for IDirect3DVolumeTexture9's
  127. DWORD LineCaps; // D3DLINECAPS
  128. DWORD MaxTextureWidth, MaxTextureHeight;
  129. DWORD MaxVolumeExtent;
  130. DWORD MaxTextureRepeat;
  131. DWORD MaxTextureAspectRatio;
  132. DWORD MaxAnisotropy;
  133. float MaxVertexW;
  134. float GuardBandLeft;
  135. float GuardBandTop;
  136. float GuardBandRight;
  137. float GuardBandBottom;
  138. float ExtentsAdjust;
  139. DWORD StencilCaps;
  140. DWORD FVFCaps;
  141. DWORD TextureOpCaps;
  142. DWORD MaxTextureBlendStages;
  143. DWORD MaxSimultaneousTextures;
  144. DWORD VertexProcessingCaps;
  145. DWORD MaxActiveLights;
  146. DWORD MaxUserClipPlanes;
  147. DWORD MaxVertexBlendMatrices;
  148. DWORD MaxVertexBlendMatrixIndex;
  149. float MaxPointSize;
  150. DWORD MaxPrimitiveCount; // max number of primitives per DrawPrimitive call
  151. DWORD MaxVertexIndex;
  152. DWORD MaxStreams;
  153. DWORD MaxStreamStride; // max stride for SetStreamSource
  154. DWORD VertexShaderVersion;
  155. DWORD MaxVertexShaderConst; // number of vertex shader constant registers
  156. DWORD PixelShaderVersion;
  157. float PixelShader1xMaxValue; // max value storable in registers of ps.1.x shaders
  158. // Here are the DX9 specific ones
  159. DWORD DevCaps2;
  160. float MaxNpatchTessellationLevel;
  161. DWORD Reserved5;
  162. UINT MasterAdapterOrdinal; // ordinal of master adaptor for adapter group
  163. UINT AdapterOrdinalInGroup; // ordinal inside the adapter group
  164. UINT NumberOfAdaptersInGroup; // number of adapters in this adapter group (only if master)
  165. DWORD DeclTypes; // Data types, supported in vertex declarations
  166. DWORD NumSimultaneousRTs; // Will be at least 1
  167. DWORD StretchRectFilterCaps; // Filter caps supported by StretchRect
  168. D3DVSHADERCAPS2_0 VS20Caps;
  169. D3DPSHADERCAPS2_0 PS20Caps;
  170. DWORD VertexTextureFilterCaps; // D3DPTFILTERCAPS for IDirect3DTexture9's for texture, used in vertex shaders
  171. DWORD MaxVShaderInstructionsExecuted; // maximum number of vertex shader instructions that can be executed
  172. DWORD MaxPShaderInstructionsExecuted; // maximum number of pixel shader instructions that can be executed
  173. DWORD MaxVertexShader30InstructionSlots;
  174. DWORD MaxPixelShader30InstructionSlots;
  175. } D3DCAPS9;
  176. //
  177. // BIT DEFINES FOR D3DCAPS9 DWORD MEMBERS
  178. //
  179. //
  180. // Caps
  181. //
  182. #define D3DCAPS_OVERLAY 0x00000800L
  183. #define D3DCAPS_READ_SCANLINE 0x00020000L
  184. //
  185. // Caps2
  186. //
  187. #define D3DCAPS2_FULLSCREENGAMMA 0x00020000L
  188. #define D3DCAPS2_CANCALIBRATEGAMMA 0x00100000L
  189. #define D3DCAPS2_RESERVED 0x02000000L
  190. #define D3DCAPS2_CANMANAGERESOURCE 0x10000000L
  191. #define D3DCAPS2_DYNAMICTEXTURES 0x20000000L
  192. #define D3DCAPS2_CANAUTOGENMIPMAP 0x40000000L
  193. /* D3D9Ex only -- */
  194. #if !defined(D3D_DISABLE_9EX)
  195. #define D3DCAPS2_CANSHARERESOURCE 0x80000000L
  196. #endif // !D3D_DISABLE_9EX
  197. /* -- D3D9Ex only */
  198. //
  199. // Caps3
  200. //
  201. #define D3DCAPS3_RESERVED 0x8000001fL
  202. // Indicates that the device can respect the ALPHABLENDENABLE render state
  203. // when fullscreen while using the FLIP or DISCARD swap effect.
  204. // COPY and COPYVSYNC swap effects work whether or not this flag is set.
  205. #define D3DCAPS3_ALPHA_FULLSCREEN_FLIP_OR_DISCARD 0x00000020L
  206. // Indicates that the device can perform a gamma correction from
  207. // a windowed back buffer containing linear content to the sRGB desktop.
  208. #define D3DCAPS3_LINEAR_TO_SRGB_PRESENTATION 0x00000080L
  209. #define D3DCAPS3_COPY_TO_VIDMEM 0x00000100L /* Device can acclerate copies from sysmem to local vidmem */
  210. #define D3DCAPS3_COPY_TO_SYSTEMMEM 0x00000200L /* Device can acclerate copies from local vidmem to sysmem */
  211. #define D3DCAPS3_DXVAHD 0x00000400L
  212. //
  213. // PresentationIntervals
  214. //
  215. #define D3DPRESENT_INTERVAL_DEFAULT 0x00000000L
  216. #define D3DPRESENT_INTERVAL_ONE 0x00000001L
  217. #define D3DPRESENT_INTERVAL_TWO 0x00000002L
  218. #define D3DPRESENT_INTERVAL_THREE 0x00000004L
  219. #define D3DPRESENT_INTERVAL_FOUR 0x00000008L
  220. #define D3DPRESENT_INTERVAL_IMMEDIATE 0x80000000L
  221. //
  222. // CursorCaps
  223. //
  224. // Driver supports HW color cursor in at least hi-res modes(height >=400)
  225. #define D3DCURSORCAPS_COLOR 0x00000001L
  226. // Driver supports HW cursor also in low-res modes(height < 400)
  227. #define D3DCURSORCAPS_LOWRES 0x00000002L
  228. //
  229. // DevCaps
  230. //
  231. #define D3DDEVCAPS_EXECUTESYSTEMMEMORY 0x00000010L /* Device can use execute buffers from system memory */
  232. #define D3DDEVCAPS_EXECUTEVIDEOMEMORY 0x00000020L /* Device can use execute buffers from video memory */
  233. #define D3DDEVCAPS_TLVERTEXSYSTEMMEMORY 0x00000040L /* Device can use TL buffers from system memory */
  234. #define D3DDEVCAPS_TLVERTEXVIDEOMEMORY 0x00000080L /* Device can use TL buffers from video memory */
  235. #define D3DDEVCAPS_TEXTURESYSTEMMEMORY 0x00000100L /* Device can texture from system memory */
  236. #define D3DDEVCAPS_TEXTUREVIDEOMEMORY 0x00000200L /* Device can texture from device memory */
  237. #define D3DDEVCAPS_DRAWPRIMTLVERTEX 0x00000400L /* Device can draw TLVERTEX primitives */
  238. #define D3DDEVCAPS_CANRENDERAFTERFLIP 0x00000800L /* Device can render without waiting for flip to complete */
  239. #define D3DDEVCAPS_TEXTURENONLOCALVIDMEM 0x00001000L /* Device can texture from nonlocal video memory */
  240. #define D3DDEVCAPS_DRAWPRIMITIVES2 0x00002000L /* Device can support DrawPrimitives2 */
  241. #define D3DDEVCAPS_SEPARATETEXTUREMEMORIES 0x00004000L /* Device is texturing from separate memory pools */
  242. #define D3DDEVCAPS_DRAWPRIMITIVES2EX 0x00008000L /* Device can support Extended DrawPrimitives2 i.e. DX7 compliant driver*/
  243. #define D3DDEVCAPS_HWTRANSFORMANDLIGHT 0x00010000L /* Device can support transformation and lighting in hardware and DRAWPRIMITIVES2EX must be also */
  244. #define D3DDEVCAPS_CANBLTSYSTONONLOCAL 0x00020000L /* Device supports a Tex Blt from system memory to non-local vidmem */
  245. #define D3DDEVCAPS_HWRASTERIZATION 0x00080000L /* Device has HW acceleration for rasterization */
  246. #define D3DDEVCAPS_PUREDEVICE 0x00100000L /* Device supports D3DCREATE_PUREDEVICE */
  247. #define D3DDEVCAPS_QUINTICRTPATCHES 0x00200000L /* Device supports quintic Beziers and BSplines */
  248. #define D3DDEVCAPS_RTPATCHES 0x00400000L /* Device supports Rect and Tri patches */
  249. #define D3DDEVCAPS_RTPATCHHANDLEZERO 0x00800000L /* Indicates that RT Patches may be drawn efficiently using handle 0 */
  250. #define D3DDEVCAPS_NPATCHES 0x01000000L /* Device supports N-Patches */
  251. //
  252. // PrimitiveMiscCaps
  253. //
  254. #define D3DPMISCCAPS_MASKZ 0x00000002L
  255. #define D3DPMISCCAPS_CULLNONE 0x00000010L
  256. #define D3DPMISCCAPS_CULLCW 0x00000020L
  257. #define D3DPMISCCAPS_CULLCCW 0x00000040L
  258. #define D3DPMISCCAPS_COLORWRITEENABLE 0x00000080L
  259. #define D3DPMISCCAPS_CLIPPLANESCALEDPOINTS 0x00000100L /* Device correctly clips scaled points to clip planes */
  260. #define D3DPMISCCAPS_CLIPTLVERTS 0x00000200L /* device will clip post-transformed vertex primitives */
  261. #define D3DPMISCCAPS_TSSARGTEMP 0x00000400L /* device supports D3DTA_TEMP for temporary register */
  262. #define D3DPMISCCAPS_BLENDOP 0x00000800L /* device supports D3DRS_BLENDOP */
  263. #define D3DPMISCCAPS_NULLREFERENCE 0x00001000L /* Reference Device that doesnt render */
  264. #define D3DPMISCCAPS_INDEPENDENTWRITEMASKS 0x00004000L /* Device supports independent write masks for MET or MRT */
  265. #define D3DPMISCCAPS_PERSTAGECONSTANT 0x00008000L /* Device supports per-stage constants */
  266. #define D3DPMISCCAPS_FOGANDSPECULARALPHA 0x00010000L /* Device supports separate fog and specular alpha (many devices
  267. use the specular alpha channel to store fog factor) */
  268. #define D3DPMISCCAPS_SEPARATEALPHABLEND 0x00020000L /* Device supports separate blend settings for the alpha channel */
  269. #define D3DPMISCCAPS_MRTINDEPENDENTBITDEPTHS 0x00040000L /* Device supports different bit depths for MRT */
  270. #define D3DPMISCCAPS_MRTPOSTPIXELSHADERBLENDING 0x00080000L /* Device supports post-pixel shader operations for MRT */
  271. #define D3DPMISCCAPS_FOGVERTEXCLAMPED 0x00100000L /* Device clamps fog blend factor per vertex */
  272. /* D3D9Ex only -- */
  273. #if !defined(D3D_DISABLE_9EX)
  274. #define D3DPMISCCAPS_POSTBLENDSRGBCONVERT 0x00200000L /* Indicates device can perform conversion to sRGB after blending. */
  275. #endif // !D3D_DISABLE_9EX
  276. /* -- D3D9Ex only */
  277. //
  278. // LineCaps
  279. //
  280. #define D3DLINECAPS_TEXTURE 0x00000001L
  281. #define D3DLINECAPS_ZTEST 0x00000002L
  282. #define D3DLINECAPS_BLEND 0x00000004L
  283. #define D3DLINECAPS_ALPHACMP 0x00000008L
  284. #define D3DLINECAPS_FOG 0x00000010L
  285. #define D3DLINECAPS_ANTIALIAS 0x00000020L
  286. //
  287. // RasterCaps
  288. //
  289. #define D3DPRASTERCAPS_DITHER 0x00000001L
  290. #define D3DPRASTERCAPS_ZTEST 0x00000010L
  291. #define D3DPRASTERCAPS_FOGVERTEX 0x00000080L
  292. #define D3DPRASTERCAPS_FOGTABLE 0x00000100L
  293. #define D3DPRASTERCAPS_MIPMAPLODBIAS 0x00002000L
  294. #define D3DPRASTERCAPS_ZBUFFERLESSHSR 0x00008000L
  295. #define D3DPRASTERCAPS_FOGRANGE 0x00010000L
  296. #define D3DPRASTERCAPS_ANISOTROPY 0x00020000L
  297. #define D3DPRASTERCAPS_WBUFFER 0x00040000L
  298. #define D3DPRASTERCAPS_WFOG 0x00100000L
  299. #define D3DPRASTERCAPS_ZFOG 0x00200000L
  300. #define D3DPRASTERCAPS_COLORPERSPECTIVE 0x00400000L /* Device iterates colors perspective correct */
  301. #define D3DPRASTERCAPS_SCISSORTEST 0x01000000L
  302. #define D3DPRASTERCAPS_SLOPESCALEDEPTHBIAS 0x02000000L
  303. #define D3DPRASTERCAPS_DEPTHBIAS 0x04000000L
  304. #define D3DPRASTERCAPS_MULTISAMPLE_TOGGLE 0x08000000L
  305. //
  306. // ZCmpCaps, AlphaCmpCaps
  307. //
  308. #define D3DPCMPCAPS_NEVER 0x00000001L
  309. #define D3DPCMPCAPS_LESS 0x00000002L
  310. #define D3DPCMPCAPS_EQUAL 0x00000004L
  311. #define D3DPCMPCAPS_LESSEQUAL 0x00000008L
  312. #define D3DPCMPCAPS_GREATER 0x00000010L
  313. #define D3DPCMPCAPS_NOTEQUAL 0x00000020L
  314. #define D3DPCMPCAPS_GREATEREQUAL 0x00000040L
  315. #define D3DPCMPCAPS_ALWAYS 0x00000080L
  316. //
  317. // SourceBlendCaps, DestBlendCaps
  318. //
  319. #define D3DPBLENDCAPS_ZERO 0x00000001L
  320. #define D3DPBLENDCAPS_ONE 0x00000002L
  321. #define D3DPBLENDCAPS_SRCCOLOR 0x00000004L
  322. #define D3DPBLENDCAPS_INVSRCCOLOR 0x00000008L
  323. #define D3DPBLENDCAPS_SRCALPHA 0x00000010L
  324. #define D3DPBLENDCAPS_INVSRCALPHA 0x00000020L
  325. #define D3DPBLENDCAPS_DESTALPHA 0x00000040L
  326. #define D3DPBLENDCAPS_INVDESTALPHA 0x00000080L
  327. #define D3DPBLENDCAPS_DESTCOLOR 0x00000100L
  328. #define D3DPBLENDCAPS_INVDESTCOLOR 0x00000200L
  329. #define D3DPBLENDCAPS_SRCALPHASAT 0x00000400L
  330. #define D3DPBLENDCAPS_BOTHSRCALPHA 0x00000800L
  331. #define D3DPBLENDCAPS_BOTHINVSRCALPHA 0x00001000L
  332. #define D3DPBLENDCAPS_BLENDFACTOR 0x00002000L /* Supports both D3DBLEND_BLENDFACTOR and D3DBLEND_INVBLENDFACTOR */
  333. /* D3D9Ex only -- */
  334. #if !defined(D3D_DISABLE_9EX)
  335. #define D3DPBLENDCAPS_SRCCOLOR2 0x00004000L
  336. #define D3DPBLENDCAPS_INVSRCCOLOR2 0x00008000L
  337. #endif // !D3D_DISABLE_9EX
  338. /* -- D3D9Ex only */
  339. //
  340. // ShadeCaps
  341. //
  342. #define D3DPSHADECAPS_COLORGOURAUDRGB 0x00000008L
  343. #define D3DPSHADECAPS_SPECULARGOURAUDRGB 0x00000200L
  344. #define D3DPSHADECAPS_ALPHAGOURAUDBLEND 0x00004000L
  345. #define D3DPSHADECAPS_FOGGOURAUD 0x00080000L
  346. //
  347. // TextureCaps
  348. //
  349. #define D3DPTEXTURECAPS_PERSPECTIVE 0x00000001L /* Perspective-correct texturing is supported */
  350. #define D3DPTEXTURECAPS_POW2 0x00000002L /* Power-of-2 texture dimensions are required - applies to non-Cube/Volume textures only. */
  351. #define D3DPTEXTURECAPS_ALPHA 0x00000004L /* Alpha in texture pixels is supported */
  352. #define D3DPTEXTURECAPS_SQUAREONLY 0x00000020L /* Only square textures are supported */
  353. #define D3DPTEXTURECAPS_TEXREPEATNOTSCALEDBYSIZE 0x00000040L /* Texture indices are not scaled by the texture size prior to interpolation */
  354. #define D3DPTEXTURECAPS_ALPHAPALETTE 0x00000080L /* Device can draw alpha from texture palettes */
  355. // Device can use non-POW2 textures if:
  356. // 1) D3DTEXTURE_ADDRESS is set to CLAMP for this texture's stage
  357. // 2) D3DRS_WRAP(N) is zero for this texture's coordinates
  358. // 3) mip mapping is not enabled (use magnification filter only)
  359. #define D3DPTEXTURECAPS_NONPOW2CONDITIONAL 0x00000100L
  360. #define D3DPTEXTURECAPS_PROJECTED 0x00000400L /* Device can do D3DTTFF_PROJECTED */
  361. #define D3DPTEXTURECAPS_CUBEMAP 0x00000800L /* Device can do cubemap textures */
  362. #define D3DPTEXTURECAPS_VOLUMEMAP 0x00002000L /* Device can do volume textures */
  363. #define D3DPTEXTURECAPS_MIPMAP 0x00004000L /* Device can do mipmapped textures */
  364. #define D3DPTEXTURECAPS_MIPVOLUMEMAP 0x00008000L /* Device can do mipmapped volume textures */
  365. #define D3DPTEXTURECAPS_MIPCUBEMAP 0x00010000L /* Device can do mipmapped cube maps */
  366. #define D3DPTEXTURECAPS_CUBEMAP_POW2 0x00020000L /* Device requires that cubemaps be power-of-2 dimension */
  367. #define D3DPTEXTURECAPS_VOLUMEMAP_POW2 0x00040000L /* Device requires that volume maps be power-of-2 dimension */
  368. #define D3DPTEXTURECAPS_NOPROJECTEDBUMPENV 0x00200000L /* Device does not support projected bump env lookup operation
  369. in programmable and fixed function pixel shaders */
  370. //
  371. // TextureFilterCaps, StretchRectFilterCaps
  372. //
  373. #define D3DPTFILTERCAPS_MINFPOINT 0x00000100L /* Min Filter */
  374. #define D3DPTFILTERCAPS_MINFLINEAR 0x00000200L
  375. #define D3DPTFILTERCAPS_MINFANISOTROPIC 0x00000400L
  376. #define D3DPTFILTERCAPS_MINFPYRAMIDALQUAD 0x00000800L
  377. #define D3DPTFILTERCAPS_MINFGAUSSIANQUAD 0x00001000L
  378. #define D3DPTFILTERCAPS_MIPFPOINT 0x00010000L /* Mip Filter */
  379. #define D3DPTFILTERCAPS_MIPFLINEAR 0x00020000L
  380. /* D3D9Ex only -- */
  381. #if !defined(D3D_DISABLE_9EX)
  382. #define D3DPTFILTERCAPS_CONVOLUTIONMONO 0x00040000L /* Min and Mag for the convolution mono filter */
  383. #endif // !D3D_DISABLE_9EX
  384. /* -- D3D9Ex only */
  385. #define D3DPTFILTERCAPS_MAGFPOINT 0x01000000L /* Mag Filter */
  386. #define D3DPTFILTERCAPS_MAGFLINEAR 0x02000000L
  387. #define D3DPTFILTERCAPS_MAGFANISOTROPIC 0x04000000L
  388. #define D3DPTFILTERCAPS_MAGFPYRAMIDALQUAD 0x08000000L
  389. #define D3DPTFILTERCAPS_MAGFGAUSSIANQUAD 0x10000000L
  390. //
  391. // TextureAddressCaps
  392. //
  393. #define D3DPTADDRESSCAPS_WRAP 0x00000001L
  394. #define D3DPTADDRESSCAPS_MIRROR 0x00000002L
  395. #define D3DPTADDRESSCAPS_CLAMP 0x00000004L
  396. #define D3DPTADDRESSCAPS_BORDER 0x00000008L
  397. #define D3DPTADDRESSCAPS_INDEPENDENTUV 0x00000010L
  398. #define D3DPTADDRESSCAPS_MIRRORONCE 0x00000020L
  399. //
  400. // StencilCaps
  401. //
  402. #define D3DSTENCILCAPS_KEEP 0x00000001L
  403. #define D3DSTENCILCAPS_ZERO 0x00000002L
  404. #define D3DSTENCILCAPS_REPLACE 0x00000004L
  405. #define D3DSTENCILCAPS_INCRSAT 0x00000008L
  406. #define D3DSTENCILCAPS_DECRSAT 0x00000010L
  407. #define D3DSTENCILCAPS_INVERT 0x00000020L
  408. #define D3DSTENCILCAPS_INCR 0x00000040L
  409. #define D3DSTENCILCAPS_DECR 0x00000080L
  410. #define D3DSTENCILCAPS_TWOSIDED 0x00000100L
  411. //
  412. // TextureOpCaps
  413. //
  414. #define D3DTEXOPCAPS_DISABLE 0x00000001L
  415. #define D3DTEXOPCAPS_SELECTARG1 0x00000002L
  416. #define D3DTEXOPCAPS_SELECTARG2 0x00000004L
  417. #define D3DTEXOPCAPS_MODULATE 0x00000008L
  418. #define D3DTEXOPCAPS_MODULATE2X 0x00000010L
  419. #define D3DTEXOPCAPS_MODULATE4X 0x00000020L
  420. #define D3DTEXOPCAPS_ADD 0x00000040L
  421. #define D3DTEXOPCAPS_ADDSIGNED 0x00000080L
  422. #define D3DTEXOPCAPS_ADDSIGNED2X 0x00000100L
  423. #define D3DTEXOPCAPS_SUBTRACT 0x00000200L
  424. #define D3DTEXOPCAPS_ADDSMOOTH 0x00000400L
  425. #define D3DTEXOPCAPS_BLENDDIFFUSEALPHA 0x00000800L
  426. #define D3DTEXOPCAPS_BLENDTEXTUREALPHA 0x00001000L
  427. #define D3DTEXOPCAPS_BLENDFACTORALPHA 0x00002000L
  428. #define D3DTEXOPCAPS_BLENDTEXTUREALPHAPM 0x00004000L
  429. #define D3DTEXOPCAPS_BLENDCURRENTALPHA 0x00008000L
  430. #define D3DTEXOPCAPS_PREMODULATE 0x00010000L
  431. #define D3DTEXOPCAPS_MODULATEALPHA_ADDCOLOR 0x00020000L
  432. #define D3DTEXOPCAPS_MODULATECOLOR_ADDALPHA 0x00040000L
  433. #define D3DTEXOPCAPS_MODULATEINVALPHA_ADDCOLOR 0x00080000L
  434. #define D3DTEXOPCAPS_MODULATEINVCOLOR_ADDALPHA 0x00100000L
  435. #define D3DTEXOPCAPS_BUMPENVMAP 0x00200000L
  436. #define D3DTEXOPCAPS_BUMPENVMAPLUMINANCE 0x00400000L
  437. #define D3DTEXOPCAPS_DOTPRODUCT3 0x00800000L
  438. #define D3DTEXOPCAPS_MULTIPLYADD 0x01000000L
  439. #define D3DTEXOPCAPS_LERP 0x02000000L
  440. //
  441. // FVFCaps
  442. //
  443. #define D3DFVFCAPS_TEXCOORDCOUNTMASK 0x0000ffffL /* mask for texture coordinate count field */
  444. #define D3DFVFCAPS_DONOTSTRIPELEMENTS 0x00080000L /* Device prefers that vertex elements not be stripped */
  445. #define D3DFVFCAPS_PSIZE 0x00100000L /* Device can receive point size */
  446. //
  447. // VertexProcessingCaps
  448. //
  449. #define D3DVTXPCAPS_TEXGEN 0x00000001L /* device can do texgen */
  450. #define D3DVTXPCAPS_MATERIALSOURCE7 0x00000002L /* device can do DX7-level colormaterialsource ops */
  451. #define D3DVTXPCAPS_DIRECTIONALLIGHTS 0x00000008L /* device can do directional lights */
  452. #define D3DVTXPCAPS_POSITIONALLIGHTS 0x00000010L /* device can do positional lights (includes point and spot) */
  453. #define D3DVTXPCAPS_LOCALVIEWER 0x00000020L /* device can do local viewer */
  454. #define D3DVTXPCAPS_TWEENING 0x00000040L /* device can do vertex tweening */
  455. #define D3DVTXPCAPS_TEXGEN_SPHEREMAP 0x00000100L /* device supports D3DTSS_TCI_SPHEREMAP */
  456. #define D3DVTXPCAPS_NO_TEXGEN_NONLOCALVIEWER 0x00000200L /* device does not support TexGen in non-local
  457. viewer mode */
  458. //
  459. // DevCaps2
  460. //
  461. #define D3DDEVCAPS2_STREAMOFFSET 0x00000001L /* Device supports offsets in streams. Must be set by DX9 drivers */
  462. #define D3DDEVCAPS2_DMAPNPATCH 0x00000002L /* Device supports displacement maps for N-Patches*/
  463. #define D3DDEVCAPS2_ADAPTIVETESSRTPATCH 0x00000004L /* Device supports adaptive tesselation of RT-patches*/
  464. #define D3DDEVCAPS2_ADAPTIVETESSNPATCH 0x00000008L /* Device supports adaptive tesselation of N-patches*/
  465. #define D3DDEVCAPS2_CAN_STRETCHRECT_FROM_TEXTURES 0x00000010L /* Device supports StretchRect calls with a texture as the source*/
  466. #define D3DDEVCAPS2_PRESAMPLEDDMAPNPATCH 0x00000020L /* Device supports presampled displacement maps for N-Patches */
  467. #define D3DDEVCAPS2_VERTEXELEMENTSCANSHARESTREAMOFFSET 0x00000040L /* Vertex elements in a vertex declaration can share the same stream offset */
  468. //
  469. // DeclTypes
  470. //
  471. #define D3DDTCAPS_UBYTE4 0x00000001L
  472. #define D3DDTCAPS_UBYTE4N 0x00000002L
  473. #define D3DDTCAPS_SHORT2N 0x00000004L
  474. #define D3DDTCAPS_SHORT4N 0x00000008L
  475. #define D3DDTCAPS_USHORT2N 0x00000010L
  476. #define D3DDTCAPS_USHORT4N 0x00000020L
  477. #define D3DDTCAPS_UDEC3 0x00000040L
  478. #define D3DDTCAPS_DEC3N 0x00000080L
  479. #define D3DDTCAPS_FLOAT16_2 0x00000100L
  480. #define D3DDTCAPS_FLOAT16_4 0x00000200L
  481. #pragma pack()
  482. #endif /* (DIRECT3D_VERSION >= 0x0900) */
  483. #endif /* _d3d9CAPS_H_ */