Commit 39cd9f74 authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

d3d10: Add an initial implementation of D3D10CreateDevice().

parent b2d20154
@ stub D3D10CompileEffectFromMemory
@ stub D3D10CompileShader
@ stub D3D10CreateBlob
@ stub D3D10CreateDevice
@ stdcall D3D10CreateDevice(ptr long ptr long long ptr)
@ stub D3D10CreateDeviceAndSwapChain
@ stub D3D10CreateEffectFromMemory
@ stub D3D10CreateEffectPoolFromMemory
......
......@@ -40,3 +40,27 @@ BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpv)
}
return TRUE;
}
HRESULT WINAPI D3D10CreateDevice(IDXGIAdapter *adapter, D3D10_DRIVER_TYPE driver_type,
HMODULE swrast, UINT flags, UINT sdk_version, ID3D10Device **device)
{
struct d3d10_device *object;
FIXME("adapter %p, driver_type %s, swrast %p, flags %#x, sdk_version %d, device %p partial stub!\n",
adapter, debug_d3d10_driver_type(driver_type), swrast, flags, sdk_version, device);
object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*object));
if (!object)
{
ERR("Failed to allocate D3D device object memory\n");
return E_OUTOFMEMORY;
}
object->vtbl = &d3d10_device_vtbl;
object->refcount = 1;
*device = (ID3D10Device *)object;
TRACE("Created ID3D10Device %p\n", object);
return S_OK;
}
......@@ -32,6 +32,9 @@ typedef enum D3D10_DRIVER_TYPE {
D3D10_DRIVER_TYPE_SOFTWARE = 3,
} D3D10_DRIVER_TYPE;
HRESULT WINAPI D3D10CreateDevice(IDXGIAdapter *adapter, D3D10_DRIVER_TYPE driver_type,
HMODULE swrast, UINT flags, UINT sdk_version, ID3D10Device **device);
#ifdef __cplusplus
}
#endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment