mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-04-13 05:43:18 -07:00
libs/vkd3d: Move D3D12CreateDevice() to libvkd3d-utils.
This commit is contained in:
@@ -51,23 +51,6 @@ HRESULT WINAPI vkd3d_create_device(const struct vkd3d_device_create_info *create
|
||||
riid, device);
|
||||
}
|
||||
|
||||
HRESULT WINAPI D3D12CreateDevice(IUnknown *adapter, D3D_FEATURE_LEVEL minimum_feature_level,
|
||||
REFIID riid, void **device)
|
||||
{
|
||||
struct vkd3d_device_create_info create_info;
|
||||
|
||||
TRACE("adapter %p, minimum_feature_level %#x, riid %s, device %p.\n",
|
||||
adapter, minimum_feature_level, debugstr_guid(riid), device);
|
||||
|
||||
if (adapter)
|
||||
FIXME("Ignoring adapter %p.\n", adapter);
|
||||
|
||||
create_info.minimum_feature_level = minimum_feature_level;
|
||||
create_info.signal_event_pfn = VKD3DSignalEvent;
|
||||
|
||||
return vkd3d_create_device(&create_info, riid, device);
|
||||
}
|
||||
|
||||
/* Events */
|
||||
HANDLE WINAPI VKD3DCreateEvent(void)
|
||||
{
|
||||
|
@@ -26,8 +26,7 @@
|
||||
#define COBJMACROS
|
||||
#define NONAMELESSUNION
|
||||
#include "vkd3d.h"
|
||||
#include "vkd3d_common.h"
|
||||
#include "vkd3d_debug.h"
|
||||
#include "vkd3d_memory.h"
|
||||
#include "vkd3d_vulkan.h"
|
||||
|
||||
#include <assert.h>
|
||||
@@ -275,34 +274,6 @@ VkFormat vk_format_from_dxgi_format(DXGI_FORMAT format) DECLSPEC_HIDDEN;
|
||||
bool vkd3d_array_reserve(void **elements, size_t *capacity,
|
||||
size_t element_count, size_t element_size) DECLSPEC_HIDDEN;
|
||||
|
||||
static inline void *vkd3d_malloc(size_t size)
|
||||
{
|
||||
void *ptr;
|
||||
if (!(ptr = malloc(size)))
|
||||
ERR("Out of memory.\n");
|
||||
return ptr;
|
||||
}
|
||||
|
||||
static inline void *vkd3d_realloc(void *ptr, size_t size)
|
||||
{
|
||||
if (!(ptr = realloc(ptr, size)))
|
||||
ERR("Out of memory.\n");
|
||||
return ptr;
|
||||
}
|
||||
|
||||
static inline void *vkd3d_calloc(size_t count, size_t size)
|
||||
{
|
||||
void *ptr;
|
||||
if (!(ptr = calloc(count, size)))
|
||||
ERR("Out of memory.\n");
|
||||
return ptr;
|
||||
}
|
||||
|
||||
static inline void vkd3d_free(void *ptr)
|
||||
{
|
||||
free(ptr);
|
||||
}
|
||||
|
||||
HRESULT hresult_from_vk_result(VkResult vr) DECLSPEC_HIDDEN;
|
||||
|
||||
HRESULT vkd3d_load_vk_instance_procs(struct vkd3d_vk_instance_procs *procs,
|
||||
|
Reference in New Issue
Block a user