mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2025-04-13 05:43:18 -07:00
vkd3d: Implement private data for command lists.
Signed-off-by: Józef Kucia <jkucia@codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
committed by
Alexandre Julliard
parent
f92abd7147
commit
ec13f36681
@@ -1610,6 +1610,8 @@ static ULONG STDMETHODCALLTYPE d3d12_command_list_Release(ID3D12GraphicsCommandL
|
||||
{
|
||||
struct d3d12_device *device = list->device;
|
||||
|
||||
vkd3d_private_store_destroy(&list->private_store);
|
||||
|
||||
/* When command pool is destroyed, all command buffers are implicitly freed. */
|
||||
if (list->allocator)
|
||||
d3d12_command_allocator_free_command_buffer(list->allocator, list);
|
||||
@@ -1625,25 +1627,31 @@ static ULONG STDMETHODCALLTYPE d3d12_command_list_Release(ID3D12GraphicsCommandL
|
||||
static HRESULT STDMETHODCALLTYPE d3d12_command_list_GetPrivateData(ID3D12GraphicsCommandList *iface,
|
||||
REFGUID guid, UINT *data_size, void *data)
|
||||
{
|
||||
FIXME("iface %p, guid %s, data_size %p, data %p stub!", iface, debugstr_guid(guid), data_size, data);
|
||||
struct d3d12_command_list *list = impl_from_ID3D12GraphicsCommandList(iface);
|
||||
|
||||
return E_NOTIMPL;
|
||||
TRACE("iface %p, guid %s, data_size %p, data %p.\n", iface, debugstr_guid(guid), data_size, data);
|
||||
|
||||
return vkd3d_get_private_data(&list->private_store, guid, data_size, data);
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE d3d12_command_list_SetPrivateData(ID3D12GraphicsCommandList *iface,
|
||||
REFGUID guid, UINT data_size, const void *data)
|
||||
{
|
||||
FIXME("iface %p, guid %s, data_size %u, data %p stub!\n", iface, debugstr_guid(guid), data_size, data);
|
||||
struct d3d12_command_list *list = impl_from_ID3D12GraphicsCommandList(iface);
|
||||
|
||||
return E_NOTIMPL;
|
||||
TRACE("iface %p, guid %s, data_size %u, data %p.\n", iface, debugstr_guid(guid), data_size, data);
|
||||
|
||||
return vkd3d_set_private_data(&list->private_store, guid, data_size, data);
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE d3d12_command_list_SetPrivateDataInterface(ID3D12GraphicsCommandList *iface,
|
||||
REFGUID guid, const IUnknown *data)
|
||||
{
|
||||
FIXME("iface %p, guid %s, data %p stub!\n", iface, debugstr_guid(guid), data);
|
||||
struct d3d12_command_list *list = impl_from_ID3D12GraphicsCommandList(iface);
|
||||
|
||||
return E_NOTIMPL;
|
||||
TRACE("iface %p, guid %s, data %p.\n", iface, debugstr_guid(guid), data);
|
||||
|
||||
return vkd3d_set_private_data_interface(&list->private_store, guid, data);
|
||||
}
|
||||
|
||||
static HRESULT STDMETHODCALLTYPE d3d12_command_list_SetName(ID3D12GraphicsCommandList *iface, const WCHAR *name)
|
||||
@@ -4282,6 +4290,8 @@ static HRESULT d3d12_command_list_init(struct d3d12_command_list *list, struct d
|
||||
list->device = device;
|
||||
ID3D12Device_AddRef(&device->ID3D12Device_iface);
|
||||
|
||||
vkd3d_private_store_init(&list->private_store);
|
||||
|
||||
list->allocator = allocator;
|
||||
|
||||
if (SUCCEEDED(hr = d3d12_command_allocator_allocate_command_buffer(allocator, list)))
|
||||
|
@@ -765,6 +765,8 @@ struct d3d12_command_list
|
||||
|
||||
struct d3d12_command_allocator *allocator;
|
||||
struct d3d12_device *device;
|
||||
|
||||
struct vkd3d_private_store private_store;
|
||||
};
|
||||
|
||||
HRESULT d3d12_command_list_create(struct d3d12_device *device,
|
||||
|
Reference in New Issue
Block a user