José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1 | ########################################################################## |
| 2 | # |
| 3 | # Copyright 2012 Jose Fonseca |
| 4 | # All Rights Reserved. |
| 5 | # |
| 6 | # Permission is hereby granted, free of charge, to any person obtaining a copy |
| 7 | # of this software and associated documentation files (the "Software"), to deal |
| 8 | # in the Software without restriction, including without limitation the rights |
| 9 | # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
| 10 | # copies of the Software, and to permit persons to whom the Software is |
| 11 | # furnished to do so, subject to the following conditions: |
| 12 | # |
| 13 | # The above copyright notice and this permission notice shall be included in |
| 14 | # all copies or substantial portions of the Software. |
| 15 | # |
| 16 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR |
| 17 | # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, |
| 18 | # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE |
| 19 | # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER |
| 20 | # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, |
| 21 | # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN |
| 22 | # THE SOFTWARE. |
| 23 | # |
| 24 | ##########################################################################/ |
| 25 | |
| 26 | |
| 27 | from dxgi import * |
| 28 | from d3dcommon import * |
| 29 | from d3d11sdklayers import * |
| 30 | |
| 31 | |
José Fonseca | 73841ad | 2012-04-16 20:47:56 +0100 | [diff] [blame] | 32 | HRESULT = MAKE_HRESULT([ |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 33 | "D3D11_ERROR_FILE_NOT_FOUND", |
| 34 | "D3D11_ERROR_TOO_MANY_UNIQUE_STATE_OBJECTS", |
| 35 | "D3D11_ERROR_TOO_MANY_UNIQUE_VIEW_OBJECTS", |
| 36 | "D3D11_ERROR_DEFERRED_CONTEXT_MAP_WITHOUT_INITIAL_DISCARD", |
| 37 | "D3DERR_INVALIDCALL", |
| 38 | "D3DERR_WASSTILLDRAWING", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 39 | ]) |
| 40 | |
| 41 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 42 | ID3D11DepthStencilState = Interface("ID3D11DepthStencilState", ID3D11DeviceChild) |
| 43 | ID3D11BlendState = Interface("ID3D11BlendState", ID3D11DeviceChild) |
| 44 | ID3D11RasterizerState = Interface("ID3D11RasterizerState", ID3D11DeviceChild) |
| 45 | ID3D11Resource = Interface("ID3D11Resource", ID3D11DeviceChild) |
| 46 | ID3D11Buffer = Interface("ID3D11Buffer", ID3D11Resource) |
| 47 | ID3D11Texture1D = Interface("ID3D11Texture1D", ID3D11Resource) |
| 48 | ID3D11Texture2D = Interface("ID3D11Texture2D", ID3D11Resource) |
| 49 | ID3D11Texture3D = Interface("ID3D11Texture3D", ID3D11Resource) |
| 50 | ID3D11View = Interface("ID3D11View", ID3D11DeviceChild) |
| 51 | ID3D11ShaderResourceView = Interface("ID3D11ShaderResourceView", ID3D11View) |
| 52 | ID3D11RenderTargetView = Interface("ID3D11RenderTargetView", ID3D11View) |
| 53 | ID3D11DepthStencilView = Interface("ID3D11DepthStencilView", ID3D11View) |
| 54 | ID3D11UnorderedAccessView = Interface("ID3D11UnorderedAccessView", ID3D11View) |
| 55 | ID3D11VertexShader = Interface("ID3D11VertexShader", ID3D11DeviceChild) |
| 56 | ID3D11HullShader = Interface("ID3D11HullShader", ID3D11DeviceChild) |
| 57 | ID3D11DomainShader = Interface("ID3D11DomainShader", ID3D11DeviceChild) |
| 58 | ID3D11GeometryShader = Interface("ID3D11GeometryShader", ID3D11DeviceChild) |
| 59 | ID3D11PixelShader = Interface("ID3D11PixelShader", ID3D11DeviceChild) |
| 60 | ID3D11ComputeShader = Interface("ID3D11ComputeShader", ID3D11DeviceChild) |
| 61 | ID3D11InputLayout = Interface("ID3D11InputLayout", ID3D11DeviceChild) |
| 62 | ID3D11SamplerState = Interface("ID3D11SamplerState", ID3D11DeviceChild) |
| 63 | ID3D11Asynchronous = Interface("ID3D11Asynchronous", ID3D11DeviceChild) |
| 64 | ID3D11Query = Interface("ID3D11Query", ID3D11Asynchronous) |
| 65 | ID3D11Predicate = Interface("ID3D11Predicate", ID3D11Query) |
| 66 | ID3D11Counter = Interface("ID3D11Counter", ID3D11Asynchronous) |
| 67 | ID3D11ClassInstance = Interface("ID3D11ClassInstance", ID3D11DeviceChild) |
| 68 | ID3D11ClassLinkage = Interface("ID3D11ClassLinkage", ID3D11DeviceChild) |
| 69 | ID3D11CommandList = Interface("ID3D11CommandList", ID3D11DeviceChild) |
| 70 | ID3D11Device = Interface("ID3D11Device", IUnknown) |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 71 | |
| 72 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 73 | D3D11_INPUT_CLASSIFICATION = Enum("D3D11_INPUT_CLASSIFICATION", [ |
| 74 | "D3D11_INPUT_PER_VERTEX_DATA", |
| 75 | "D3D11_INPUT_PER_INSTANCE_DATA", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 76 | ]) |
| 77 | |
| 78 | D3D11_INPUT_ELEMENT_ALIGNED_BYTE_OFFSET = FakeEnum(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 79 | "D3D11_APPEND_ALIGNED_ELEMENT", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 80 | ]) |
| 81 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 82 | D3D11_INPUT_ELEMENT_DESC = Struct("D3D11_INPUT_ELEMENT_DESC", [ |
| 83 | (LPCSTR, "SemanticName"), |
| 84 | (UINT, "SemanticIndex"), |
| 85 | (DXGI_FORMAT, "Format"), |
| 86 | (UINT, "InputSlot"), |
| 87 | (D3D11_INPUT_ELEMENT_ALIGNED_BYTE_OFFSET, "AlignedByteOffset"), |
| 88 | (D3D11_INPUT_CLASSIFICATION, "InputSlotClass"), |
| 89 | (UINT, "InstanceDataStepRate"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 90 | ]) |
| 91 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 92 | D3D11_FILL_MODE = Enum("D3D11_FILL_MODE", [ |
| 93 | "D3D11_FILL_WIREFRAME", |
| 94 | "D3D11_FILL_SOLID", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 95 | ]) |
| 96 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 97 | D3D11_PRIMITIVE_TOPOLOGY = Enum("D3D11_PRIMITIVE_TOPOLOGY", [ |
| 98 | "D3D11_PRIMITIVE_TOPOLOGY_UNDEFINED", |
| 99 | "D3D11_PRIMITIVE_TOPOLOGY_POINTLIST", |
| 100 | "D3D11_PRIMITIVE_TOPOLOGY_LINELIST", |
| 101 | "D3D11_PRIMITIVE_TOPOLOGY_LINESTRIP", |
| 102 | "D3D11_PRIMITIVE_TOPOLOGY_TRIANGLELIST", |
| 103 | "D3D11_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP", |
| 104 | "D3D11_PRIMITIVE_TOPOLOGY_LINELIST_ADJ", |
| 105 | "D3D11_PRIMITIVE_TOPOLOGY_LINESTRIP_ADJ", |
| 106 | "D3D11_PRIMITIVE_TOPOLOGY_TRIANGLELIST_ADJ", |
| 107 | "D3D11_PRIMITIVE_TOPOLOGY_TRIANGLESTRIP_ADJ", |
| 108 | "D3D11_PRIMITIVE_TOPOLOGY_1_CONTROL_POINT_PATCHLIST", |
| 109 | "D3D11_PRIMITIVE_TOPOLOGY_2_CONTROL_POINT_PATCHLIST", |
| 110 | "D3D11_PRIMITIVE_TOPOLOGY_3_CONTROL_POINT_PATCHLIST", |
| 111 | "D3D11_PRIMITIVE_TOPOLOGY_4_CONTROL_POINT_PATCHLIST", |
| 112 | "D3D11_PRIMITIVE_TOPOLOGY_5_CONTROL_POINT_PATCHLIST", |
| 113 | "D3D11_PRIMITIVE_TOPOLOGY_6_CONTROL_POINT_PATCHLIST", |
| 114 | "D3D11_PRIMITIVE_TOPOLOGY_7_CONTROL_POINT_PATCHLIST", |
| 115 | "D3D11_PRIMITIVE_TOPOLOGY_8_CONTROL_POINT_PATCHLIST", |
| 116 | "D3D11_PRIMITIVE_TOPOLOGY_9_CONTROL_POINT_PATCHLIST", |
| 117 | "D3D11_PRIMITIVE_TOPOLOGY_10_CONTROL_POINT_PATCHLIST", |
| 118 | "D3D11_PRIMITIVE_TOPOLOGY_11_CONTROL_POINT_PATCHLIST", |
| 119 | "D3D11_PRIMITIVE_TOPOLOGY_12_CONTROL_POINT_PATCHLIST", |
| 120 | "D3D11_PRIMITIVE_TOPOLOGY_13_CONTROL_POINT_PATCHLIST", |
| 121 | "D3D11_PRIMITIVE_TOPOLOGY_14_CONTROL_POINT_PATCHLIST", |
| 122 | "D3D11_PRIMITIVE_TOPOLOGY_15_CONTROL_POINT_PATCHLIST", |
| 123 | "D3D11_PRIMITIVE_TOPOLOGY_16_CONTROL_POINT_PATCHLIST", |
| 124 | "D3D11_PRIMITIVE_TOPOLOGY_17_CONTROL_POINT_PATCHLIST", |
| 125 | "D3D11_PRIMITIVE_TOPOLOGY_18_CONTROL_POINT_PATCHLIST", |
| 126 | "D3D11_PRIMITIVE_TOPOLOGY_19_CONTROL_POINT_PATCHLIST", |
| 127 | "D3D11_PRIMITIVE_TOPOLOGY_20_CONTROL_POINT_PATCHLIST", |
| 128 | "D3D11_PRIMITIVE_TOPOLOGY_21_CONTROL_POINT_PATCHLIST", |
| 129 | "D3D11_PRIMITIVE_TOPOLOGY_22_CONTROL_POINT_PATCHLIST", |
| 130 | "D3D11_PRIMITIVE_TOPOLOGY_23_CONTROL_POINT_PATCHLIST", |
| 131 | "D3D11_PRIMITIVE_TOPOLOGY_24_CONTROL_POINT_PATCHLIST", |
| 132 | "D3D11_PRIMITIVE_TOPOLOGY_25_CONTROL_POINT_PATCHLIST", |
| 133 | "D3D11_PRIMITIVE_TOPOLOGY_26_CONTROL_POINT_PATCHLIST", |
| 134 | "D3D11_PRIMITIVE_TOPOLOGY_27_CONTROL_POINT_PATCHLIST", |
| 135 | "D3D11_PRIMITIVE_TOPOLOGY_28_CONTROL_POINT_PATCHLIST", |
| 136 | "D3D11_PRIMITIVE_TOPOLOGY_29_CONTROL_POINT_PATCHLIST", |
| 137 | "D3D11_PRIMITIVE_TOPOLOGY_30_CONTROL_POINT_PATCHLIST", |
| 138 | "D3D11_PRIMITIVE_TOPOLOGY_31_CONTROL_POINT_PATCHLIST", |
| 139 | "D3D11_PRIMITIVE_TOPOLOGY_32_CONTROL_POINT_PATCHLIST", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 140 | ]) |
| 141 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 142 | D3D11_PRIMITIVE = Enum("D3D11_PRIMITIVE", [ |
| 143 | "D3D11_PRIMITIVE_UNDEFINED", |
| 144 | "D3D11_PRIMITIVE_POINT", |
| 145 | "D3D11_PRIMITIVE_LINE", |
| 146 | "D3D11_PRIMITIVE_TRIANGLE", |
| 147 | "D3D11_PRIMITIVE_LINE_ADJ", |
| 148 | "D3D11_PRIMITIVE_TRIANGLE_ADJ", |
| 149 | "D3D11_PRIMITIVE_1_CONTROL_POINT_PATCH", |
| 150 | "D3D11_PRIMITIVE_2_CONTROL_POINT_PATCH", |
| 151 | "D3D11_PRIMITIVE_3_CONTROL_POINT_PATCH", |
| 152 | "D3D11_PRIMITIVE_4_CONTROL_POINT_PATCH", |
| 153 | "D3D11_PRIMITIVE_5_CONTROL_POINT_PATCH", |
| 154 | "D3D11_PRIMITIVE_6_CONTROL_POINT_PATCH", |
| 155 | "D3D11_PRIMITIVE_7_CONTROL_POINT_PATCH", |
| 156 | "D3D11_PRIMITIVE_8_CONTROL_POINT_PATCH", |
| 157 | "D3D11_PRIMITIVE_9_CONTROL_POINT_PATCH", |
| 158 | "D3D11_PRIMITIVE_10_CONTROL_POINT_PATCH", |
| 159 | "D3D11_PRIMITIVE_11_CONTROL_POINT_PATCH", |
| 160 | "D3D11_PRIMITIVE_12_CONTROL_POINT_PATCH", |
| 161 | "D3D11_PRIMITIVE_13_CONTROL_POINT_PATCH", |
| 162 | "D3D11_PRIMITIVE_14_CONTROL_POINT_PATCH", |
| 163 | "D3D11_PRIMITIVE_15_CONTROL_POINT_PATCH", |
| 164 | "D3D11_PRIMITIVE_16_CONTROL_POINT_PATCH", |
| 165 | "D3D11_PRIMITIVE_17_CONTROL_POINT_PATCH", |
| 166 | "D3D11_PRIMITIVE_18_CONTROL_POINT_PATCH", |
| 167 | "D3D11_PRIMITIVE_19_CONTROL_POINT_PATCH", |
| 168 | "D3D11_PRIMITIVE_20_CONTROL_POINT_PATCH", |
| 169 | "D3D11_PRIMITIVE_21_CONTROL_POINT_PATCH", |
| 170 | "D3D11_PRIMITIVE_22_CONTROL_POINT_PATCH", |
| 171 | "D3D11_PRIMITIVE_23_CONTROL_POINT_PATCH", |
| 172 | "D3D11_PRIMITIVE_24_CONTROL_POINT_PATCH", |
| 173 | "D3D11_PRIMITIVE_25_CONTROL_POINT_PATCH", |
| 174 | "D3D11_PRIMITIVE_26_CONTROL_POINT_PATCH", |
| 175 | "D3D11_PRIMITIVE_27_CONTROL_POINT_PATCH", |
| 176 | "D3D11_PRIMITIVE_28_CONTROL_POINT_PATCH", |
| 177 | "D3D11_PRIMITIVE_29_CONTROL_POINT_PATCH", |
| 178 | "D3D11_PRIMITIVE_30_CONTROL_POINT_PATCH", |
| 179 | "D3D11_PRIMITIVE_31_CONTROL_POINT_PATCH", |
| 180 | "D3D11_PRIMITIVE_32_CONTROL_POINT_PATCH", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 181 | ]) |
| 182 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 183 | D3D11_CULL_MODE = Enum("D3D11_CULL_MODE", [ |
| 184 | "D3D11_CULL_NONE", |
| 185 | "D3D11_CULL_FRONT", |
| 186 | "D3D11_CULL_BACK", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 187 | ]) |
| 188 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 189 | D3D11_SO_DECLARATION_ENTRY = Struct("D3D11_SO_DECLARATION_ENTRY", [ |
| 190 | (UINT, "Stream"), |
| 191 | (LPCSTR, "SemanticName"), |
| 192 | (UINT, "SemanticIndex"), |
| 193 | (BYTE, "StartComponent"), |
| 194 | (BYTE, "ComponentCount"), |
| 195 | (BYTE, "OutputSlot"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 196 | ]) |
| 197 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 198 | D3D11_VIEWPORT = Struct("D3D11_VIEWPORT", [ |
| 199 | (FLOAT, "TopLeftX"), |
| 200 | (FLOAT, "TopLeftY"), |
| 201 | (FLOAT, "Width"), |
| 202 | (FLOAT, "Height"), |
| 203 | (FLOAT, "MinDepth"), |
| 204 | (FLOAT, "MaxDepth"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 205 | ]) |
| 206 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 207 | D3D11_RESOURCE_DIMENSION = Enum("D3D11_RESOURCE_DIMENSION", [ |
| 208 | "D3D11_RESOURCE_DIMENSION_UNKNOWN", |
| 209 | "D3D11_RESOURCE_DIMENSION_BUFFER", |
| 210 | "D3D11_RESOURCE_DIMENSION_TEXTURE1D", |
| 211 | "D3D11_RESOURCE_DIMENSION_TEXTURE2D", |
| 212 | "D3D11_RESOURCE_DIMENSION_TEXTURE3D", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 213 | ]) |
| 214 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 215 | D3D11_SRV_DIMENSION = Enum("D3D11_SRV_DIMENSION", [ |
| 216 | "D3D11_SRV_DIMENSION_UNKNOWN", |
| 217 | "D3D11_SRV_DIMENSION_BUFFER", |
| 218 | "D3D11_SRV_DIMENSION_TEXTURE1D", |
| 219 | "D3D11_SRV_DIMENSION_TEXTURE1DARRAY", |
| 220 | "D3D11_SRV_DIMENSION_TEXTURE2D", |
| 221 | "D3D11_SRV_DIMENSION_TEXTURE2DARRAY", |
| 222 | "D3D11_SRV_DIMENSION_TEXTURE2DMS", |
| 223 | "D3D11_SRV_DIMENSION_TEXTURE2DMSARRAY", |
| 224 | "D3D11_SRV_DIMENSION_TEXTURE3D", |
| 225 | "D3D11_SRV_DIMENSION_TEXTURECUBE", |
| 226 | "D3D11_SRV_DIMENSION_TEXTURECUBEARRAY", |
| 227 | "D3D11_SRV_DIMENSION_BUFFEREX", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 228 | ]) |
| 229 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 230 | D3D11_DSV_DIMENSION = Enum("D3D11_DSV_DIMENSION", [ |
| 231 | "D3D11_DSV_DIMENSION_UNKNOWN", |
| 232 | "D3D11_DSV_DIMENSION_TEXTURE1D", |
| 233 | "D3D11_DSV_DIMENSION_TEXTURE1DARRAY", |
| 234 | "D3D11_DSV_DIMENSION_TEXTURE2D", |
| 235 | "D3D11_DSV_DIMENSION_TEXTURE2DARRAY", |
| 236 | "D3D11_DSV_DIMENSION_TEXTURE2DMS", |
| 237 | "D3D11_DSV_DIMENSION_TEXTURE2DMSARRAY", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 238 | ]) |
| 239 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 240 | D3D11_RTV_DIMENSION = Enum("D3D11_RTV_DIMENSION", [ |
| 241 | "D3D11_RTV_DIMENSION_UNKNOWN", |
| 242 | "D3D11_RTV_DIMENSION_BUFFER", |
| 243 | "D3D11_RTV_DIMENSION_TEXTURE1D", |
| 244 | "D3D11_RTV_DIMENSION_TEXTURE1DARRAY", |
| 245 | "D3D11_RTV_DIMENSION_TEXTURE2D", |
| 246 | "D3D11_RTV_DIMENSION_TEXTURE2DARRAY", |
| 247 | "D3D11_RTV_DIMENSION_TEXTURE2DMS", |
| 248 | "D3D11_RTV_DIMENSION_TEXTURE2DMSARRAY", |
| 249 | "D3D11_RTV_DIMENSION_TEXTURE3D", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 250 | ]) |
| 251 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 252 | D3D11_UAV_DIMENSION = Enum("D3D11_UAV_DIMENSION", [ |
| 253 | "D3D11_UAV_DIMENSION_UNKNOWN", |
| 254 | "D3D11_UAV_DIMENSION_BUFFER", |
| 255 | "D3D11_UAV_DIMENSION_TEXTURE1D", |
| 256 | "D3D11_UAV_DIMENSION_TEXTURE1DARRAY", |
| 257 | "D3D11_UAV_DIMENSION_TEXTURE2D", |
| 258 | "D3D11_UAV_DIMENSION_TEXTURE2DARRAY", |
| 259 | "D3D11_UAV_DIMENSION_TEXTURE3D", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 260 | ]) |
| 261 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 262 | D3D11_USAGE = Enum("D3D11_USAGE", [ |
| 263 | "D3D11_USAGE_DEFAULT", |
| 264 | "D3D11_USAGE_IMMUTABLE", |
| 265 | "D3D11_USAGE_DYNAMIC", |
| 266 | "D3D11_USAGE_STAGING", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 267 | ]) |
| 268 | |
| 269 | D3D11_BIND_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 270 | "D3D11_BIND_VERTEX_BUFFER", |
| 271 | "D3D11_BIND_INDEX_BUFFER", |
| 272 | "D3D11_BIND_CONSTANT_BUFFER", |
| 273 | "D3D11_BIND_SHADER_RESOURCE", |
| 274 | "D3D11_BIND_STREAM_OUTPUT", |
| 275 | "D3D11_BIND_RENDER_TARGET", |
| 276 | "D3D11_BIND_DEPTH_STENCIL", |
| 277 | "D3D11_BIND_UNORDERED_ACCESS", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 278 | ]) |
| 279 | |
| 280 | D3D11_CPU_ACCESS_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 281 | "D3D11_CPU_ACCESS_WRITE", |
| 282 | "D3D11_CPU_ACCESS_READ", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 283 | ]) |
| 284 | |
| 285 | D3D11_RESOURCE_MISC_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 286 | "D3D11_RESOURCE_MISC_GENERATE_MIPS", |
| 287 | "D3D11_RESOURCE_MISC_SHARED", |
| 288 | "D3D11_RESOURCE_MISC_TEXTURECUBE", |
| 289 | "D3D11_RESOURCE_MISC_DRAWINDIRECT_ARGS", |
| 290 | "D3D11_RESOURCE_MISC_BUFFER_ALLOW_RAW_VIEWS", |
| 291 | "D3D11_RESOURCE_MISC_BUFFER_STRUCTURED", |
| 292 | "D3D11_RESOURCE_MISC_RESOURCE_CLAMP", |
| 293 | "D3D11_RESOURCE_MISC_SHARED_KEYEDMUTEX", |
| 294 | "D3D11_RESOURCE_MISC_GDI_COMPATIBLE", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 295 | ]) |
| 296 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 297 | D3D11_MAP = Enum("D3D11_MAP", [ |
| 298 | "D3D11_MAP_READ", |
| 299 | "D3D11_MAP_WRITE", |
| 300 | "D3D11_MAP_READ_WRITE", |
| 301 | "D3D11_MAP_WRITE_DISCARD", |
| 302 | "D3D11_MAP_WRITE_NO_OVERWRITE", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 303 | ]) |
| 304 | |
| 305 | D3D11_MAP_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 306 | "D3D11_MAP_FLAG_DO_NOT_WAIT", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 307 | ]) |
| 308 | |
| 309 | D3D11_RAISE_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 310 | "D3D11_RAISE_FLAG_DRIVER_INTERNAL_ERROR", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 311 | ]) |
| 312 | |
| 313 | D3D11_CLEAR_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 314 | "D3D11_CLEAR_DEPTH", |
| 315 | "D3D11_CLEAR_STENCIL", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 316 | ]) |
| 317 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 318 | D3D11_RECT = Alias("D3D11_RECT", RECT) |
| 319 | D3D11_BOX = Struct("D3D11_BOX", [ |
| 320 | (UINT, "left"), |
| 321 | (UINT, "top"), |
| 322 | (UINT, "front"), |
| 323 | (UINT, "right"), |
| 324 | (UINT, "bottom"), |
| 325 | (UINT, "back"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 326 | ]) |
| 327 | |
| 328 | ID3D11DeviceChild.methods += [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 329 | StdMethod(Void, "GetDevice", [Out(Pointer(ObjPointer(ID3D11Device)), "ppDevice")]), |
José Fonseca | bc10e45 | 2012-11-08 10:24:45 +0000 | [diff] [blame] | 330 | StdMethod(HRESULT, "GetPrivateData", [(REFGUID, "guid"), Out(Pointer(UINT), "pDataSize"), Out(OpaquePointer(Void), "pData")], sideeffects=False), |
| 331 | StdMethod(HRESULT, "SetPrivateData", [(REFGUID, "guid"), (UINT, "DataSize"), (OpaqueBlob(Const(Void), "DataSize"), "pData")], sideeffects=False), |
| 332 | StdMethod(HRESULT, "SetPrivateDataInterface", [(REFGUID, "guid"), (OpaquePointer(Const(IUnknown)), "pData")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 333 | ] |
| 334 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 335 | D3D11_COMPARISON_FUNC = Enum("D3D11_COMPARISON_FUNC", [ |
| 336 | "D3D11_COMPARISON_NEVER", |
| 337 | "D3D11_COMPARISON_LESS", |
| 338 | "D3D11_COMPARISON_EQUAL", |
| 339 | "D3D11_COMPARISON_LESS_EQUAL", |
| 340 | "D3D11_COMPARISON_GREATER", |
| 341 | "D3D11_COMPARISON_NOT_EQUAL", |
| 342 | "D3D11_COMPARISON_GREATER_EQUAL", |
| 343 | "D3D11_COMPARISON_ALWAYS", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 344 | ]) |
| 345 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 346 | D3D11_DEPTH_WRITE_MASK = Enum("D3D11_DEPTH_WRITE_MASK", [ |
| 347 | "D3D11_DEPTH_WRITE_MASK_ZERO", |
| 348 | "D3D11_DEPTH_WRITE_MASK_ALL", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 349 | ]) |
| 350 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 351 | D3D11_STENCIL_OP = Enum("D3D11_STENCIL_OP", [ |
| 352 | "D3D11_STENCIL_OP_KEEP", |
| 353 | "D3D11_STENCIL_OP_ZERO", |
| 354 | "D3D11_STENCIL_OP_REPLACE", |
| 355 | "D3D11_STENCIL_OP_INCR_SAT", |
| 356 | "D3D11_STENCIL_OP_DECR_SAT", |
| 357 | "D3D11_STENCIL_OP_INVERT", |
| 358 | "D3D11_STENCIL_OP_INCR", |
| 359 | "D3D11_STENCIL_OP_DECR", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 360 | ]) |
| 361 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 362 | D3D11_DEPTH_STENCILOP_DESC = Struct("D3D11_DEPTH_STENCILOP_DESC", [ |
| 363 | (D3D11_STENCIL_OP, "StencilFailOp"), |
| 364 | (D3D11_STENCIL_OP, "StencilDepthFailOp"), |
| 365 | (D3D11_STENCIL_OP, "StencilPassOp"), |
| 366 | (D3D11_COMPARISON_FUNC, "StencilFunc"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 367 | ]) |
| 368 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 369 | D3D11_DEPTH_STENCIL_DESC = Struct("D3D11_DEPTH_STENCIL_DESC", [ |
| 370 | (BOOL, "DepthEnable"), |
| 371 | (D3D11_DEPTH_WRITE_MASK, "DepthWriteMask"), |
| 372 | (D3D11_COMPARISON_FUNC, "DepthFunc"), |
| 373 | (BOOL, "StencilEnable"), |
| 374 | (UINT8, "StencilReadMask"), |
| 375 | (UINT8, "StencilWriteMask"), |
| 376 | (D3D11_DEPTH_STENCILOP_DESC, "FrontFace"), |
| 377 | (D3D11_DEPTH_STENCILOP_DESC, "BackFace"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 378 | ]) |
| 379 | |
| 380 | ID3D11DepthStencilState.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 381 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_DEPTH_STENCIL_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 382 | ] |
| 383 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 384 | D3D11_BLEND = Enum("D3D11_BLEND", [ |
| 385 | "D3D11_BLEND_ZERO", |
| 386 | "D3D11_BLEND_ONE", |
| 387 | "D3D11_BLEND_SRC_COLOR", |
| 388 | "D3D11_BLEND_INV_SRC_COLOR", |
| 389 | "D3D11_BLEND_SRC_ALPHA", |
| 390 | "D3D11_BLEND_INV_SRC_ALPHA", |
| 391 | "D3D11_BLEND_DEST_ALPHA", |
| 392 | "D3D11_BLEND_INV_DEST_ALPHA", |
| 393 | "D3D11_BLEND_DEST_COLOR", |
| 394 | "D3D11_BLEND_INV_DEST_COLOR", |
| 395 | "D3D11_BLEND_SRC_ALPHA_SAT", |
| 396 | "D3D11_BLEND_BLEND_FACTOR", |
| 397 | "D3D11_BLEND_INV_BLEND_FACTOR", |
| 398 | "D3D11_BLEND_SRC1_COLOR", |
| 399 | "D3D11_BLEND_INV_SRC1_COLOR", |
| 400 | "D3D11_BLEND_SRC1_ALPHA", |
| 401 | "D3D11_BLEND_INV_SRC1_ALPHA", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 402 | ]) |
| 403 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 404 | D3D11_BLEND_OP = Enum("D3D11_BLEND_OP", [ |
| 405 | "D3D11_BLEND_OP_ADD", |
| 406 | "D3D11_BLEND_OP_SUBTRACT", |
| 407 | "D3D11_BLEND_OP_REV_SUBTRACT", |
| 408 | "D3D11_BLEND_OP_MIN", |
| 409 | "D3D11_BLEND_OP_MAX", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 410 | ]) |
| 411 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 412 | D3D11_COLOR_WRITE_ENABLE = Enum("D3D11_COLOR_WRITE_ENABLE", [ |
| 413 | "D3D11_COLOR_WRITE_ENABLE_ALL", |
| 414 | "D3D11_COLOR_WRITE_ENABLE_RED", |
| 415 | "D3D11_COLOR_WRITE_ENABLE_GREEN", |
| 416 | "D3D11_COLOR_WRITE_ENABLE_BLUE", |
| 417 | "D3D11_COLOR_WRITE_ENABLE_ALPHA", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 418 | ]) |
| 419 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 420 | D3D11_RENDER_TARGET_BLEND_DESC = Struct("D3D11_RENDER_TARGET_BLEND_DESC", [ |
| 421 | (BOOL, "BlendEnable"), |
| 422 | (D3D11_BLEND, "SrcBlend"), |
| 423 | (D3D11_BLEND, "DestBlend"), |
| 424 | (D3D11_BLEND_OP, "BlendOp"), |
| 425 | (D3D11_BLEND, "SrcBlendAlpha"), |
| 426 | (D3D11_BLEND, "DestBlendAlpha"), |
| 427 | (D3D11_BLEND_OP, "BlendOpAlpha"), |
| 428 | (UINT8, "RenderTargetWriteMask"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 429 | ]) |
| 430 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 431 | D3D11_BLEND_DESC = Struct("D3D11_BLEND_DESC", [ |
| 432 | (BOOL, "AlphaToCoverageEnable"), |
| 433 | (BOOL, "IndependentBlendEnable"), |
| 434 | (Array(D3D11_RENDER_TARGET_BLEND_DESC, 8), "RenderTarget"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 435 | ]) |
| 436 | |
| 437 | ID3D11BlendState.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 438 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_BLEND_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 439 | ] |
| 440 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 441 | D3D11_RASTERIZER_DESC = Struct("D3D11_RASTERIZER_DESC", [ |
| 442 | (D3D11_FILL_MODE, "FillMode"), |
| 443 | (D3D11_CULL_MODE, "CullMode"), |
| 444 | (BOOL, "FrontCounterClockwise"), |
| 445 | (INT, "DepthBias"), |
| 446 | (FLOAT, "DepthBiasClamp"), |
| 447 | (FLOAT, "SlopeScaledDepthBias"), |
| 448 | (BOOL, "DepthClipEnable"), |
| 449 | (BOOL, "ScissorEnable"), |
| 450 | (BOOL, "MultisampleEnable"), |
| 451 | (BOOL, "AntialiasedLineEnable"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 452 | ]) |
| 453 | |
| 454 | ID3D11RasterizerState.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 455 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_RASTERIZER_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 456 | ] |
| 457 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 458 | D3D11_SUBRESOURCE_DATA = Struct("D3D11_SUBRESOURCE_DATA", [ |
José Fonseca | 8f6e0e3 | 2012-11-07 19:22:20 +0000 | [diff] [blame] | 459 | (Blob(Const(Void), "_calcSubresourceSize(pDesc, {i}, {self}.SysMemPitch, {self}.SysMemSlicePitch)"), "pSysMem"), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 460 | (UINT, "SysMemPitch"), |
| 461 | (UINT, "SysMemSlicePitch"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 462 | ]) |
| 463 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 464 | D3D11_MAPPED_SUBRESOURCE = Struct("D3D11_MAPPED_SUBRESOURCE", [ |
José Fonseca | e6bde44 | 2012-11-14 08:45:58 +0000 | [diff] [blame] | 465 | (LinearPointer(Void, "_MappedSize"), "pData"), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 466 | (UINT, "RowPitch"), |
| 467 | (UINT, "DepthPitch"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 468 | ]) |
| 469 | |
| 470 | ID3D11Resource.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 471 | StdMethod(Void, "GetType", [Out(Pointer(D3D11_RESOURCE_DIMENSION), "pResourceDimension")], sideeffects=False), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 472 | StdMethod(Void, "SetEvictionPriority", [(UINT, "EvictionPriority")]), |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 473 | StdMethod(UINT, "GetEvictionPriority", [], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 474 | ] |
| 475 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 476 | D3D11_BUFFER_DESC = Struct("D3D11_BUFFER_DESC", [ |
| 477 | (UINT, "ByteWidth"), |
| 478 | (D3D11_USAGE, "Usage"), |
| 479 | (D3D11_BIND_FLAG, "BindFlags"), |
| 480 | (D3D11_CPU_ACCESS_FLAG, "CPUAccessFlags"), |
| 481 | (D3D11_RESOURCE_MISC_FLAG, "MiscFlags"), |
| 482 | (UINT, "StructureByteStride"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 483 | ]) |
| 484 | |
| 485 | ID3D11Buffer.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 486 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_BUFFER_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 487 | ] |
| 488 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 489 | D3D11_TEXTURE1D_DESC = Struct("D3D11_TEXTURE1D_DESC", [ |
| 490 | (UINT, "Width"), |
| 491 | (UINT, "MipLevels"), |
| 492 | (UINT, "ArraySize"), |
| 493 | (DXGI_FORMAT, "Format"), |
| 494 | (D3D11_USAGE, "Usage"), |
| 495 | (D3D11_BIND_FLAG, "BindFlags"), |
| 496 | (D3D11_CPU_ACCESS_FLAG, "CPUAccessFlags"), |
| 497 | (D3D11_RESOURCE_MISC_FLAG, "MiscFlags"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 498 | ]) |
| 499 | |
| 500 | ID3D11Texture1D.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 501 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_TEXTURE1D_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 502 | ] |
| 503 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 504 | D3D11_TEXTURE2D_DESC = Struct("D3D11_TEXTURE2D_DESC", [ |
| 505 | (UINT, "Width"), |
| 506 | (UINT, "Height"), |
| 507 | (UINT, "MipLevels"), |
| 508 | (UINT, "ArraySize"), |
| 509 | (DXGI_FORMAT, "Format"), |
| 510 | (DXGI_SAMPLE_DESC, "SampleDesc"), |
| 511 | (D3D11_USAGE, "Usage"), |
| 512 | (D3D11_BIND_FLAG, "BindFlags"), |
| 513 | (D3D11_CPU_ACCESS_FLAG, "CPUAccessFlags"), |
| 514 | (D3D11_RESOURCE_MISC_FLAG, "MiscFlags"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 515 | ]) |
| 516 | |
| 517 | ID3D11Texture2D.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 518 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_TEXTURE2D_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 519 | ] |
| 520 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 521 | D3D11_TEXTURE3D_DESC = Struct("D3D11_TEXTURE3D_DESC", [ |
| 522 | (UINT, "Width"), |
| 523 | (UINT, "Height"), |
| 524 | (UINT, "Depth"), |
| 525 | (UINT, "MipLevels"), |
| 526 | (DXGI_FORMAT, "Format"), |
| 527 | (D3D11_USAGE, "Usage"), |
| 528 | (D3D11_BIND_FLAG, "BindFlags"), |
| 529 | (D3D11_CPU_ACCESS_FLAG, "CPUAccessFlags"), |
| 530 | (D3D11_RESOURCE_MISC_FLAG, "MiscFlags"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 531 | ]) |
| 532 | |
| 533 | ID3D11Texture3D.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 534 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_TEXTURE3D_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 535 | ] |
| 536 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 537 | D3D11_TEXTURECUBE_FACE = Enum("D3D11_TEXTURECUBE_FACE", [ |
| 538 | "D3D11_TEXTURECUBE_FACE_POSITIVE_X", |
| 539 | "D3D11_TEXTURECUBE_FACE_NEGATIVE_X", |
| 540 | "D3D11_TEXTURECUBE_FACE_POSITIVE_Y", |
| 541 | "D3D11_TEXTURECUBE_FACE_NEGATIVE_Y", |
| 542 | "D3D11_TEXTURECUBE_FACE_POSITIVE_Z", |
| 543 | "D3D11_TEXTURECUBE_FACE_NEGATIVE_Z", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 544 | ]) |
| 545 | |
| 546 | ID3D11View.methods += [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 547 | StdMethod(Void, "GetResource", [Out(Pointer(ObjPointer(ID3D11Resource)), "ppResource")]), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 548 | ] |
| 549 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 550 | D3D11_BUFFER_SRV = Struct("D3D11_BUFFER_SRV", [ |
José Fonseca | 5f4b6e3 | 2012-11-20 10:47:10 +0000 | [diff] [blame] | 551 | (UINT, "FirstElement"), |
| 552 | (UINT, "NumElements"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 553 | ]) |
| 554 | |
| 555 | D3D11_BUFFEREX_SRV_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 556 | "D3D11_BUFFEREX_SRV_FLAG_RAW", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 557 | ]) |
| 558 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 559 | D3D11_BUFFEREX_SRV = Struct("D3D11_BUFFEREX_SRV", [ |
| 560 | (UINT, "FirstElement"), |
| 561 | (UINT, "NumElements"), |
| 562 | (D3D11_BUFFEREX_SRV_FLAG, "Flags"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 563 | ]) |
| 564 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 565 | D3D11_TEX1D_SRV = Struct("D3D11_TEX1D_SRV", [ |
| 566 | (UINT, "MostDetailedMip"), |
| 567 | (UINT, "MipLevels"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 568 | ]) |
| 569 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 570 | D3D11_TEX1D_ARRAY_SRV = Struct("D3D11_TEX1D_ARRAY_SRV", [ |
| 571 | (UINT, "MostDetailedMip"), |
| 572 | (UINT, "MipLevels"), |
| 573 | (UINT, "FirstArraySlice"), |
| 574 | (UINT, "ArraySize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 575 | ]) |
| 576 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 577 | D3D11_TEX2D_SRV = Struct("D3D11_TEX2D_SRV", [ |
| 578 | (UINT, "MostDetailedMip"), |
| 579 | (UINT, "MipLevels"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 580 | ]) |
| 581 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 582 | D3D11_TEX2D_ARRAY_SRV = Struct("D3D11_TEX2D_ARRAY_SRV", [ |
| 583 | (UINT, "MostDetailedMip"), |
| 584 | (UINT, "MipLevels"), |
| 585 | (UINT, "FirstArraySlice"), |
| 586 | (UINT, "ArraySize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 587 | ]) |
| 588 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 589 | D3D11_TEX3D_SRV = Struct("D3D11_TEX3D_SRV", [ |
| 590 | (UINT, "MostDetailedMip"), |
| 591 | (UINT, "MipLevels"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 592 | ]) |
| 593 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 594 | D3D11_TEXCUBE_SRV = Struct("D3D11_TEXCUBE_SRV", [ |
| 595 | (UINT, "MostDetailedMip"), |
| 596 | (UINT, "MipLevels"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 597 | ]) |
| 598 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 599 | D3D11_TEXCUBE_ARRAY_SRV = Struct("D3D11_TEXCUBE_ARRAY_SRV", [ |
| 600 | (UINT, "MostDetailedMip"), |
| 601 | (UINT, "MipLevels"), |
| 602 | (UINT, "First2DArrayFace"), |
| 603 | (UINT, "NumCubes"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 604 | ]) |
| 605 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 606 | D3D11_TEX2DMS_SRV = Struct("D3D11_TEX2DMS_SRV", [ |
| 607 | (UINT, "UnusedField_NothingToDefine"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 608 | ]) |
| 609 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 610 | D3D11_TEX2DMS_ARRAY_SRV = Struct("D3D11_TEX2DMS_ARRAY_SRV", [ |
| 611 | (UINT, "FirstArraySlice"), |
| 612 | (UINT, "ArraySize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 613 | ]) |
| 614 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 615 | D3D11_SHADER_RESOURCE_VIEW_DESC = Struct("D3D11_SHADER_RESOURCE_VIEW_DESC", [ |
| 616 | (DXGI_FORMAT, "Format"), |
| 617 | (D3D11_SRV_DIMENSION, "ViewDimension"), |
José Fonseca | dbf714b | 2012-11-20 17:03:43 +0000 | [diff] [blame] | 618 | (Union("{self}.ViewDimension", [ |
| 619 | ("D3D11_SRV_DIMENSION_BUFFER", D3D11_BUFFER_SRV, "Buffer"), |
| 620 | ("D3D11_SRV_DIMENSION_TEXTURE1D", D3D11_TEX1D_SRV, "Texture1D"), |
| 621 | ("D3D11_SRV_DIMENSION_TEXTURE1DARRAY", D3D11_TEX1D_ARRAY_SRV, "Texture1DArray"), |
| 622 | ("D3D11_SRV_DIMENSION_TEXTURE2D", D3D11_TEX2D_SRV, "Texture2D"), |
| 623 | ("D3D11_SRV_DIMENSION_TEXTURE2DARRAY", D3D11_TEX2D_ARRAY_SRV, "Texture2DArray"), |
| 624 | ("D3D11_SRV_DIMENSION_TEXTURE2DMS", D3D11_TEX2DMS_SRV, "Texture2DMS"), |
| 625 | ("D3D11_SRV_DIMENSION_TEXTURE2DMSARRAY", D3D11_TEX2DMS_ARRAY_SRV, "Texture2DMSArray"), |
| 626 | ("D3D11_SRV_DIMENSION_TEXTURE3D", D3D11_TEX3D_SRV, "Texture3D"), |
| 627 | ("D3D11_SRV_DIMENSION_TEXTURECUBE", D3D11_TEXCUBE_SRV, "TextureCube"), |
| 628 | ("D3D11_SRV_DIMENSION_TEXTURECUBEARRAY", D3D11_TEXCUBE_ARRAY_SRV, "TextureCubeArray"), |
| 629 | ("D3D11_SRV_DIMENSION_BUFFEREX", D3D11_BUFFEREX_SRV, "BufferEx"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 630 | ]), None), |
| 631 | ]) |
| 632 | |
| 633 | ID3D11ShaderResourceView.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 634 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_SHADER_RESOURCE_VIEW_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 635 | ] |
| 636 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 637 | D3D11_BUFFER_RTV = Struct("D3D11_BUFFER_RTV", [ |
José Fonseca | 5f4b6e3 | 2012-11-20 10:47:10 +0000 | [diff] [blame] | 638 | (UINT, "FirstElement"), |
| 639 | (UINT, "NumElements"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 640 | ]) |
| 641 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 642 | D3D11_TEX1D_RTV = Struct("D3D11_TEX1D_RTV", [ |
| 643 | (UINT, "MipSlice"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 644 | ]) |
| 645 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 646 | D3D11_TEX1D_ARRAY_RTV = Struct("D3D11_TEX1D_ARRAY_RTV", [ |
| 647 | (UINT, "MipSlice"), |
| 648 | (UINT, "FirstArraySlice"), |
| 649 | (UINT, "ArraySize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 650 | ]) |
| 651 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 652 | D3D11_TEX2D_RTV = Struct("D3D11_TEX2D_RTV", [ |
| 653 | (UINT, "MipSlice"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 654 | ]) |
| 655 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 656 | D3D11_TEX2DMS_RTV = Struct("D3D11_TEX2DMS_RTV", [ |
| 657 | (UINT, "UnusedField_NothingToDefine"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 658 | ]) |
| 659 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 660 | D3D11_TEX2D_ARRAY_RTV = Struct("D3D11_TEX2D_ARRAY_RTV", [ |
| 661 | (UINT, "MipSlice"), |
| 662 | (UINT, "FirstArraySlice"), |
| 663 | (UINT, "ArraySize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 664 | ]) |
| 665 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 666 | D3D11_TEX2DMS_ARRAY_RTV = Struct("D3D11_TEX2DMS_ARRAY_RTV", [ |
| 667 | (UINT, "FirstArraySlice"), |
| 668 | (UINT, "ArraySize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 669 | ]) |
| 670 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 671 | D3D11_TEX3D_RTV = Struct("D3D11_TEX3D_RTV", [ |
| 672 | (UINT, "MipSlice"), |
| 673 | (UINT, "FirstWSlice"), |
| 674 | (UINT, "WSize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 675 | ]) |
| 676 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 677 | D3D11_RENDER_TARGET_VIEW_DESC = Struct("D3D11_RENDER_TARGET_VIEW_DESC", [ |
| 678 | (DXGI_FORMAT, "Format"), |
| 679 | (D3D11_RTV_DIMENSION, "ViewDimension"), |
José Fonseca | dbf714b | 2012-11-20 17:03:43 +0000 | [diff] [blame] | 680 | (Union("{self}.ViewDimension", [ |
José Fonseca | eb216e6 | 2012-11-20 11:08:08 +0000 | [diff] [blame] | 681 | ("D3D11_RTV_DIMENSION_BUFFER", D3D11_BUFFER_RTV, "Buffer"), |
| 682 | ("D3D11_RTV_DIMENSION_TEXTURE1D", D3D11_TEX1D_RTV, "Texture1D"), |
| 683 | ("D3D11_RTV_DIMENSION_TEXTURE1DARRAY", D3D11_TEX1D_ARRAY_RTV, "Texture1DArray"), |
| 684 | ("D3D11_RTV_DIMENSION_TEXTURE2D", D3D11_TEX2D_RTV, "Texture2D"), |
| 685 | ("D3D11_RTV_DIMENSION_TEXTURE2DARRAY", D3D11_TEX2D_ARRAY_RTV, "Texture2DArray"), |
| 686 | ("D3D11_RTV_DIMENSION_TEXTURE2DMS", D3D11_TEX2DMS_RTV, "Texture2DMS"), |
| 687 | ("D3D11_RTV_DIMENSION_TEXTURE2DMSARRAY", D3D11_TEX2DMS_ARRAY_RTV, "Texture2DMSArray"), |
| 688 | ("D3D11_RTV_DIMENSION_TEXTURE3D", D3D11_TEX3D_RTV, "Texture3D"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 689 | ]), None), |
| 690 | ]) |
| 691 | |
| 692 | ID3D11RenderTargetView.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 693 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_RENDER_TARGET_VIEW_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 694 | ] |
| 695 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 696 | D3D11_TEX1D_DSV = Struct("D3D11_TEX1D_DSV", [ |
| 697 | (UINT, "MipSlice"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 698 | ]) |
| 699 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 700 | D3D11_TEX1D_ARRAY_DSV = Struct("D3D11_TEX1D_ARRAY_DSV", [ |
| 701 | (UINT, "MipSlice"), |
| 702 | (UINT, "FirstArraySlice"), |
| 703 | (UINT, "ArraySize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 704 | ]) |
| 705 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 706 | D3D11_TEX2D_DSV = Struct("D3D11_TEX2D_DSV", [ |
| 707 | (UINT, "MipSlice"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 708 | ]) |
| 709 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 710 | D3D11_TEX2D_ARRAY_DSV = Struct("D3D11_TEX2D_ARRAY_DSV", [ |
| 711 | (UINT, "MipSlice"), |
| 712 | (UINT, "FirstArraySlice"), |
| 713 | (UINT, "ArraySize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 714 | ]) |
| 715 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 716 | D3D11_TEX2DMS_DSV = Struct("D3D11_TEX2DMS_DSV", [ |
| 717 | (UINT, "UnusedField_NothingToDefine"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 718 | ]) |
| 719 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 720 | D3D11_TEX2DMS_ARRAY_DSV = Struct("D3D11_TEX2DMS_ARRAY_DSV", [ |
| 721 | (UINT, "FirstArraySlice"), |
| 722 | (UINT, "ArraySize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 723 | ]) |
| 724 | |
| 725 | D3D11_DSV_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 726 | "D3D11_DSV_READ_ONLY_DEPTH", |
| 727 | "D3D11_DSV_READ_ONLY_STENCIL", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 728 | ]) |
| 729 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 730 | D3D11_DEPTH_STENCIL_VIEW_DESC = Struct("D3D11_DEPTH_STENCIL_VIEW_DESC", [ |
| 731 | (DXGI_FORMAT, "Format"), |
| 732 | (D3D11_DSV_DIMENSION, "ViewDimension"), |
| 733 | (D3D11_DSV_FLAG, "Flags"), |
José Fonseca | dbf714b | 2012-11-20 17:03:43 +0000 | [diff] [blame] | 734 | (Union("{self}.ViewDimension", [ |
| 735 | ("D3D11_DSV_DIMENSION_TEXTURE1D", D3D11_TEX1D_DSV, "Texture1D"), |
| 736 | ("D3D11_DSV_DIMENSION_TEXTURE1DARRAY", D3D11_TEX1D_ARRAY_DSV, "Texture1DArray"), |
| 737 | ("D3D11_DSV_DIMENSION_TEXTURE2D", D3D11_TEX2D_DSV, "Texture2D"), |
| 738 | ("D3D11_DSV_DIMENSION_TEXTURE2DARRAY", D3D11_TEX2D_ARRAY_DSV, "Texture2DArray"), |
| 739 | ("D3D11_DSV_DIMENSION_TEXTURE2DMS", D3D11_TEX2DMS_DSV, "Texture2DMS"), |
| 740 | ("D3D11_DSV_DIMENSION_TEXTURE2DMSARRAY", D3D11_TEX2DMS_ARRAY_DSV, "Texture2DMSArray"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 741 | ]), None), |
| 742 | ]) |
| 743 | |
| 744 | ID3D11DepthStencilView.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 745 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_DEPTH_STENCIL_VIEW_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 746 | ] |
| 747 | |
| 748 | D3D11_BUFFER_UAV_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 749 | "D3D11_BUFFER_UAV_FLAG_RAW", |
| 750 | "D3D11_BUFFER_UAV_FLAG_APPEND", |
| 751 | "D3D11_BUFFER_UAV_FLAG_COUNTER", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 752 | ]) |
| 753 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 754 | D3D11_BUFFER_UAV = Struct("D3D11_BUFFER_UAV", [ |
| 755 | (UINT, "FirstElement"), |
| 756 | (UINT, "NumElements"), |
| 757 | (D3D11_BUFFER_UAV_FLAG, "Flags"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 758 | ]) |
| 759 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 760 | D3D11_TEX1D_UAV = Struct("D3D11_TEX1D_UAV", [ |
| 761 | (UINT, "MipSlice"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 762 | ]) |
| 763 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 764 | D3D11_TEX1D_ARRAY_UAV = Struct("D3D11_TEX1D_ARRAY_UAV", [ |
| 765 | (UINT, "MipSlice"), |
| 766 | (UINT, "FirstArraySlice"), |
| 767 | (UINT, "ArraySize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 768 | ]) |
| 769 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 770 | D3D11_TEX2D_UAV = Struct("D3D11_TEX2D_UAV", [ |
| 771 | (UINT, "MipSlice"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 772 | ]) |
| 773 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 774 | D3D11_TEX2D_ARRAY_UAV = Struct("D3D11_TEX2D_ARRAY_UAV", [ |
| 775 | (UINT, "MipSlice"), |
| 776 | (UINT, "FirstArraySlice"), |
| 777 | (UINT, "ArraySize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 778 | ]) |
| 779 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 780 | D3D11_TEX3D_UAV = Struct("D3D11_TEX3D_UAV", [ |
| 781 | (UINT, "MipSlice"), |
| 782 | (UINT, "FirstWSlice"), |
| 783 | (UINT, "WSize"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 784 | ]) |
| 785 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 786 | D3D11_UNORDERED_ACCESS_VIEW_DESC = Struct("D3D11_UNORDERED_ACCESS_VIEW_DESC", [ |
| 787 | (DXGI_FORMAT, "Format"), |
| 788 | (D3D11_UAV_DIMENSION, "ViewDimension"), |
José Fonseca | dbf714b | 2012-11-20 17:03:43 +0000 | [diff] [blame] | 789 | (Union("{self}.ViewDimension", [ |
| 790 | ("D3D11_UAV_DIMENSION_BUFFER", D3D11_BUFFER_UAV, "Buffer"), |
| 791 | ("D3D11_UAV_DIMENSION_TEXTURE1D", D3D11_TEX1D_UAV, "Texture1D"), |
| 792 | ("D3D11_UAV_DIMENSION_TEXTURE1DARRAY", D3D11_TEX1D_ARRAY_UAV, "Texture1DArray"), |
| 793 | ("D3D11_UAV_DIMENSION_TEXTURE2D", D3D11_TEX2D_UAV, "Texture2D"), |
| 794 | ("D3D11_UAV_DIMENSION_TEXTURE2DARRAY", D3D11_TEX2D_ARRAY_UAV, "Texture2DArray"), |
| 795 | ("D3D11_UAV_DIMENSION_TEXTURE3D", D3D11_TEX3D_UAV, "Texture3D"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 796 | ]), None), |
| 797 | ]) |
| 798 | |
| 799 | ID3D11UnorderedAccessView.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 800 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_UNORDERED_ACCESS_VIEW_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 801 | ] |
| 802 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 803 | D3D11_FILTER = Enum("D3D11_FILTER", [ |
| 804 | "D3D11_FILTER_MIN_MAG_MIP_POINT", |
| 805 | "D3D11_FILTER_MIN_MAG_POINT_MIP_LINEAR", |
| 806 | "D3D11_FILTER_MIN_POINT_MAG_LINEAR_MIP_POINT", |
| 807 | "D3D11_FILTER_MIN_POINT_MAG_MIP_LINEAR", |
| 808 | "D3D11_FILTER_MIN_LINEAR_MAG_MIP_POINT", |
| 809 | "D3D11_FILTER_MIN_LINEAR_MAG_POINT_MIP_LINEAR", |
| 810 | "D3D11_FILTER_MIN_MAG_LINEAR_MIP_POINT", |
| 811 | "D3D11_FILTER_MIN_MAG_MIP_LINEAR", |
| 812 | "D3D11_FILTER_ANISOTROPIC", |
| 813 | "D3D11_FILTER_COMPARISON_MIN_MAG_MIP_POINT", |
| 814 | "D3D11_FILTER_COMPARISON_MIN_MAG_POINT_MIP_LINEAR", |
| 815 | "D3D11_FILTER_COMPARISON_MIN_POINT_MAG_LINEAR_MIP_POINT", |
| 816 | "D3D11_FILTER_COMPARISON_MIN_POINT_MAG_MIP_LINEAR", |
| 817 | "D3D11_FILTER_COMPARISON_MIN_LINEAR_MAG_MIP_POINT", |
| 818 | "D3D11_FILTER_COMPARISON_MIN_LINEAR_MAG_POINT_MIP_LINEAR", |
| 819 | "D3D11_FILTER_COMPARISON_MIN_MAG_LINEAR_MIP_POINT", |
| 820 | "D3D11_FILTER_COMPARISON_MIN_MAG_MIP_LINEAR", |
| 821 | "D3D11_FILTER_COMPARISON_ANISOTROPIC", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 822 | ]) |
| 823 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 824 | D3D11_FILTER_TYPE = Enum("D3D11_FILTER_TYPE", [ |
| 825 | "D3D11_FILTER_TYPE_POINT", |
| 826 | "D3D11_FILTER_TYPE_LINEAR", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 827 | ]) |
| 828 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 829 | D3D11_TEXTURE_ADDRESS_MODE = Enum("D3D11_TEXTURE_ADDRESS_MODE", [ |
| 830 | "D3D11_TEXTURE_ADDRESS_WRAP", |
| 831 | "D3D11_TEXTURE_ADDRESS_MIRROR", |
| 832 | "D3D11_TEXTURE_ADDRESS_CLAMP", |
| 833 | "D3D11_TEXTURE_ADDRESS_BORDER", |
| 834 | "D3D11_TEXTURE_ADDRESS_MIRROR_ONCE", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 835 | ]) |
| 836 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 837 | D3D11_SAMPLER_DESC = Struct("D3D11_SAMPLER_DESC", [ |
| 838 | (D3D11_FILTER, "Filter"), |
| 839 | (D3D11_TEXTURE_ADDRESS_MODE, "AddressU"), |
| 840 | (D3D11_TEXTURE_ADDRESS_MODE, "AddressV"), |
| 841 | (D3D11_TEXTURE_ADDRESS_MODE, "AddressW"), |
| 842 | (FLOAT, "MipLODBias"), |
| 843 | (UINT, "MaxAnisotropy"), |
| 844 | (D3D11_COMPARISON_FUNC, "ComparisonFunc"), |
| 845 | (Array(FLOAT, 4), "BorderColor"), |
| 846 | (FLOAT, "MinLOD"), |
| 847 | (FLOAT, "MaxLOD"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 848 | ]) |
| 849 | |
| 850 | ID3D11SamplerState.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 851 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_SAMPLER_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 852 | ] |
| 853 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 854 | D3D11_FORMAT_SUPPORT = Flags(UINT, [ |
| 855 | "D3D11_FORMAT_SUPPORT_BUFFER", |
| 856 | "D3D11_FORMAT_SUPPORT_IA_VERTEX_BUFFER", |
| 857 | "D3D11_FORMAT_SUPPORT_IA_INDEX_BUFFER", |
| 858 | "D3D11_FORMAT_SUPPORT_SO_BUFFER", |
| 859 | "D3D11_FORMAT_SUPPORT_TEXTURE1D", |
| 860 | "D3D11_FORMAT_SUPPORT_TEXTURE2D", |
| 861 | "D3D11_FORMAT_SUPPORT_TEXTURE3D", |
| 862 | "D3D11_FORMAT_SUPPORT_TEXTURECUBE", |
| 863 | "D3D11_FORMAT_SUPPORT_SHADER_LOAD", |
| 864 | "D3D11_FORMAT_SUPPORT_SHADER_SAMPLE", |
| 865 | "D3D11_FORMAT_SUPPORT_SHADER_SAMPLE_COMPARISON", |
| 866 | "D3D11_FORMAT_SUPPORT_SHADER_SAMPLE_MONO_TEXT", |
| 867 | "D3D11_FORMAT_SUPPORT_MIP", |
| 868 | "D3D11_FORMAT_SUPPORT_MIP_AUTOGEN", |
| 869 | "D3D11_FORMAT_SUPPORT_RENDER_TARGET", |
| 870 | "D3D11_FORMAT_SUPPORT_BLENDABLE", |
| 871 | "D3D11_FORMAT_SUPPORT_DEPTH_STENCIL", |
| 872 | "D3D11_FORMAT_SUPPORT_CPU_LOCKABLE", |
| 873 | "D3D11_FORMAT_SUPPORT_MULTISAMPLE_RESOLVE", |
| 874 | "D3D11_FORMAT_SUPPORT_DISPLAY", |
| 875 | "D3D11_FORMAT_SUPPORT_CAST_WITHIN_BIT_LAYOUT", |
| 876 | "D3D11_FORMAT_SUPPORT_MULTISAMPLE_RENDERTARGET", |
| 877 | "D3D11_FORMAT_SUPPORT_MULTISAMPLE_LOAD", |
| 878 | "D3D11_FORMAT_SUPPORT_SHADER_GATHER", |
| 879 | "D3D11_FORMAT_SUPPORT_BACK_BUFFER_CAST", |
| 880 | "D3D11_FORMAT_SUPPORT_TYPED_UNORDERED_ACCESS_VIEW", |
| 881 | "D3D11_FORMAT_SUPPORT_SHADER_GATHER_COMPARISON", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 882 | ]) |
| 883 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 884 | D3D11_FORMAT_SUPPORT2 = Enum("D3D11_FORMAT_SUPPORT2", [ |
| 885 | "D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_ADD", |
| 886 | "D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_BITWISE_OPS", |
| 887 | "D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_COMPARE_STORE_OR_COMPARE_EXCHANGE", |
| 888 | "D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_EXCHANGE", |
| 889 | "D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_SIGNED_MIN_OR_MAX", |
| 890 | "D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_UNSIGNED_MIN_OR_MAX", |
| 891 | "D3D11_FORMAT_SUPPORT2_UAV_TYPED_LOAD", |
| 892 | "D3D11_FORMAT_SUPPORT2_UAV_TYPED_STORE", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 893 | ]) |
| 894 | |
| 895 | ID3D11Asynchronous.methods += [ |
José Fonseca | bc10e45 | 2012-11-08 10:24:45 +0000 | [diff] [blame] | 896 | StdMethod(UINT, "GetDataSize", [], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 897 | ] |
| 898 | |
| 899 | D3D11_ASYNC_GETDATA_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 900 | "D3D11_ASYNC_GETDATA_DONOTFLUSH", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 901 | ]) |
| 902 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 903 | D3D11_QUERY = Enum("D3D11_QUERY", [ |
| 904 | "D3D11_QUERY_EVENT", |
| 905 | "D3D11_QUERY_OCCLUSION", |
| 906 | "D3D11_QUERY_TIMESTAMP", |
| 907 | "D3D11_QUERY_TIMESTAMP_DISJOINT", |
| 908 | "D3D11_QUERY_PIPELINE_STATISTICS", |
| 909 | "D3D11_QUERY_OCCLUSION_PREDICATE", |
| 910 | "D3D11_QUERY_SO_STATISTICS", |
| 911 | "D3D11_QUERY_SO_OVERFLOW_PREDICATE", |
| 912 | "D3D11_QUERY_SO_STATISTICS_STREAM0", |
| 913 | "D3D11_QUERY_SO_OVERFLOW_PREDICATE_STREAM0", |
| 914 | "D3D11_QUERY_SO_STATISTICS_STREAM1", |
| 915 | "D3D11_QUERY_SO_OVERFLOW_PREDICATE_STREAM1", |
| 916 | "D3D11_QUERY_SO_STATISTICS_STREAM2", |
| 917 | "D3D11_QUERY_SO_OVERFLOW_PREDICATE_STREAM2", |
| 918 | "D3D11_QUERY_SO_STATISTICS_STREAM3", |
| 919 | "D3D11_QUERY_SO_OVERFLOW_PREDICATE_STREAM3", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 920 | ]) |
| 921 | |
| 922 | D3D11_QUERY_MISC_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 923 | "D3D11_QUERY_MISC_PREDICATEHINT", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 924 | ]) |
| 925 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 926 | D3D11_QUERY_DESC = Struct("D3D11_QUERY_DESC", [ |
| 927 | (D3D11_QUERY, "Query"), |
| 928 | (D3D11_QUERY_MISC_FLAG, "MiscFlags"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 929 | ]) |
| 930 | |
| 931 | ID3D11Query.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 932 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_QUERY_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 933 | ] |
| 934 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 935 | D3D11_QUERY_DATA_TIMESTAMP_DISJOINT = Struct("D3D11_QUERY_DATA_TIMESTAMP_DISJOINT", [ |
| 936 | (UINT64, "Frequency"), |
| 937 | (BOOL, "Disjoint"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 938 | ]) |
| 939 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 940 | D3D11_QUERY_DATA_PIPELINE_STATISTICS = Struct("D3D11_QUERY_DATA_PIPELINE_STATISTICS", [ |
| 941 | (UINT64, "IAVertices"), |
| 942 | (UINT64, "IAPrimitives"), |
| 943 | (UINT64, "VSInvocations"), |
| 944 | (UINT64, "GSInvocations"), |
| 945 | (UINT64, "GSPrimitives"), |
| 946 | (UINT64, "CInvocations"), |
| 947 | (UINT64, "CPrimitives"), |
| 948 | (UINT64, "PSInvocations"), |
| 949 | (UINT64, "HSInvocations"), |
| 950 | (UINT64, "DSInvocations"), |
| 951 | (UINT64, "CSInvocations"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 952 | ]) |
| 953 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 954 | D3D11_QUERY_DATA_SO_STATISTICS = Struct("D3D11_QUERY_DATA_SO_STATISTICS", [ |
| 955 | (UINT64, "NumPrimitivesWritten"), |
| 956 | (UINT64, "PrimitivesStorageNeeded"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 957 | ]) |
| 958 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 959 | D3D11_COUNTER = Enum("D3D11_COUNTER", [ |
| 960 | "D3D11_COUNTER_DEVICE_DEPENDENT_0", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 961 | ]) |
| 962 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 963 | D3D11_COUNTER_TYPE = Enum("D3D11_COUNTER_TYPE", [ |
| 964 | "D3D11_COUNTER_TYPE_FLOAT32", |
| 965 | "D3D11_COUNTER_TYPE_UINT16", |
| 966 | "D3D11_COUNTER_TYPE_UINT32", |
| 967 | "D3D11_COUNTER_TYPE_UINT64", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 968 | ]) |
| 969 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 970 | D3D11_COUNTER_DESC = Struct("D3D11_COUNTER_DESC", [ |
| 971 | (D3D11_COUNTER, "Counter"), |
| 972 | (UINT, "MiscFlags"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 973 | ]) |
| 974 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 975 | D3D11_COUNTER_INFO = Struct("D3D11_COUNTER_INFO", [ |
| 976 | (D3D11_COUNTER, "LastDeviceDependentCounter"), |
| 977 | (UINT, "NumSimultaneousCounters"), |
| 978 | (UINT8, "NumDetectableParallelUnits"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 979 | ]) |
| 980 | |
| 981 | ID3D11Counter.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 982 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_COUNTER_DESC), "pDesc")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 983 | ] |
| 984 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 985 | D3D11_STANDARD_MULTISAMPLE_QUALITY_LEVELS = Enum("D3D11_STANDARD_MULTISAMPLE_QUALITY_LEVELS", [ |
| 986 | "D3D11_STANDARD_MULTISAMPLE_PATTERN", |
| 987 | "D3D11_CENTER_MULTISAMPLE_PATTERN", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 988 | ]) |
| 989 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 990 | D3D11_DEVICE_CONTEXT_TYPE = Enum("D3D11_DEVICE_CONTEXT_TYPE", [ |
| 991 | "D3D11_DEVICE_CONTEXT_IMMEDIATE", |
| 992 | "D3D11_DEVICE_CONTEXT_DEFERRED", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 993 | ]) |
| 994 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 995 | D3D11_CLASS_INSTANCE_DESC = Struct("D3D11_CLASS_INSTANCE_DESC", [ |
| 996 | (UINT, "InstanceId"), |
| 997 | (UINT, "InstanceIndex"), |
| 998 | (UINT, "TypeId"), |
| 999 | (UINT, "ConstantBuffer"), |
| 1000 | (UINT, "BaseConstantBufferOffset"), |
| 1001 | (UINT, "BaseTexture"), |
| 1002 | (UINT, "BaseSampler"), |
| 1003 | (BOOL, "Created"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1004 | ]) |
| 1005 | |
| 1006 | |
| 1007 | ID3D11ClassInstance.methods += [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1008 | StdMethod(Void, "GetClassLinkage", [Out(Pointer(ObjPointer(ID3D11ClassLinkage)), "ppLinkage")]), |
José Fonseca | bc10e45 | 2012-11-08 10:24:45 +0000 | [diff] [blame] | 1009 | StdMethod(Void, "GetDesc", [Out(Pointer(D3D11_CLASS_INSTANCE_DESC), "pDesc")], sideeffects=False), |
| 1010 | StdMethod(Void, "GetInstanceName", [Out(LPSTR, "pInstanceName"), Out(Pointer(SIZE_T), "pBufferLength")], sideeffects=False), |
| 1011 | StdMethod(Void, "GetTypeName", [Out(LPSTR, "pTypeName"), Out(Pointer(SIZE_T), "pBufferLength")], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1012 | ] |
| 1013 | |
| 1014 | ID3D11ClassLinkage.methods += [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1015 | StdMethod(HRESULT, "GetClassInstance", [(LPCSTR, "pClassInstanceName"), (UINT, "InstanceIndex"), Out(Pointer(ObjPointer(ID3D11ClassInstance)), "ppInstance")]), |
| 1016 | StdMethod(HRESULT, "CreateClassInstance", [(LPCSTR, "pClassTypeName"), (UINT, "ConstantBufferOffset"), (UINT, "ConstantVectorOffset"), (UINT, "TextureOffset"), (UINT, "SamplerOffset"), Out(Pointer(ObjPointer(ID3D11ClassInstance)), "ppInstance")]), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1017 | ] |
| 1018 | |
| 1019 | ID3D11CommandList.methods += [ |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 1020 | StdMethod(UINT, "GetContextFlags", [], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1021 | ] |
| 1022 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1023 | D3D11_FEATURE_DATA_THREADING = Struct("D3D11_FEATURE_DATA_THREADING", [ |
| 1024 | (BOOL, "DriverConcurrentCreates"), |
| 1025 | (BOOL, "DriverCommandLists"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1026 | ]) |
| 1027 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1028 | D3D11_FEATURE_DATA_DOUBLES = Struct("D3D11_FEATURE_DATA_DOUBLES", [ |
| 1029 | (BOOL, "DoublePrecisionFloatShaderOps"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1030 | ]) |
| 1031 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1032 | D3D11_FEATURE_DATA_FORMAT_SUPPORT = Struct("D3D11_FEATURE_DATA_FORMAT_SUPPORT", [ |
| 1033 | (DXGI_FORMAT, "InFormat"), |
| 1034 | (D3D11_FORMAT_SUPPORT, "OutFormatSupport"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1035 | ]) |
| 1036 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1037 | D3D11_FEATURE_DATA_FORMAT_SUPPORT2 = Struct("D3D11_FEATURE_DATA_FORMAT_SUPPORT2", [ |
| 1038 | (DXGI_FORMAT, "InFormat"), |
| 1039 | (D3D11_FORMAT_SUPPORT2, "OutFormatSupport2"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1040 | ]) |
| 1041 | |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1042 | D3D11_FEATURE_DATA_D3D10_X_HARDWARE_OPTIONS = Struct("D3D11_FEATURE_DATA_D3D10_X_HARDWARE_OPTIONS", [ |
| 1043 | (BOOL, "ComputeShaders_Plus_RawAndStructuredBuffers_Via_Shader_4_x"), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1044 | ]) |
| 1045 | |
José Fonseca | b95e372 | 2012-04-16 14:01:15 +0100 | [diff] [blame] | 1046 | D3D11_FEATURE, D3D11_FEATURE_DATA = EnumPolymorphic("D3D11_FEATURE", "Feature", [ |
| 1047 | ("D3D11_FEATURE_THREADING", Pointer(D3D11_FEATURE_DATA_THREADING)), |
| 1048 | ("D3D11_FEATURE_DOUBLES", Pointer(D3D11_FEATURE_DATA_DOUBLES)), |
| 1049 | ("D3D11_FEATURE_FORMAT_SUPPORT", Pointer(D3D11_FEATURE_DATA_FORMAT_SUPPORT)), |
| 1050 | ("D3D11_FEATURE_FORMAT_SUPPORT2", Pointer(D3D11_FEATURE_DATA_FORMAT_SUPPORT2)), |
| 1051 | ("D3D11_FEATURE_D3D10_X_HARDWARE_OPTIONS", Pointer(D3D11_FEATURE_DATA_D3D10_X_HARDWARE_OPTIONS)), |
| 1052 | ], Blob(Void, "FeatureSupportDataSize"), False) |
| 1053 | |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1054 | ID3D11DeviceContext.methods += [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1055 | StdMethod(Void, "VSSetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), (Array(Const(ObjPointer(ID3D11Buffer)), "NumBuffers"), "ppConstantBuffers")]), |
| 1056 | StdMethod(Void, "PSSetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), (Array(Const(ObjPointer(ID3D11ShaderResourceView)), "NumViews"), "ppShaderResourceViews")]), |
| 1057 | StdMethod(Void, "PSSetShader", [(ObjPointer(ID3D11PixelShader), "pPixelShader"), (Array(Const(ObjPointer(ID3D11ClassInstance)), "NumClassInstances"), "ppClassInstances"), (UINT, "NumClassInstances")]), |
| 1058 | StdMethod(Void, "PSSetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), (Array(Const(ObjPointer(ID3D11SamplerState)), "NumSamplers"), "ppSamplers")]), |
| 1059 | StdMethod(Void, "VSSetShader", [(ObjPointer(ID3D11VertexShader), "pVertexShader"), (Array(Const(ObjPointer(ID3D11ClassInstance)), "NumClassInstances"), "ppClassInstances"), (UINT, "NumClassInstances")]), |
| 1060 | StdMethod(Void, "DrawIndexed", [(UINT, "IndexCount"), (UINT, "StartIndexLocation"), (INT, "BaseVertexLocation")]), |
| 1061 | StdMethod(Void, "Draw", [(UINT, "VertexCount"), (UINT, "StartVertexLocation")]), |
| 1062 | StdMethod(HRESULT, "Map", [(ObjPointer(ID3D11Resource), "pResource"), (UINT, "Subresource"), (D3D11_MAP, "MapType"), (D3D11_MAP_FLAG, "MapFlags"), Out(Pointer(D3D11_MAPPED_SUBRESOURCE), "pMappedResource")]), |
| 1063 | StdMethod(Void, "Unmap", [(ObjPointer(ID3D11Resource), "pResource"), (UINT, "Subresource")]), |
| 1064 | StdMethod(Void, "PSSetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), (Array(Const(ObjPointer(ID3D11Buffer)), "NumBuffers"), "ppConstantBuffers")]), |
| 1065 | StdMethod(Void, "IASetInputLayout", [(ObjPointer(ID3D11InputLayout), "pInputLayout")]), |
José Fonseca | 9243aa6 | 2012-11-16 19:13:20 +0000 | [diff] [blame] | 1066 | StdMethod(Void, "IASetVertexBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), (Array(Const(ObjPointer(ID3D11Buffer)), "NumBuffers"), "ppVertexBuffers"), (Array(Const(UINT), "NumBuffers"), "pStrides"), (Array(Const(UINT), "NumBuffers"), "pOffsets")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1067 | StdMethod(Void, "IASetIndexBuffer", [(ObjPointer(ID3D11Buffer), "pIndexBuffer"), (DXGI_FORMAT, "Format"), (UINT, "Offset")]), |
| 1068 | StdMethod(Void, "DrawIndexedInstanced", [(UINT, "IndexCountPerInstance"), (UINT, "InstanceCount"), (UINT, "StartIndexLocation"), (INT, "BaseVertexLocation"), (UINT, "StartInstanceLocation")]), |
| 1069 | StdMethod(Void, "DrawInstanced", [(UINT, "VertexCountPerInstance"), (UINT, "InstanceCount"), (UINT, "StartVertexLocation"), (UINT, "StartInstanceLocation")]), |
| 1070 | StdMethod(Void, "GSSetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), (Array(Const(ObjPointer(ID3D11Buffer)), "NumBuffers"), "ppConstantBuffers")]), |
| 1071 | StdMethod(Void, "GSSetShader", [(ObjPointer(ID3D11GeometryShader), "pShader"), (Array(Const(ObjPointer(ID3D11ClassInstance)), "NumClassInstances"), "ppClassInstances"), (UINT, "NumClassInstances")]), |
| 1072 | StdMethod(Void, "IASetPrimitiveTopology", [(D3D11_PRIMITIVE_TOPOLOGY, "Topology")]), |
| 1073 | StdMethod(Void, "VSSetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), (Array(Const(ObjPointer(ID3D11ShaderResourceView)), "NumViews"), "ppShaderResourceViews")]), |
| 1074 | StdMethod(Void, "VSSetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), (Array(Const(ObjPointer(ID3D11SamplerState)), "NumSamplers"), "ppSamplers")]), |
| 1075 | StdMethod(Void, "Begin", [(ObjPointer(ID3D11Asynchronous), "pAsync")]), |
| 1076 | StdMethod(Void, "End", [(ObjPointer(ID3D11Asynchronous), "pAsync")]), |
José Fonseca | bc10e45 | 2012-11-08 10:24:45 +0000 | [diff] [blame] | 1077 | StdMethod(HRESULT, "GetData", [(ObjPointer(ID3D11Asynchronous), "pAsync"), Out(OpaqueBlob(Void, "DataSize"), "pData"), (UINT, "DataSize"), (D3D11_ASYNC_GETDATA_FLAG, "GetDataFlags")], sideeffects=False), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1078 | StdMethod(Void, "SetPredication", [(ObjPointer(ID3D11Predicate), "pPredicate"), (BOOL, "PredicateValue")]), |
| 1079 | StdMethod(Void, "GSSetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), (Array(Const(ObjPointer(ID3D11ShaderResourceView)), "NumViews"), "ppShaderResourceViews")]), |
| 1080 | StdMethod(Void, "GSSetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), (Array(Const(ObjPointer(ID3D11SamplerState)), "NumSamplers"), "ppSamplers")]), |
| 1081 | StdMethod(Void, "OMSetRenderTargets", [(UINT, "NumViews"), (Array(Const(ObjPointer(ID3D11RenderTargetView)), "NumViews"), "ppRenderTargetViews"), (ObjPointer(ID3D11DepthStencilView), "pDepthStencilView")]), |
José Fonseca | 9243aa6 | 2012-11-16 19:13:20 +0000 | [diff] [blame] | 1082 | StdMethod(Void, "OMSetRenderTargetsAndUnorderedAccessViews", [(UINT, "NumRTVs"), (Array(Const(ObjPointer(ID3D11RenderTargetView)), "NumRTVs"), "ppRenderTargetViews"), (ObjPointer(ID3D11DepthStencilView), "pDepthStencilView"), (UINT, "UAVStartSlot"), (UINT, "NumUAVs"), (Array(Const(ObjPointer(ID3D11UnorderedAccessView)), "NumUAVs"), "ppUnorderedAccessViews"), (Array(Const(UINT), "NumUAVs"), "pUAVInitialCounts")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1083 | StdMethod(Void, "OMSetBlendState", [(ObjPointer(ID3D11BlendState), "pBlendState"), (Array(Const(FLOAT), 4), "BlendFactor"), (UINT, "SampleMask")]), |
| 1084 | StdMethod(Void, "OMSetDepthStencilState", [(ObjPointer(ID3D11DepthStencilState), "pDepthStencilState"), (UINT, "StencilRef")]), |
José Fonseca | 9243aa6 | 2012-11-16 19:13:20 +0000 | [diff] [blame] | 1085 | StdMethod(Void, "SOSetTargets", [(UINT, "NumBuffers"), (Array(Const(ObjPointer(ID3D11Buffer)), "NumBuffers"), "ppSOTargets"), (Array(Const(UINT), "NumBuffers"), "pOffsets")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1086 | StdMethod(Void, "DrawAuto", []), |
| 1087 | StdMethod(Void, "DrawIndexedInstancedIndirect", [(ObjPointer(ID3D11Buffer), "pBufferForArgs"), (UINT, "AlignedByteOffsetForArgs")]), |
| 1088 | StdMethod(Void, "DrawInstancedIndirect", [(ObjPointer(ID3D11Buffer), "pBufferForArgs"), (UINT, "AlignedByteOffsetForArgs")]), |
| 1089 | StdMethod(Void, "Dispatch", [(UINT, "ThreadGroupCountX"), (UINT, "ThreadGroupCountY"), (UINT, "ThreadGroupCountZ")]), |
| 1090 | StdMethod(Void, "DispatchIndirect", [(ObjPointer(ID3D11Buffer), "pBufferForArgs"), (UINT, "AlignedByteOffsetForArgs")]), |
| 1091 | StdMethod(Void, "RSSetState", [(ObjPointer(ID3D11RasterizerState), "pRasterizerState")]), |
| 1092 | StdMethod(Void, "RSSetViewports", [(UINT, "NumViewports"), (Array(Const(D3D11_VIEWPORT), "NumViewports"), "pViewports")]), |
| 1093 | StdMethod(Void, "RSSetScissorRects", [(UINT, "NumRects"), (Array(Const(D3D11_RECT), "NumRects"), "pRects")]), |
| 1094 | StdMethod(Void, "CopySubresourceRegion", [(ObjPointer(ID3D11Resource), "pDstResource"), (UINT, "DstSubresource"), (UINT, "DstX"), (UINT, "DstY"), (UINT, "DstZ"), (ObjPointer(ID3D11Resource), "pSrcResource"), (UINT, "SrcSubresource"), (Pointer(Const(D3D11_BOX)), "pSrcBox")]), |
| 1095 | StdMethod(Void, "CopyResource", [(ObjPointer(ID3D11Resource), "pDstResource"), (ObjPointer(ID3D11Resource), "pSrcResource")]), |
José Fonseca | cc9abd7 | 2012-11-08 10:47:18 +0000 | [diff] [blame] | 1096 | StdMethod(Void, "UpdateSubresource", [(ObjPointer(ID3D11Resource), "pDstResource"), (UINT, "DstSubresource"), (Pointer(Const(D3D11_BOX)), "pDstBox"), (Blob(Const(Void), "_calcSubresourceSize(pDstResource, DstSubresource, pDstBox, SrcRowPitch, SrcDepthPitch)"), "pSrcData"), (UINT, "SrcRowPitch"), (UINT, "SrcDepthPitch")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1097 | StdMethod(Void, "CopyStructureCount", [(ObjPointer(ID3D11Buffer), "pDstBuffer"), (UINT, "DstAlignedByteOffset"), (ObjPointer(ID3D11UnorderedAccessView), "pSrcView")]), |
| 1098 | StdMethod(Void, "ClearRenderTargetView", [(ObjPointer(ID3D11RenderTargetView), "pRenderTargetView"), (Array(Const(FLOAT), 4), "ColorRGBA")]), |
| 1099 | StdMethod(Void, "ClearUnorderedAccessViewUint", [(ObjPointer(ID3D11UnorderedAccessView), "pUnorderedAccessView"), (Array(Const(UINT), 4), "Values")]), |
| 1100 | StdMethod(Void, "ClearUnorderedAccessViewFloat", [(ObjPointer(ID3D11UnorderedAccessView), "pUnorderedAccessView"), (Array(Const(FLOAT), 4), "Values")]), |
| 1101 | StdMethod(Void, "ClearDepthStencilView", [(ObjPointer(ID3D11DepthStencilView), "pDepthStencilView"), (D3D11_CLEAR_FLAG, "ClearFlags"), (FLOAT, "Depth"), (UINT8, "Stencil")]), |
| 1102 | StdMethod(Void, "GenerateMips", [(ObjPointer(ID3D11ShaderResourceView), "pShaderResourceView")]), |
| 1103 | StdMethod(Void, "SetResourceMinLOD", [(ObjPointer(ID3D11Resource), "pResource"), (FLOAT, "MinLOD")]), |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 1104 | StdMethod(FLOAT, "GetResourceMinLOD", [(ObjPointer(ID3D11Resource), "pResource")], sideeffects=False), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1105 | StdMethod(Void, "ResolveSubresource", [(ObjPointer(ID3D11Resource), "pDstResource"), (UINT, "DstSubresource"), (ObjPointer(ID3D11Resource), "pSrcResource"), (UINT, "SrcSubresource"), (DXGI_FORMAT, "Format")]), |
| 1106 | StdMethod(Void, "ExecuteCommandList", [(ObjPointer(ID3D11CommandList), "pCommandList"), (BOOL, "RestoreContextState")]), |
| 1107 | StdMethod(Void, "HSSetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), (Array(Const(ObjPointer(ID3D11ShaderResourceView)), "NumViews"), "ppShaderResourceViews")]), |
| 1108 | StdMethod(Void, "HSSetShader", [(ObjPointer(ID3D11HullShader), "pHullShader"), (Array(Const(ObjPointer(ID3D11ClassInstance)), "NumClassInstances"), "ppClassInstances"), (UINT, "NumClassInstances")]), |
| 1109 | StdMethod(Void, "HSSetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), (Array(Const(ObjPointer(ID3D11SamplerState)), "NumSamplers"), "ppSamplers")]), |
| 1110 | StdMethod(Void, "HSSetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), (Array(Const(ObjPointer(ID3D11Buffer)), "NumBuffers"), "ppConstantBuffers")]), |
| 1111 | StdMethod(Void, "DSSetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), (Array(Const(ObjPointer(ID3D11ShaderResourceView)), "NumViews"), "ppShaderResourceViews")]), |
| 1112 | StdMethod(Void, "DSSetShader", [(ObjPointer(ID3D11DomainShader), "pDomainShader"), (Array(Const(ObjPointer(ID3D11ClassInstance)), "NumClassInstances"), "ppClassInstances"), (UINT, "NumClassInstances")]), |
| 1113 | StdMethod(Void, "DSSetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), (Array(Const(ObjPointer(ID3D11SamplerState)), "NumSamplers"), "ppSamplers")]), |
| 1114 | StdMethod(Void, "DSSetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), (Array(Const(ObjPointer(ID3D11Buffer)), "NumBuffers"), "ppConstantBuffers")]), |
| 1115 | StdMethod(Void, "CSSetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), (Array(Const(ObjPointer(ID3D11ShaderResourceView)), "NumViews"), "ppShaderResourceViews")]), |
José Fonseca | 9243aa6 | 2012-11-16 19:13:20 +0000 | [diff] [blame] | 1116 | StdMethod(Void, "CSSetUnorderedAccessViews", [(UINT, "StartSlot"), (UINT, "NumUAVs"), (Array(Const(ObjPointer(ID3D11UnorderedAccessView)), "NumUAVs"), "ppUnorderedAccessViews"), (Array(Const(UINT), "NumUAVs"), "pUAVInitialCounts")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1117 | StdMethod(Void, "CSSetShader", [(ObjPointer(ID3D11ComputeShader), "pComputeShader"), (Array(Const(ObjPointer(ID3D11ClassInstance)), "NumClassInstances"), "ppClassInstances"), (UINT, "NumClassInstances")]), |
| 1118 | StdMethod(Void, "CSSetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), (Array(Const(ObjPointer(ID3D11SamplerState)), "NumSamplers"), "ppSamplers")]), |
| 1119 | StdMethod(Void, "CSSetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), (Array(Const(ObjPointer(ID3D11Buffer)), "NumBuffers"), "ppConstantBuffers")]), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1120 | StdMethod(Void, "VSGetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), Out(Array(ObjPointer(ID3D11Buffer), "NumBuffers"), "ppConstantBuffers")]), |
| 1121 | StdMethod(Void, "PSGetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), Out(Array(ObjPointer(ID3D11ShaderResourceView), "NumViews"), "ppShaderResourceViews")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1122 | StdMethod(Void, "PSGetShader", [Out(Pointer(ObjPointer(ID3D11PixelShader)), "ppPixelShader"), Out(Array(ObjPointer(ID3D11ClassInstance), "*pNumClassInstances"), "ppClassInstances"), Out(Pointer(UINT), "pNumClassInstances")]), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1123 | StdMethod(Void, "PSGetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), Out(Array(ObjPointer(ID3D11SamplerState), "NumSamplers"), "ppSamplers")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1124 | StdMethod(Void, "VSGetShader", [Out(Pointer(ObjPointer(ID3D11VertexShader)), "ppVertexShader"), Out(Array(ObjPointer(ID3D11ClassInstance), "*pNumClassInstances"), "ppClassInstances"), Out(Pointer(UINT), "pNumClassInstances")]), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1125 | StdMethod(Void, "PSGetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), Out(Array(ObjPointer(ID3D11Buffer), "NumBuffers"), "ppConstantBuffers")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1126 | StdMethod(Void, "IAGetInputLayout", [Out(Pointer(ObjPointer(ID3D11InputLayout)), "ppInputLayout")]), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1127 | StdMethod(Void, "IAGetVertexBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), Out(Array(ObjPointer(ID3D11Buffer), "NumBuffers"), "ppVertexBuffers"), Out(Array(UINT, "NumBuffers"), "pStrides"), Out(Array(UINT, "NumBuffers"), "pOffsets")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1128 | StdMethod(Void, "IAGetIndexBuffer", [Out(Pointer(ObjPointer(ID3D11Buffer)), "pIndexBuffer"), Out(Pointer(DXGI_FORMAT), "Format"), Out(Pointer(UINT), "Offset")]), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1129 | StdMethod(Void, "GSGetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), Out(Array(ObjPointer(ID3D11Buffer), "NumBuffers"), "ppConstantBuffers")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1130 | StdMethod(Void, "GSGetShader", [Out(Pointer(ObjPointer(ID3D11GeometryShader)), "ppGeometryShader"), Out(Array(ObjPointer(ID3D11ClassInstance), "*pNumClassInstances"), "ppClassInstances"), Out(Pointer(UINT), "pNumClassInstances")]), |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 1131 | StdMethod(Void, "IAGetPrimitiveTopology", [Out(Pointer(D3D11_PRIMITIVE_TOPOLOGY), "pTopology")], sideeffects=False), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1132 | StdMethod(Void, "VSGetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), Out(Array(ObjPointer(ID3D11ShaderResourceView), "NumViews"), "ppShaderResourceViews")]), |
| 1133 | StdMethod(Void, "VSGetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), Out(Array(ObjPointer(ID3D11SamplerState), "NumSamplers"), "ppSamplers")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1134 | StdMethod(Void, "GetPredication", [Out(Pointer(ObjPointer(ID3D11Predicate)), "ppPredicate"), Out(Pointer(BOOL), "pPredicateValue")]), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1135 | StdMethod(Void, "GSGetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), Out(Array(ObjPointer(ID3D11ShaderResourceView), "NumViews"), "ppShaderResourceViews")]), |
| 1136 | StdMethod(Void, "GSGetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), Out(Array(ObjPointer(ID3D11SamplerState), "NumSamplers"), "ppSamplers")]), |
| 1137 | StdMethod(Void, "OMGetRenderTargets", [(UINT, "NumViews"), Out(Array(ObjPointer(ID3D11RenderTargetView), "NumViews"), "ppRenderTargetViews"), Out(Pointer(ObjPointer(ID3D11DepthStencilView)), "ppDepthStencilView")]), |
| 1138 | StdMethod(Void, "OMGetRenderTargetsAndUnorderedAccessViews", [(UINT, "NumRTVs"), Out(Array(ObjPointer(ID3D11RenderTargetView), "NumRTVs"), "ppRenderTargetViews"), Out(Pointer(ObjPointer(ID3D11DepthStencilView)), "ppDepthStencilView"), (UINT, "UAVStartSlot"), (UINT, "NumUAVs"), Out(Array(ObjPointer(ID3D11UnorderedAccessView), "NumUAVs"), "ppUnorderedAccessViews")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1139 | StdMethod(Void, "OMGetBlendState", [Out(Pointer(ObjPointer(ID3D11BlendState)), "ppBlendState"), Out(Array(FLOAT, 4), "BlendFactor"), Out(Pointer(UINT), "pSampleMask")]), |
| 1140 | StdMethod(Void, "OMGetDepthStencilState", [Out(Pointer(ObjPointer(ID3D11DepthStencilState)), "ppDepthStencilState"), Out(Pointer(UINT), "pStencilRef")]), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1141 | StdMethod(Void, "SOGetTargets", [(UINT, "NumBuffers"), Out(Array(ObjPointer(ID3D11Buffer), "NumBuffers"), "ppSOTargets")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1142 | StdMethod(Void, "RSGetState", [Out(Pointer(ObjPointer(ID3D11RasterizerState)), "ppRasterizerState")]), |
| 1143 | StdMethod(Void, "RSGetViewports", [Out(Pointer(UINT), "pNumViewports"), Out(Array(D3D11_VIEWPORT, "*pNumViewports"), "pViewports")]), |
| 1144 | StdMethod(Void, "RSGetScissorRects", [Out(Pointer(UINT), "pNumRects"), Out(Array(D3D11_RECT, "*pNumRects"), "pRects")]), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1145 | StdMethod(Void, "HSGetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), Out(Array(ObjPointer(ID3D11ShaderResourceView), "NumViews"), "ppShaderResourceViews")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1146 | StdMethod(Void, "HSGetShader", [Out(Pointer(ObjPointer(ID3D11HullShader)), "ppHullShader"), Out(Array(ObjPointer(ID3D11ClassInstance), "*pNumClassInstances"), "ppClassInstances"), Out(Pointer(UINT), "pNumClassInstances")]), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1147 | StdMethod(Void, "HSGetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), Out(Array(ObjPointer(ID3D11SamplerState), "NumSamplers"), "ppSamplers")]), |
| 1148 | StdMethod(Void, "HSGetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), Out(Array(ObjPointer(ID3D11Buffer), "NumBuffers"), "ppConstantBuffers")]), |
| 1149 | StdMethod(Void, "DSGetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), Out(Array(ObjPointer(ID3D11ShaderResourceView), "NumViews"), "ppShaderResourceViews")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1150 | StdMethod(Void, "DSGetShader", [Out(Pointer(ObjPointer(ID3D11DomainShader)), "ppDomainShader"), Out(Array(ObjPointer(ID3D11ClassInstance), "*pNumClassInstances"), "ppClassInstances"), Out(Pointer(UINT), "pNumClassInstances")]), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1151 | StdMethod(Void, "DSGetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), Out(Array(ObjPointer(ID3D11SamplerState), "NumSamplers"), "ppSamplers")]), |
| 1152 | StdMethod(Void, "DSGetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), Out(Array(ObjPointer(ID3D11Buffer), "NumBuffers"), "ppConstantBuffers")]), |
| 1153 | StdMethod(Void, "CSGetShaderResources", [(UINT, "StartSlot"), (UINT, "NumViews"), Out(Array(ObjPointer(ID3D11ShaderResourceView), "NumViews"), "ppShaderResourceViews")]), |
| 1154 | StdMethod(Void, "CSGetUnorderedAccessViews", [(UINT, "StartSlot"), (UINT, "NumUAVs"), Out(Array(ObjPointer(ID3D11UnorderedAccessView), "NumUAVs"), "ppUnorderedAccessViews")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1155 | StdMethod(Void, "CSGetShader", [Out(Pointer(ObjPointer(ID3D11ComputeShader)), "ppComputeShader"), Out(Array(ObjPointer(ID3D11ClassInstance), "*pNumClassInstances"), "ppClassInstances"), Out(Pointer(UINT), "pNumClassInstances")]), |
José Fonseca | 8ce19e4 | 2012-11-21 21:01:05 +0000 | [diff] [blame^] | 1156 | StdMethod(Void, "CSGetSamplers", [(UINT, "StartSlot"), (UINT, "NumSamplers"), Out(Array(ObjPointer(ID3D11SamplerState), "NumSamplers"), "ppSamplers")]), |
| 1157 | StdMethod(Void, "CSGetConstantBuffers", [(UINT, "StartSlot"), (UINT, "NumBuffers"), Out(Array(ObjPointer(ID3D11Buffer), "NumBuffers"), "ppConstantBuffers")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1158 | StdMethod(Void, "ClearState", []), |
| 1159 | StdMethod(Void, "Flush", []), |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 1160 | StdMethod(D3D11_DEVICE_CONTEXT_TYPE, "GetType", [], sideeffects=False), |
| 1161 | StdMethod(UINT, "GetContextFlags", [], sideeffects=False), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1162 | StdMethod(HRESULT, "FinishCommandList", [(BOOL, "RestoreDeferredContextState"), Out(Pointer(ObjPointer(ID3D11CommandList)), "ppCommandList")]), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1163 | ] |
| 1164 | |
| 1165 | D3D11_CREATE_DEVICE_FLAG = Flags(UINT, [ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1166 | "D3D11_CREATE_DEVICE_SINGLETHREADED", |
| 1167 | "D3D11_CREATE_DEVICE_DEBUG", |
| 1168 | "D3D11_CREATE_DEVICE_SWITCH_TO_REF", |
| 1169 | "D3D11_CREATE_DEVICE_PREVENT_INTERNAL_THREADING_OPTIMIZATIONS", |
| 1170 | "D3D11_CREATE_DEVICE_BGRA_SUPPORT", |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1171 | ]) |
| 1172 | |
| 1173 | ID3D11Device.methods += [ |
José Fonseca | 8f6e0e3 | 2012-11-07 19:22:20 +0000 | [diff] [blame] | 1174 | StdMethod(HRESULT, "CreateBuffer", [(Pointer(Const(D3D11_BUFFER_DESC)), "pDesc"), (Array(Const(D3D11_SUBRESOURCE_DATA), "1"), "pInitialData"), Out(Pointer(ObjPointer(ID3D11Buffer)), "ppBuffer")]), |
| 1175 | StdMethod(HRESULT, "CreateTexture1D", [(Pointer(Const(D3D11_TEXTURE1D_DESC)), "pDesc"), (Array(Const(D3D11_SUBRESOURCE_DATA), "_getNumSubResources(pDesc)"), "pInitialData"), Out(Pointer(ObjPointer(ID3D11Texture1D)), "ppTexture1D")]), |
| 1176 | StdMethod(HRESULT, "CreateTexture2D", [(Pointer(Const(D3D11_TEXTURE2D_DESC)), "pDesc"), (Array(Const(D3D11_SUBRESOURCE_DATA), "_getNumSubResources(pDesc)"), "pInitialData"), Out(Pointer(ObjPointer(ID3D11Texture2D)), "ppTexture2D")]), |
| 1177 | StdMethod(HRESULT, "CreateTexture3D", [(Pointer(Const(D3D11_TEXTURE3D_DESC)), "pDesc"), (Array(Const(D3D11_SUBRESOURCE_DATA), "_getNumSubResources(pDesc)"), "pInitialData"), Out(Pointer(ObjPointer(ID3D11Texture3D)), "ppTexture3D")]), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1178 | StdMethod(HRESULT, "CreateShaderResourceView", [(ObjPointer(ID3D11Resource), "pResource"), (Pointer(Const(D3D11_SHADER_RESOURCE_VIEW_DESC)), "pDesc"), Out(Pointer(ObjPointer(ID3D11ShaderResourceView)), "ppSRView")]), |
| 1179 | StdMethod(HRESULT, "CreateUnorderedAccessView", [(ObjPointer(ID3D11Resource), "pResource"), (Pointer(Const(D3D11_UNORDERED_ACCESS_VIEW_DESC)), "pDesc"), Out(Pointer(ObjPointer(ID3D11UnorderedAccessView)), "ppUAView")]), |
| 1180 | StdMethod(HRESULT, "CreateRenderTargetView", [(ObjPointer(ID3D11Resource), "pResource"), (Pointer(Const(D3D11_RENDER_TARGET_VIEW_DESC)), "pDesc"), Out(Pointer(ObjPointer(ID3D11RenderTargetView)), "ppRTView")]), |
| 1181 | StdMethod(HRESULT, "CreateDepthStencilView", [(ObjPointer(ID3D11Resource), "pResource"), (Pointer(Const(D3D11_DEPTH_STENCIL_VIEW_DESC)), "pDesc"), Out(Pointer(ObjPointer(ID3D11DepthStencilView)), "ppDepthStencilView")]), |
| 1182 | StdMethod(HRESULT, "CreateInputLayout", [(Array(Const(D3D11_INPUT_ELEMENT_DESC), "NumElements"), "pInputElementDescs"), (UINT, "NumElements"), (Blob(Const(Void), "BytecodeLength"), "pShaderBytecodeWithInputSignature"), (SIZE_T, "BytecodeLength"), Out(Pointer(ObjPointer(ID3D11InputLayout)), "ppInputLayout")]), |
| 1183 | StdMethod(HRESULT, "CreateVertexShader", [(Blob(Const(Void), "BytecodeLength"), "pShaderBytecode"), (SIZE_T, "BytecodeLength"), (ObjPointer(ID3D11ClassLinkage), "pClassLinkage"), Out(Pointer(ObjPointer(ID3D11VertexShader)), "ppVertexShader")]), |
| 1184 | StdMethod(HRESULT, "CreateGeometryShader", [(Blob(Const(Void), "BytecodeLength"), "pShaderBytecode"), (SIZE_T, "BytecodeLength"), (ObjPointer(ID3D11ClassLinkage), "pClassLinkage"), Out(Pointer(ObjPointer(ID3D11GeometryShader)), "ppGeometryShader")]), |
| 1185 | StdMethod(HRESULT, "CreateGeometryShaderWithStreamOutput", [(Blob(Const(Void), "BytecodeLength"), "pShaderBytecode"), (SIZE_T, "BytecodeLength"), (Array(Const(D3D11_SO_DECLARATION_ENTRY), "NumEntries"), "pSODeclaration"), (UINT, "NumEntries"), (Array(Const(UINT), "NumStrides"), "pBufferStrides"), (UINT, "NumStrides"), (UINT, "RasterizedStream"), (ObjPointer(ID3D11ClassLinkage), "pClassLinkage"), Out(Pointer(ObjPointer(ID3D11GeometryShader)), "ppGeometryShader")]), |
| 1186 | StdMethod(HRESULT, "CreatePixelShader", [(Blob(Const(Void), "BytecodeLength"), "pShaderBytecode"), (SIZE_T, "BytecodeLength"), (ObjPointer(ID3D11ClassLinkage), "pClassLinkage"), Out(Pointer(ObjPointer(ID3D11PixelShader)), "ppPixelShader")]), |
| 1187 | StdMethod(HRESULT, "CreateHullShader", [(Blob(Const(Void), "BytecodeLength"), "pShaderBytecode"), (SIZE_T, "BytecodeLength"), (ObjPointer(ID3D11ClassLinkage), "pClassLinkage"), Out(Pointer(ObjPointer(ID3D11HullShader)), "ppHullShader")]), |
| 1188 | StdMethod(HRESULT, "CreateDomainShader", [(Blob(Const(Void), "BytecodeLength"), "pShaderBytecode"), (SIZE_T, "BytecodeLength"), (ObjPointer(ID3D11ClassLinkage), "pClassLinkage"), Out(Pointer(ObjPointer(ID3D11DomainShader)), "ppDomainShader")]), |
| 1189 | StdMethod(HRESULT, "CreateComputeShader", [(Blob(Const(Void), "BytecodeLength"), "pShaderBytecode"), (SIZE_T, "BytecodeLength"), (ObjPointer(ID3D11ClassLinkage), "pClassLinkage"), Out(Pointer(ObjPointer(ID3D11ComputeShader)), "ppComputeShader")]), |
| 1190 | StdMethod(HRESULT, "CreateClassLinkage", [Out(Pointer(ObjPointer(ID3D11ClassLinkage)), "ppLinkage")]), |
| 1191 | StdMethod(HRESULT, "CreateBlendState", [(Pointer(Const(D3D11_BLEND_DESC)), "pBlendStateDesc"), Out(Pointer(ObjPointer(ID3D11BlendState)), "ppBlendState")]), |
| 1192 | StdMethod(HRESULT, "CreateDepthStencilState", [(Pointer(Const(D3D11_DEPTH_STENCIL_DESC)), "pDepthStencilDesc"), Out(Pointer(ObjPointer(ID3D11DepthStencilState)), "ppDepthStencilState")]), |
| 1193 | StdMethod(HRESULT, "CreateRasterizerState", [(Pointer(Const(D3D11_RASTERIZER_DESC)), "pRasterizerDesc"), Out(Pointer(ObjPointer(ID3D11RasterizerState)), "ppRasterizerState")]), |
| 1194 | StdMethod(HRESULT, "CreateSamplerState", [(Pointer(Const(D3D11_SAMPLER_DESC)), "pSamplerDesc"), Out(Pointer(ObjPointer(ID3D11SamplerState)), "ppSamplerState")]), |
| 1195 | StdMethod(HRESULT, "CreateQuery", [(Pointer(Const(D3D11_QUERY_DESC)), "pQueryDesc"), Out(Pointer(ObjPointer(ID3D11Query)), "ppQuery")]), |
| 1196 | StdMethod(HRESULT, "CreatePredicate", [(Pointer(Const(D3D11_QUERY_DESC)), "pPredicateDesc"), Out(Pointer(ObjPointer(ID3D11Predicate)), "ppPredicate")]), |
| 1197 | StdMethod(HRESULT, "CreateCounter", [(Pointer(Const(D3D11_COUNTER_DESC)), "pCounterDesc"), Out(Pointer(ObjPointer(ID3D11Counter)), "ppCounter")]), |
| 1198 | StdMethod(HRESULT, "CreateDeferredContext", [(UINT, "ContextFlags"), Out(Pointer(ObjPointer(ID3D11DeviceContext)), "ppDeferredContext")]), |
| 1199 | StdMethod(HRESULT, "OpenSharedResource", [(HANDLE, "hResource"), (REFIID, "ReturnedInterface"), Out(Pointer(ObjPointer(Void)), "ppResource")]), |
José Fonseca | e088e5c | 2012-11-16 20:05:54 +0000 | [diff] [blame] | 1200 | StdMethod(HRESULT, "CheckFormatSupport", [(DXGI_FORMAT, "Format"), Out(Pointer(D3D11_FORMAT_SUPPORT), "pFormatSupport")], sideeffects=False), |
| 1201 | StdMethod(HRESULT, "CheckMultisampleQualityLevels", [(DXGI_FORMAT, "Format"), (UINT, "SampleCount"), Out(Pointer(UINT), "pNumQualityLevels")], sideeffects=False), |
| 1202 | StdMethod(Void, "CheckCounterInfo", [Out(Pointer(D3D11_COUNTER_INFO), "pCounterInfo")], sideeffects=False), |
José Fonseca | bc10e45 | 2012-11-08 10:24:45 +0000 | [diff] [blame] | 1203 | StdMethod(HRESULT, "CheckCounter", [(Pointer(Const(D3D11_COUNTER_DESC)), "pDesc"), Out(Pointer(D3D11_COUNTER_TYPE), "pType"), Out(Pointer(UINT), "pActiveCounters"), Out(LPSTR, "szName"), Out(Pointer(UINT), "pNameLength"), Out(LPSTR, "szUnits"), Out(Pointer(UINT), "pUnitsLength"), Out(LPSTR, "szDescription"), Out(Pointer(UINT), "pDescriptionLength")], sideeffects=False), |
| 1204 | StdMethod(HRESULT, "CheckFeatureSupport", [(D3D11_FEATURE, "Feature"), Out(D3D11_FEATURE_DATA, "pFeatureSupportData"), (UINT, "FeatureSupportDataSize")], sideeffects=False), |
| 1205 | StdMethod(HRESULT, "GetPrivateData", [(REFGUID, "guid"), Out(Pointer(UINT), "pDataSize"), Out(OpaquePointer(Void), "pData")], sideeffects=False), |
| 1206 | StdMethod(HRESULT, "SetPrivateData", [(REFGUID, "guid"), (UINT, "DataSize"), (OpaqueBlob(Const(Void), "DataSize"), "pData")], sideeffects=False), |
| 1207 | StdMethod(HRESULT, "SetPrivateDataInterface", [(REFGUID, "guid"), (OpaquePointer(Const(IUnknown)), "pData")], sideeffects=False), |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 1208 | StdMethod(D3D_FEATURE_LEVEL, "GetFeatureLevel", [], sideeffects=False), |
| 1209 | StdMethod(D3D11_CREATE_DEVICE_FLAG, "GetCreationFlags", [], sideeffects=False), |
| 1210 | StdMethod(HRESULT, "GetDeviceRemovedReason", [], sideeffects=False), |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1211 | StdMethod(Void, "GetImmediateContext", [Out(Pointer(ObjPointer(ID3D11DeviceContext)), "ppImmediateContext")]), |
| 1212 | StdMethod(HRESULT, "SetExceptionMode", [(D3D11_RAISE_FLAG, "RaiseFlags")]), |
José Fonseca | 2b80745 | 2012-11-10 09:50:10 +0000 | [diff] [blame] | 1213 | StdMethod(UINT, "GetExceptionMode", [], sideeffects=False), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1214 | ] |
| 1215 | |
José Fonseca | 8130193 | 2012-11-11 00:10:20 +0000 | [diff] [blame] | 1216 | d3d11 = Module("d3d11") |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1217 | |
| 1218 | d3d11.addFunctions([ |
José Fonseca | ee590be | 2012-04-16 13:25:06 +0100 | [diff] [blame] | 1219 | StdFunction(HRESULT, "D3D11CreateDevice", [(ObjPointer(IDXGIAdapter), "pAdapter"), (D3D_DRIVER_TYPE, "DriverType"), (HMODULE, "Software"), (D3D11_CREATE_DEVICE_FLAG, "Flags"), (Array(Const(D3D_FEATURE_LEVEL), "FeatureLevels"), "pFeatureLevels"), (UINT, "FeatureLevels"), (UINT, "SDKVersion"), Out(Pointer(ObjPointer(ID3D11Device)), "ppDevice"), Out(Pointer(D3D_FEATURE_LEVEL), "pFeatureLevel"), Out(Pointer(ObjPointer(ID3D11DeviceContext)), "ppImmediateContext")]), |
| 1220 | StdFunction(HRESULT, "D3D11CreateDeviceAndSwapChain", [(ObjPointer(IDXGIAdapter), "pAdapter"), (D3D_DRIVER_TYPE, "DriverType"), (HMODULE, "Software"), (D3D11_CREATE_DEVICE_FLAG, "Flags"), (Array(Const(D3D_FEATURE_LEVEL), "FeatureLevels"), "pFeatureLevels"), (UINT, "FeatureLevels"), (UINT, "SDKVersion"), (Pointer(Const(DXGI_SWAP_CHAIN_DESC)), "pSwapChainDesc"), Out(Pointer(ObjPointer(IDXGISwapChain)), "ppSwapChain"), Out(Pointer(ObjPointer(ID3D11Device)), "ppDevice"), Out(Pointer(D3D_FEATURE_LEVEL), "pFeatureLevel"), Out(Pointer(ObjPointer(ID3D11DeviceContext)), "ppImmediateContext")]), |
José Fonseca | 84cea3b | 2012-05-09 21:12:30 +0100 | [diff] [blame] | 1221 | |
| 1222 | # XXX: Undocumented functions, called by d3d11sdklayers.dll when D3D11_CREATE_DEVICE_DEBUG is set |
| 1223 | StdFunction(HRESULT, "D3D11CoreRegisterLayers", [LPCVOID, DWORD], internal=True), |
| 1224 | StdFunction(SIZE_T, "D3D11CoreGetLayeredDeviceSize", [LPCVOID, DWORD], internal=True), |
| 1225 | StdFunction(HRESULT, "D3D11CoreCreateLayeredDevice", [LPCVOID, DWORD, LPCVOID, (REFIID, "riid"), Out(Pointer(ObjPointer(Void)), "ppvObj")], internal=True), |
| 1226 | StdFunction(HRESULT, "D3D11CoreCreateDevice", [DWORD, DWORD, DWORD, DWORD, DWORD, DWORD, DWORD, DWORD, DWORD], internal=True), |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1227 | ]) |
| 1228 | |
| 1229 | d3d11.addInterfaces([ |
José Fonseca | cdefc48 | 2012-11-16 20:06:20 +0000 | [diff] [blame] | 1230 | IDXGIFactory1, |
José Fonseca | 24019a1 | 2012-04-16 21:02:17 +0100 | [diff] [blame] | 1231 | IDXGIAdapter1, |
José Fonseca | ca55d16 | 2012-04-16 13:05:47 +0100 | [diff] [blame] | 1232 | IDXGIDevice1, |
José Fonseca | 24019a1 | 2012-04-16 21:02:17 +0100 | [diff] [blame] | 1233 | IDXGIResource, |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1234 | ID3D11Debug, |
José Fonseca | f17f464 | 2012-04-16 13:06:44 +0100 | [diff] [blame] | 1235 | ID3D11InfoQueue, |
| 1236 | ID3D11SwitchToRef, |
José Fonseca | 5b6fb75 | 2012-04-14 14:56:45 +0100 | [diff] [blame] | 1237 | ]) |