push 07a2b33f792746135ccf34a3b3e1dfb2a3c1e823
[wine/hacks.git] / dlls / d3d10core / device.c
blob567c93af92f6d015c160695d188b65d423eeb7b8
1 /*
2 * Copyright 2008 Henri Verbeet for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
20 #include "config.h"
21 #include "wine/port.h"
23 #include "d3d10core_private.h"
25 WINE_DEFAULT_DEBUG_CHANNEL(d3d10core);
27 /* Inner IUnknown methods */
29 static inline struct d3d10_device *d3d10_device_from_inner_unknown(IUnknown *iface)
31 return (struct d3d10_device *)((char*)iface - FIELD_OFFSET(struct d3d10_device, inner_unknown_vtbl));
34 static HRESULT STDMETHODCALLTYPE d3d10_device_inner_QueryInterface(IUnknown *iface, REFIID riid, void **object)
36 struct d3d10_device *This = d3d10_device_from_inner_unknown(iface);
38 TRACE("iface %p, riid %s, object %p\n", iface, debugstr_guid(riid), object);
40 if (IsEqualGUID(riid, &IID_IUnknown)
41 || IsEqualGUID(riid, &IID_ID3D10Device))
43 IUnknown_AddRef((IUnknown *)This);
44 *object = This;
45 return S_OK;
48 WARN("%s not implemented, returning E_NOINTERFACE\n", debugstr_guid(riid));
50 *object = NULL;
51 return E_NOINTERFACE;
54 static ULONG STDMETHODCALLTYPE d3d10_device_inner_AddRef(IUnknown *iface)
56 struct d3d10_device *This = d3d10_device_from_inner_unknown(iface);
57 ULONG refcount = InterlockedIncrement(&This->refcount);
59 TRACE("%p increasing refcount to %u\n", This, refcount);
61 return refcount;
64 static ULONG STDMETHODCALLTYPE d3d10_device_inner_Release(IUnknown *iface)
66 struct d3d10_device *This = d3d10_device_from_inner_unknown(iface);
67 ULONG refcount = InterlockedDecrement(&This->refcount);
69 TRACE("%p decreasing refcount to %u\n", This, refcount);
71 return refcount;
74 /* IUnknown methods */
76 static HRESULT STDMETHODCALLTYPE d3d10_device_QueryInterface(ID3D10Device *iface, REFIID riid, void **object)
78 struct d3d10_device *This = (struct d3d10_device *)iface;
79 TRACE("Forwarding to outer IUnknown\n");
80 return IUnknown_QueryInterface(This->outer_unknown, riid, object);
83 static ULONG STDMETHODCALLTYPE d3d10_device_AddRef(ID3D10Device *iface)
85 struct d3d10_device *This = (struct d3d10_device *)iface;
86 TRACE("Forwarding to outer IUnknown\n");
87 return IUnknown_AddRef(This->outer_unknown);
90 static ULONG STDMETHODCALLTYPE d3d10_device_Release(ID3D10Device *iface)
92 struct d3d10_device *This = (struct d3d10_device *)iface;
93 TRACE("Forwarding to outer IUnknown\n");
94 return IUnknown_Release(This->outer_unknown);
97 /* ID3D10Device methods */
99 static void STDMETHODCALLTYPE d3d10_device_VSSetConstantBuffers(ID3D10Device *iface,
100 UINT start_slot, UINT buffer_count, ID3D10Buffer *const *buffers)
102 FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p stub!\n",
103 iface, start_slot, buffer_count, buffers);
106 static void STDMETHODCALLTYPE d3d10_device_PSSetShaderResources(ID3D10Device *iface,
107 UINT start_slot, UINT view_count, ID3D10ShaderResourceView *const *views)
109 FIXME("iface %p, start_slot %u, view_count %u, views %p stub!\n",
110 iface, start_slot, view_count, views);
113 static void STDMETHODCALLTYPE d3d10_device_PSSetShader(ID3D10Device *iface, ID3D10PixelShader *shader)
115 FIXME("iface %p, shader %p stub!\n", iface, shader);
118 static void STDMETHODCALLTYPE d3d10_device_PSSetSamplers(ID3D10Device *iface,
119 UINT start_slot, UINT sampler_count, ID3D10SamplerState *const *samplers)
121 FIXME("iface %p, start_slot %u, sampler_count %u, samplers %p stub!\n",
122 iface, start_slot, sampler_count, samplers);
125 static void STDMETHODCALLTYPE d3d10_device_VSSetShader(ID3D10Device *iface, ID3D10VertexShader *shader)
127 FIXME("iface %p, shader %p stub!\n", iface, shader);
130 static void STDMETHODCALLTYPE d3d10_device_DrawIndexed(ID3D10Device *iface,
131 UINT index_count, UINT start_index_location, INT base_vertex_location)
133 FIXME("iface %p, index_count %u, start_index_location %u, base_vertex_location %d stub!\n",
134 iface, index_count, start_index_location, base_vertex_location);
137 static void STDMETHODCALLTYPE d3d10_device_Draw(ID3D10Device *iface,
138 UINT vertex_count, UINT start_vertex_location)
140 FIXME("iface %p, vertex_count %u, start_vertex_location %u stub!\n",
141 iface, vertex_count, start_vertex_location);
144 static void STDMETHODCALLTYPE d3d10_device_PSSetConstantBuffers(ID3D10Device *iface,
145 UINT start_slot, UINT buffer_count, ID3D10Buffer *const *buffers)
147 FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p stub!\n",
148 iface, start_slot, buffer_count, buffers);
151 static void STDMETHODCALLTYPE d3d10_device_IASetInputLayout(ID3D10Device *iface, ID3D10InputLayout *input_layout)
153 FIXME("iface %p, input_layout %p stub!\n", iface, input_layout);
156 static void STDMETHODCALLTYPE d3d10_device_IASetVertexBuffers(ID3D10Device *iface,
157 UINT start_slot, UINT buffer_count, ID3D10Buffer *const *buffers,
158 const UINT *strides, const UINT *offsets)
160 FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p, strides %p, offsets %p stub!\n",
161 iface, start_slot, buffer_count, buffers, strides, offsets);
164 static void STDMETHODCALLTYPE d3d10_device_IASetIndexBuffer(ID3D10Device *iface,
165 ID3D10Buffer *buffer, DXGI_FORMAT format, UINT offset)
167 FIXME("iface %p, buffer %p, format %s, offset %u stub!\n",
168 iface, buffer, debug_dxgi_format(format), offset);
171 static void STDMETHODCALLTYPE d3d10_device_DrawIndexedInstanced(ID3D10Device *iface,
172 UINT instance_index_count, UINT instance_count, UINT start_index_location,
173 INT base_vertex_location, UINT start_instance_location)
175 FIXME("iface %p, instance_index_count %u, instance_count %u, start_index_location %u,\n"
176 "\tbase_vertex_location %d, start_instance_location %u stub!\n",
177 iface, instance_index_count, instance_count, start_index_location,
178 base_vertex_location, start_instance_location);
181 static void STDMETHODCALLTYPE d3d10_device_DrawInstanced(ID3D10Device *iface,
182 UINT instance_vertex_count, UINT instance_count,
183 UINT start_vertex_location, UINT start_instance_location)
185 FIXME("iface %p, instance_vertex_count %u, instance_count %u, start_vertex_location %u,\n"
186 "\tstart_instance_location %u stub!\n", iface, instance_vertex_count, instance_count,
187 start_vertex_location, start_instance_location);
190 static void STDMETHODCALLTYPE d3d10_device_GSSetConstantBuffers(ID3D10Device *iface,
191 UINT start_slot, UINT buffer_count, ID3D10Buffer *const *buffers)
193 FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p stub!\n",
194 iface, start_slot, buffer_count, buffers);
197 static void STDMETHODCALLTYPE d3d10_device_GSSetShader(ID3D10Device *iface, ID3D10GeometryShader *shader)
199 FIXME("iface %p, shader %p stub!\n", iface, shader);
202 static void STDMETHODCALLTYPE d3d10_device_IASetPrimitiveTopology(ID3D10Device *iface, D3D10_PRIMITIVE_TOPOLOGY topology)
204 FIXME("iface %p, topology %s stub!\n", iface, debug_d3d10_primitive_topology(topology));
207 static void STDMETHODCALLTYPE d3d10_device_VSSetShaderResources(ID3D10Device *iface,
208 UINT start_slot, UINT view_count, ID3D10ShaderResourceView *const *views)
210 FIXME("iface %p, start_slot %u, view_count %u, views %p stub!\n",
211 iface, start_slot, view_count, views);
214 static void STDMETHODCALLTYPE d3d10_device_VSSetSamplers(ID3D10Device *iface,
215 UINT start_slot, UINT sampler_count, ID3D10SamplerState *const *samplers)
217 FIXME("iface %p, start_slot %u, sampler_count %u, samplers %p stub!\n",
218 iface, start_slot, sampler_count, samplers);
221 static void STDMETHODCALLTYPE d3d10_device_SetPredication(ID3D10Device *iface, ID3D10Predicate *predicate, BOOL value)
223 FIXME("iface %p, predicate %p, value %d stub!\n", iface, predicate, value);
226 static void STDMETHODCALLTYPE d3d10_device_GSSetShaderResources(ID3D10Device *iface,
227 UINT start_slot, UINT view_count, ID3D10ShaderResourceView *const *views)
229 FIXME("iface %p, start_slot %u, view_count %u, views %p stub!\n",
230 iface, start_slot, view_count, views);
233 static void STDMETHODCALLTYPE d3d10_device_GSSetSamplers(ID3D10Device *iface,
234 UINT start_slot, UINT sampler_count, ID3D10SamplerState *const *samplers)
236 FIXME("iface %p, start_slot %u, sampler_count %u, samplers %p stub!\n",
237 iface, start_slot, sampler_count, samplers);
240 static void STDMETHODCALLTYPE d3d10_device_OMSetRenderTargets(ID3D10Device *iface,
241 UINT render_target_view_count, ID3D10RenderTargetView *const *render_target_views,
242 ID3D10DepthStencilView *depth_stencil_view)
244 FIXME("iface %p, render_target_view_count %u, render_target_views %p, depth_stencil_view %p\n",
245 iface, render_target_view_count, render_target_views, depth_stencil_view);
248 static void STDMETHODCALLTYPE d3d10_device_OMSetBlendState(ID3D10Device *iface,
249 ID3D10BlendState *blend_state, const FLOAT blend_factor[4], UINT sample_mask)
251 FIXME("iface %p, blend_state %p, blend_factor [%f %f %f %f], sample_mask 0x%08x stub!\n",
252 iface, blend_state, blend_factor[0], blend_factor[1], blend_factor[2], blend_factor[3], sample_mask);
255 static void STDMETHODCALLTYPE d3d10_device_OMSetDepthStencilState(ID3D10Device *iface,
256 ID3D10DepthStencilState *depth_stencil_state, UINT stencil_ref)
258 FIXME("iface %p, depth_stencil_state %p, stencil_ref %u stub!\n",
259 iface, depth_stencil_state, stencil_ref);
262 static void STDMETHODCALLTYPE d3d10_device_SOSetTargets(ID3D10Device *iface,
263 UINT target_count, ID3D10Buffer *const *targets, const UINT *offsets)
265 FIXME("iface %p, target_count %u, targets %p, offsets %p stub!\n", iface, target_count, targets, offsets);
268 static void STDMETHODCALLTYPE d3d10_device_DrawAuto(ID3D10Device *iface)
270 FIXME("iface %p stub!\n", iface);
273 static void STDMETHODCALLTYPE d3d10_device_RSSetState(ID3D10Device *iface, ID3D10RasterizerState *rasterizer_state)
275 FIXME("iface %p, rasterizer_state %p stub!\n", iface, rasterizer_state);
278 static void STDMETHODCALLTYPE d3d10_device_RSSetViewports(ID3D10Device *iface,
279 UINT viewport_count, const D3D10_VIEWPORT *viewports)
281 FIXME("iface %p, viewport_count %u, viewports %p stub!\n", iface, viewport_count, viewports);
284 static void STDMETHODCALLTYPE d3d10_device_RSSetScissorRects(ID3D10Device *iface,
285 UINT rect_count, const D3D10_RECT *rects)
287 FIXME("iface %p, rect_count %u, rects %p\n", iface, rect_count, rects);
290 static void STDMETHODCALLTYPE d3d10_device_CopySubresourceRegion(ID3D10Device *iface,
291 ID3D10Resource *dst_resource, UINT dst_subresource_idx, UINT dst_x, UINT dst_y, UINT dst_z,
292 ID3D10Resource *src_resource, UINT src_subresource_idx, const D3D10_BOX *src_box)
294 FIXME("iface %p, dst_resource %p, dst_subresource_idx %u, dst_x %u, dst_y %u, dst_z %u,\n"
295 "\tsrc_resource %p, src_subresource_idx %u, src_box %p stub!\n",
296 iface, dst_resource, dst_subresource_idx, dst_x, dst_y, dst_z,
297 src_resource, src_subresource_idx, src_box);
300 static void STDMETHODCALLTYPE d3d10_device_CopyResource(ID3D10Device *iface,
301 ID3D10Resource *dst_resource, ID3D10Resource *src_resource)
303 FIXME("iface %p, dst_resource %p, src_resource %p stub!\n", iface, dst_resource, src_resource);
306 static void STDMETHODCALLTYPE d3d10_device_UpdateSubresource(ID3D10Device *iface,
307 ID3D10Resource *resource, UINT subresource_idx, const D3D10_BOX *box,
308 const void *data, UINT row_pitch, UINT depth_pitch)
310 FIXME("iface %p, resource %p, subresource_idx %u, box %p, data %p, row_pitch %u, depth_pitch %u stub!\n",
311 iface, resource, subresource_idx, box, data, row_pitch, depth_pitch);
314 static void STDMETHODCALLTYPE d3d10_device_ClearRenderTargetView(ID3D10Device *iface,
315 ID3D10RenderTargetView *render_target_view, const FLOAT color_rgba[4])
317 FIXME("iface %p, render_target_view %p, color_rgba [%f %f %f %f] stub!\n",
318 iface, render_target_view, color_rgba[0], color_rgba[1], color_rgba[2], color_rgba[3]);
321 static void STDMETHODCALLTYPE d3d10_device_ClearDepthStencilView(ID3D10Device *iface,
322 ID3D10DepthStencilView *depth_stencil_view, UINT flags, FLOAT depth, UINT8 stencil)
324 FIXME("iface %p, depth_stencil_view %p, flags %#x, depth %f, stencil %u stub!\n",
325 iface, depth_stencil_view, flags, depth, stencil);
328 static void STDMETHODCALLTYPE d3d10_device_GenerateMips(ID3D10Device *iface, ID3D10ShaderResourceView *shader_resource_view)
330 FIXME("iface %p, shader_resource_view %p stub!\n", iface, shader_resource_view);
333 static void STDMETHODCALLTYPE d3d10_device_ResolveSubresource(ID3D10Device *iface,
334 ID3D10Resource *dst_resource, UINT dst_subresource_idx,
335 ID3D10Resource *src_resource, UINT src_subresource_idx, DXGI_FORMAT format)
337 FIXME("iface %p, dst_resource %p, dst_subresource_idx %u,\n"
338 "\tsrc_resource %p, src_subresource_idx %u, format %s stub!\n",
339 iface, dst_resource, dst_subresource_idx,
340 src_resource, src_subresource_idx, debug_dxgi_format(format));
343 static void STDMETHODCALLTYPE d3d10_device_VSGetConstantBuffers(ID3D10Device *iface,
344 UINT start_slot, UINT buffer_count, ID3D10Buffer **buffers)
346 FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p stub!\n",
347 iface, start_slot, buffer_count, buffers);
350 static void STDMETHODCALLTYPE d3d10_device_PSGetShaderResources(ID3D10Device *iface,
351 UINT start_slot, UINT view_count, ID3D10ShaderResourceView **views)
353 FIXME("iface %p, start_slot %u, view_count %u, views %p stub!\n",
354 iface, start_slot, view_count, views);
357 static void STDMETHODCALLTYPE d3d10_device_PSGetShader(ID3D10Device *iface, ID3D10PixelShader **shader)
359 FIXME("iface %p, shader %p stub!\n", iface, shader);
362 static void STDMETHODCALLTYPE d3d10_device_PSGetSamplers(ID3D10Device *iface,
363 UINT start_slot, UINT sampler_count, ID3D10SamplerState **samplers)
365 FIXME("iface %p, start_slot %u, sampler_count %u, samplers %p stub!\n",
366 iface, start_slot, sampler_count, samplers);
369 static void STDMETHODCALLTYPE d3d10_device_VSGetShader(ID3D10Device *iface, ID3D10VertexShader **shader)
371 FIXME("iface %p, shader %p stub!\n", iface, shader);
374 static void STDMETHODCALLTYPE d3d10_device_PSGetConstantBuffers(ID3D10Device *iface,
375 UINT start_slot, UINT buffer_count, ID3D10Buffer **buffers)
377 FIXME("iface %p, start_slot %u, buffer_count %u, buffer %p stub!\n",
378 iface, start_slot, buffer_count, buffers);
381 static void STDMETHODCALLTYPE d3d10_device_IAGetInputLayout(ID3D10Device *iface, ID3D10InputLayout **input_layout)
383 FIXME("iface %p, input_layout %p stub!\n", iface, input_layout);
386 static void STDMETHODCALLTYPE d3d10_device_IAGetVertexBuffers(ID3D10Device *iface,
387 UINT start_slot, UINT buffer_count, ID3D10Buffer **buffers, UINT *strides, UINT *offsets)
389 FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p, strides %p, offsets %p stub!\n",
390 iface, start_slot, buffer_count, buffers, strides, offsets);
393 static void STDMETHODCALLTYPE d3d10_device_IAGetIndexBuffer(ID3D10Device *iface,
394 ID3D10Buffer **buffer, DXGI_FORMAT *format, UINT *offset)
396 FIXME("iface %p, buffer %p, format %p, offset %p stub!\n", iface, buffer, format, offset);
399 static void STDMETHODCALLTYPE d3d10_device_GSGetConstantBuffers(ID3D10Device *iface,
400 UINT start_slot, UINT buffer_count, ID3D10Buffer **buffers)
402 FIXME("iface %p, start_slot %u, buffer_count %u, buffers %p stub!\n",
403 iface, start_slot, buffer_count, buffers);
406 static void STDMETHODCALLTYPE d3d10_device_GSGetShader(ID3D10Device *iface, ID3D10GeometryShader **shader)
408 FIXME("iface %p, shader %p stub!\n", iface, shader);
411 static void STDMETHODCALLTYPE d3d10_device_IAGetPrimitiveTopology(ID3D10Device *iface, D3D10_PRIMITIVE_TOPOLOGY *topology)
413 FIXME("iface %p, topology %p stub!\n", iface, topology);
416 static void STDMETHODCALLTYPE d3d10_device_VSGetShaderResources(ID3D10Device *iface,
417 UINT start_slot, UINT view_count, ID3D10ShaderResourceView **views)
419 FIXME("iface %p, start_slot %u, view_count %u, views %p stub!\n",
420 iface, start_slot, view_count, views);
423 static void STDMETHODCALLTYPE d3d10_device_VSGetSamplers(ID3D10Device *iface,
424 UINT start_slot, UINT sampler_count, ID3D10SamplerState **samplers)
426 FIXME("iface %p, start_slot %u, sampler_count %u, samplers %p stub!\n",
427 iface, start_slot, sampler_count, samplers);
430 static void STDMETHODCALLTYPE d3d10_device_GetPredication(ID3D10Device *iface,
431 ID3D10Predicate **predicate, BOOL *value)
433 FIXME("iface %p, predicate %p, value %p stub!\n", iface, predicate, value);
436 static void STDMETHODCALLTYPE d3d10_device_GSGetShaderResources(ID3D10Device *iface,
437 UINT start_slot, UINT view_count, ID3D10ShaderResourceView **views)
439 FIXME("iface %p, start_slot %u, view_count %u, views %p stub!\n",
440 iface, start_slot, view_count, views);
443 static void STDMETHODCALLTYPE d3d10_device_GSGetSamplers(ID3D10Device *iface,
444 UINT start_slot, UINT sampler_count, ID3D10SamplerState **samplers)
446 FIXME("iface %p, start_slot %u, sampler_count %u, samplers %p stub!\n",
447 iface, start_slot, sampler_count, samplers);
450 static void STDMETHODCALLTYPE d3d10_device_OMGetRenderTargets(ID3D10Device *iface,
451 UINT view_count, ID3D10RenderTargetView **render_target_views, ID3D10DepthStencilView **depth_stencil_view)
453 FIXME("iface %p, view_count %u, render_target_views %p, depth_stencil_view %p stub!\n",
454 iface, view_count, render_target_views, depth_stencil_view);
457 static void STDMETHODCALLTYPE d3d10_device_OMGetBlendState(ID3D10Device *iface,
458 ID3D10BlendState **blend_state, FLOAT blend_factor[4], UINT *sample_mask)
460 FIXME("iface %p, blend_state %p, blend_factor %p, sample_mask %p stub!\n",
461 iface, blend_state, blend_factor, sample_mask);
464 static void STDMETHODCALLTYPE d3d10_device_OMGetDepthStencilState(ID3D10Device *iface,
465 ID3D10DepthStencilState **depth_stencil_state, UINT *stencil_ref)
467 FIXME("iface %p, depth_stencil_state %p, stencil_ref %p stub!\n",
468 iface, depth_stencil_state, stencil_ref);
471 static void STDMETHODCALLTYPE d3d10_device_SOGetTargets(ID3D10Device *iface,
472 UINT buffer_count, ID3D10Buffer **buffers, UINT *offsets)
474 FIXME("iface %p, buffer_count %u, buffers %p, offsets %p stub!\n",
475 iface, buffer_count, buffers, offsets);
478 static void STDMETHODCALLTYPE d3d10_device_RSGetState(ID3D10Device *iface, ID3D10RasterizerState **rasterizer_state)
480 FIXME("iface %p, rasterizer_state %p stub!\n", iface, rasterizer_state);
483 static void STDMETHODCALLTYPE d3d10_device_RSGetViewports(ID3D10Device *iface,
484 UINT *viewport_count, D3D10_VIEWPORT *viewports)
486 FIXME("iface %p, viewport_count %p, viewports %p stub!\n", iface, viewport_count, viewports);
489 static void STDMETHODCALLTYPE d3d10_device_RSGetScissorRects(ID3D10Device *iface, UINT *rect_count, D3D10_RECT *rects)
491 FIXME("iface %p, rect_count %p, rects %p stub!\n", iface, rect_count, rects);
494 static HRESULT STDMETHODCALLTYPE d3d10_device_GetDeviceRemovedReason(ID3D10Device *iface)
496 FIXME("iface %p stub!\n", iface);
498 return E_NOTIMPL;
501 static HRESULT STDMETHODCALLTYPE d3d10_device_SetExceptionMode(ID3D10Device *iface, UINT flags)
503 FIXME("iface %p, flags %#x stub!\n", iface, flags);
505 return E_NOTIMPL;
508 static UINT STDMETHODCALLTYPE d3d10_device_GetExceptionMode(ID3D10Device *iface)
510 FIXME("iface %p stub!\n", iface);
512 return 0;
515 static HRESULT STDMETHODCALLTYPE d3d10_device_GetPrivateData(ID3D10Device *iface,
516 REFGUID guid, UINT *data_size, void *data)
518 FIXME("iface %p, guid %s, data_size %p, data %p stub!\n",
519 iface, debugstr_guid(guid), data_size, data);
521 return E_NOTIMPL;
524 static HRESULT STDMETHODCALLTYPE d3d10_device_SetPrivateData(ID3D10Device *iface,
525 REFGUID guid, UINT data_size, const void *data)
527 FIXME("iface %p, guid %s, data_size %u, data %p stub!\n",
528 iface, debugstr_guid(guid), data_size, data);
530 return E_NOTIMPL;
533 static HRESULT STDMETHODCALLTYPE d3d10_device_SetPrivateDataInterface(ID3D10Device *iface,
534 REFGUID guid, const IUnknown *data)
536 FIXME("iface %p, guid %s, data %p stub!\n", iface, debugstr_guid(guid), data);
538 return E_NOTIMPL;
541 static void STDMETHODCALLTYPE d3d10_device_ClearState(ID3D10Device *iface)
543 FIXME("iface %p stub!\n", iface);
546 static void STDMETHODCALLTYPE d3d10_device_Flush(ID3D10Device *iface)
548 FIXME("iface %p stub!\n", iface);
551 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateBuffer(ID3D10Device *iface,
552 const D3D10_BUFFER_DESC *desc, const D3D10_SUBRESOURCE_DATA *data, ID3D10Buffer **buffer)
554 FIXME("iface %p, desc %p, data %p, buffer %p stub!\n", iface, desc, data, buffer);
556 return E_NOTIMPL;
559 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateTexture1D(ID3D10Device *iface,
560 const D3D10_TEXTURE1D_DESC *desc, const D3D10_SUBRESOURCE_DATA *data, ID3D10Texture1D **texture)
562 FIXME("iface %p, desc %p, data %p, texture %p stub!\n", iface, desc, data, texture);
564 return E_NOTIMPL;
567 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateTexture2D(ID3D10Device *iface,
568 const D3D10_TEXTURE2D_DESC *desc, const D3D10_SUBRESOURCE_DATA *data, ID3D10Texture2D **texture)
570 FIXME("iface %p, desc %p, data %p, texture %p stub!\n", iface, desc, data, texture);
572 return E_NOTIMPL;
575 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateTexture3D(ID3D10Device *iface,
576 const D3D10_TEXTURE3D_DESC *desc, const D3D10_SUBRESOURCE_DATA *data, ID3D10Texture3D **texture)
578 FIXME("iface %p, desc %p, data %p, texture %p stub!\n", iface, desc, data, texture);
580 return E_NOTIMPL;
583 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateShaderResourceView(ID3D10Device *iface,
584 ID3D10Resource *resource, const D3D10_SHADER_RESOURCE_VIEW_DESC *desc, ID3D10ShaderResourceView **view)
586 FIXME("iface %p, resource %p, desc %p, view %p stub!\n", iface, resource, desc, view);
588 return E_NOTIMPL;
591 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateRenderTargetView(ID3D10Device *iface,
592 ID3D10Resource *resource, const D3D10_RENDER_TARGET_VIEW_DESC *desc, ID3D10RenderTargetView **view)
594 FIXME("iface %p, resource %p, desc %p, view %p stub!\n", iface, resource, desc, view);
596 return E_NOTIMPL;
599 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateDepthStencilView(ID3D10Device *iface,
600 ID3D10Resource *resource, const D3D10_DEPTH_STENCIL_VIEW_DESC *desc, ID3D10DepthStencilView **view)
602 FIXME("iface %p, resource %p, desc %p, view %p stub!\n", iface, resource, desc, view);
604 return E_NOTIMPL;
607 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateInputLayout(ID3D10Device *iface,
608 const D3D10_INPUT_ELEMENT_DESC *element_descs, UINT element_count, const void *shader_byte_code,
609 SIZE_T shader_byte_code_length, ID3D10InputLayout **input_layout)
611 FIXME("iface %p, element_descs %p, element_count %u, shader_byte_code %p,"
612 "\tshader_byte_code_length %lu, input_layout %p stub!\n",
613 iface, element_descs, element_count, shader_byte_code,
614 shader_byte_code_length, input_layout);
616 return E_NOTIMPL;
619 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateVertexShader(ID3D10Device *iface,
620 const void *byte_code, SIZE_T byte_code_length, ID3D10VertexShader **shader)
622 FIXME("iface %p, byte_code %p, byte_code_length %lu, shader %p stub!\n",
623 iface, byte_code, byte_code_length, shader);
625 return E_NOTIMPL;
628 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateGeometryShader(ID3D10Device *iface,
629 const void *byte_code, SIZE_T byte_code_length, ID3D10GeometryShader **shader)
631 FIXME("iface %p, byte_code %p, byte_code_length %lu, shader %p stub!\n",
632 iface, byte_code, byte_code_length, shader);
634 return E_NOTIMPL;
637 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateGeometryShaderWithStreamOutput(ID3D10Device *iface,
638 const void *byte_code, SIZE_T byte_code_length, const D3D10_SO_DECLARATION_ENTRY *output_stream_decls,
639 UINT output_stream_decl_count, UINT output_stream_stride, ID3D10GeometryShader **shader)
641 FIXME("iface %p, byte_code %p, byte_code_length %lu, output_stream_decls %p,\n"
642 "\toutput_stream_decl_count %u, output_stream_stride %u, shader %p stub!\n",
643 iface, byte_code, byte_code_length, output_stream_decls,
644 output_stream_decl_count, output_stream_stride, shader);
646 return E_NOTIMPL;
649 static HRESULT STDMETHODCALLTYPE d3d10_device_CreatePixelShader(ID3D10Device *iface,
650 const void *byte_code, SIZE_T byte_code_length, ID3D10PixelShader **shader)
652 FIXME("iface %p, byte_code %p, byte_code_length %lu, shader %p stub!\n",
653 iface, byte_code, byte_code_length, shader);
655 return E_NOTIMPL;
658 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateBlendState(ID3D10Device *iface,
659 const D3D10_BLEND_DESC *desc, ID3D10BlendState **blend_state)
661 FIXME("iface %p, desc %p, blend_state %p stub!\n", iface, desc, blend_state);
663 return E_NOTIMPL;
666 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateDepthStencilState(ID3D10Device *iface,
667 const D3D10_DEPTH_STENCIL_DESC *desc, ID3D10DepthStencilState **depth_stencil_state)
669 FIXME("iface %p, desc %p, depth_stencil_state %p stub!\n", iface, desc, depth_stencil_state);
671 return E_NOTIMPL;
674 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateRasterizerState(ID3D10Device *iface,
675 const D3D10_RASTERIZER_DESC *desc, ID3D10RasterizerState **rasterizer_state)
677 FIXME("iface %p, desc %p, rasterizer_state %p stub!\n", iface, desc, rasterizer_state);
679 return E_NOTIMPL;
682 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateSamplerState(ID3D10Device *iface,
683 const D3D10_SAMPLER_DESC *desc, ID3D10SamplerState **sampler_state)
685 FIXME("iface %p, desc %p, sampler_state %p stub!\n", iface, desc, sampler_state);
687 return E_NOTIMPL;
690 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateQuery(ID3D10Device *iface,
691 const D3D10_QUERY_DESC *desc, ID3D10Query **query)
693 FIXME("iface %p, desc %p, query %p stub!\n", iface, desc, query);
695 return E_NOTIMPL;
698 static HRESULT STDMETHODCALLTYPE d3d10_device_CreatePredicate(ID3D10Device *iface,
699 const D3D10_QUERY_DESC *desc, ID3D10Predicate **predicate)
701 FIXME("iface %p, desc %p, predicate %p stub!\n", iface, desc, predicate);
703 return E_NOTIMPL;
706 static HRESULT STDMETHODCALLTYPE d3d10_device_CreateCounter(ID3D10Device *iface,
707 const D3D10_COUNTER_DESC *desc, ID3D10Counter **counter)
709 FIXME("iface %p, desc %p, counter %p stub!\n", iface, desc, counter);
711 return E_NOTIMPL;
714 static HRESULT STDMETHODCALLTYPE d3d10_device_CheckFormatSupport(ID3D10Device *iface,
715 DXGI_FORMAT format, UINT *format_support)
717 FIXME("iface %p, format %s, format_support %p stub!\n",
718 iface, debug_dxgi_format(format), format_support);
720 return E_NOTIMPL;
723 static HRESULT STDMETHODCALLTYPE d3d10_device_CheckMultisampleQualityLevels(ID3D10Device *iface,
724 DXGI_FORMAT format, UINT sample_count, UINT *quality_level_count)
726 FIXME("iface %p, format %s, sample_count %u, quality_level_count %p stub!\n",
727 iface, debug_dxgi_format(format), sample_count, quality_level_count);
729 return E_NOTIMPL;
732 static void STDMETHODCALLTYPE d3d10_device_CheckCounterInfo(ID3D10Device *iface, D3D10_COUNTER_INFO *counter_info)
734 FIXME("iface %p, counter_info %p stub!\n", iface, counter_info);
737 static HRESULT STDMETHODCALLTYPE d3d10_device_CheckCounter(ID3D10Device *iface,
738 const D3D10_COUNTER_DESC *desc, D3D10_COUNTER_TYPE *type, UINT *active_counters, LPSTR name,
739 UINT *name_length, LPSTR units, UINT *units_length, LPSTR description, UINT *description_length)
741 FIXME("iface %p, desc %p, type %p, active_counters %p, name %p, name_length %p,\n"
742 "\tunits %p, units_length %p, description %p, description_length %p stub!\n",
743 iface, desc, type, active_counters, name, name_length,
744 units, units_length, description, description_length);
746 return E_NOTIMPL;
749 static UINT STDMETHODCALLTYPE d3d10_device_GetCreationFlags(ID3D10Device *iface)
751 FIXME("iface %p stub!\n", iface);
753 return 0;
756 static HRESULT STDMETHODCALLTYPE d3d10_device_OpenSharedResource(ID3D10Device *iface,
757 HANDLE resource_handle, REFIID guid, void **resource)
759 FIXME("iface %p, resource_handle %p, guid %s, resource %p stub!\n",
760 iface, resource_handle, debugstr_guid(guid), resource);
762 return E_NOTIMPL;
765 static void STDMETHODCALLTYPE d3d10_device_SetTextFilterSize(ID3D10Device *iface, UINT width, UINT height)
767 FIXME("iface %p, width %u, height %u stub!\n", iface, width, height);
770 static void STDMETHODCALLTYPE d3d10_device_GetTextFilterSize(ID3D10Device *iface, UINT *width, UINT *height)
772 FIXME("iface %p, width %p, height %p stub!\n", iface, width, height);
775 const struct ID3D10DeviceVtbl d3d10_device_vtbl =
777 /* IUnknown methods */
778 d3d10_device_QueryInterface,
779 d3d10_device_AddRef,
780 d3d10_device_Release,
781 /* ID3D10Device methods */
782 d3d10_device_VSSetConstantBuffers,
783 d3d10_device_PSSetShaderResources,
784 d3d10_device_PSSetShader,
785 d3d10_device_PSSetSamplers,
786 d3d10_device_VSSetShader,
787 d3d10_device_DrawIndexed,
788 d3d10_device_Draw,
789 d3d10_device_PSSetConstantBuffers,
790 d3d10_device_IASetInputLayout,
791 d3d10_device_IASetVertexBuffers,
792 d3d10_device_IASetIndexBuffer,
793 d3d10_device_DrawIndexedInstanced,
794 d3d10_device_DrawInstanced,
795 d3d10_device_GSSetConstantBuffers,
796 d3d10_device_GSSetShader,
797 d3d10_device_IASetPrimitiveTopology,
798 d3d10_device_VSSetShaderResources,
799 d3d10_device_VSSetSamplers,
800 d3d10_device_SetPredication,
801 d3d10_device_GSSetShaderResources,
802 d3d10_device_GSSetSamplers,
803 d3d10_device_OMSetRenderTargets,
804 d3d10_device_OMSetBlendState,
805 d3d10_device_OMSetDepthStencilState,
806 d3d10_device_SOSetTargets,
807 d3d10_device_DrawAuto,
808 d3d10_device_RSSetState,
809 d3d10_device_RSSetViewports,
810 d3d10_device_RSSetScissorRects,
811 d3d10_device_CopySubresourceRegion,
812 d3d10_device_CopyResource,
813 d3d10_device_UpdateSubresource,
814 d3d10_device_ClearRenderTargetView,
815 d3d10_device_ClearDepthStencilView,
816 d3d10_device_GenerateMips,
817 d3d10_device_ResolveSubresource,
818 d3d10_device_VSGetConstantBuffers,
819 d3d10_device_PSGetShaderResources,
820 d3d10_device_PSGetShader,
821 d3d10_device_PSGetSamplers,
822 d3d10_device_VSGetShader,
823 d3d10_device_PSGetConstantBuffers,
824 d3d10_device_IAGetInputLayout,
825 d3d10_device_IAGetVertexBuffers,
826 d3d10_device_IAGetIndexBuffer,
827 d3d10_device_GSGetConstantBuffers,
828 d3d10_device_GSGetShader,
829 d3d10_device_IAGetPrimitiveTopology,
830 d3d10_device_VSGetShaderResources,
831 d3d10_device_VSGetSamplers,
832 d3d10_device_GetPredication,
833 d3d10_device_GSGetShaderResources,
834 d3d10_device_GSGetSamplers,
835 d3d10_device_OMGetRenderTargets,
836 d3d10_device_OMGetBlendState,
837 d3d10_device_OMGetDepthStencilState,
838 d3d10_device_SOGetTargets,
839 d3d10_device_RSGetState,
840 d3d10_device_RSGetViewports,
841 d3d10_device_RSGetScissorRects,
842 d3d10_device_GetDeviceRemovedReason,
843 d3d10_device_SetExceptionMode,
844 d3d10_device_GetExceptionMode,
845 d3d10_device_GetPrivateData,
846 d3d10_device_SetPrivateData,
847 d3d10_device_SetPrivateDataInterface,
848 d3d10_device_ClearState,
849 d3d10_device_Flush,
850 d3d10_device_CreateBuffer,
851 d3d10_device_CreateTexture1D,
852 d3d10_device_CreateTexture2D,
853 d3d10_device_CreateTexture3D,
854 d3d10_device_CreateShaderResourceView,
855 d3d10_device_CreateRenderTargetView,
856 d3d10_device_CreateDepthStencilView,
857 d3d10_device_CreateInputLayout,
858 d3d10_device_CreateVertexShader,
859 d3d10_device_CreateGeometryShader,
860 d3d10_device_CreateGeometryShaderWithStreamOutput,
861 d3d10_device_CreatePixelShader,
862 d3d10_device_CreateBlendState,
863 d3d10_device_CreateDepthStencilState,
864 d3d10_device_CreateRasterizerState,
865 d3d10_device_CreateSamplerState,
866 d3d10_device_CreateQuery,
867 d3d10_device_CreatePredicate,
868 d3d10_device_CreateCounter,
869 d3d10_device_CheckFormatSupport,
870 d3d10_device_CheckMultisampleQualityLevels,
871 d3d10_device_CheckCounterInfo,
872 d3d10_device_CheckCounter,
873 d3d10_device_GetCreationFlags,
874 d3d10_device_OpenSharedResource,
875 d3d10_device_SetTextFilterSize,
876 d3d10_device_GetTextFilterSize,
879 const struct IUnknownVtbl d3d10_device_inner_unknown_vtbl =
881 /* IUnknown methods */
882 d3d10_device_inner_QueryInterface,
883 d3d10_device_inner_AddRef,
884 d3d10_device_inner_Release,