mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-28 18:18:38 +00:00
d3d12device: Store adapter index
... and remove unused fence object Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5875>
This commit is contained in:
parent
0577d1c9de
commit
b0ef890726
1 changed files with 1 additions and 16 deletions
|
@ -548,22 +548,6 @@ gst_d3d12_device_new_internal (const GstD3D12DeviceConstructData * data)
|
||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
ComPtr < ID3D12Fence > copy_fence;
|
|
||||||
hr = device->CreateFence (0,
|
|
||||||
D3D12_FENCE_FLAG_NONE, IID_PPV_ARGS (©_fence));
|
|
||||||
if (FAILED (hr)) {
|
|
||||||
GST_ERROR ("Couldn't create copy fence");
|
|
||||||
return nullptr;
|
|
||||||
}
|
|
||||||
|
|
||||||
ComPtr < ID3D12Fence > direct_fence;
|
|
||||||
hr = device->CreateFence (0,
|
|
||||||
D3D12_FENCE_FLAG_NONE, IID_PPV_ARGS (&direct_fence));
|
|
||||||
if (FAILED (hr)) {
|
|
||||||
GST_ERROR ("Couldn't create fence");
|
|
||||||
return nullptr;
|
|
||||||
}
|
|
||||||
|
|
||||||
GstD3D12Device *self = (GstD3D12Device *)
|
GstD3D12Device *self = (GstD3D12Device *)
|
||||||
g_object_new (GST_TYPE_D3D12_DEVICE, nullptr);
|
g_object_new (GST_TYPE_D3D12_DEVICE, nullptr);
|
||||||
GstD3D12DevicePrivate *priv = self->priv;
|
GstD3D12DevicePrivate *priv = self->priv;
|
||||||
|
@ -574,6 +558,7 @@ gst_d3d12_device_new_internal (const GstD3D12DeviceConstructData * data)
|
||||||
priv->adapter_luid = gst_d3d12_luid_to_int64 (&desc.AdapterLuid);
|
priv->adapter_luid = gst_d3d12_luid_to_int64 (&desc.AdapterLuid);
|
||||||
priv->vendor_id = desc.VendorId;
|
priv->vendor_id = desc.VendorId;
|
||||||
priv->device_id = desc.DeviceId;
|
priv->device_id = desc.DeviceId;
|
||||||
|
priv->adapter_index = index;
|
||||||
|
|
||||||
std::wstring_convert < std::codecvt_utf8 < wchar_t >, wchar_t >converter;
|
std::wstring_convert < std::codecvt_utf8 < wchar_t >, wchar_t >converter;
|
||||||
priv->description = converter.to_bytes (desc.Description);
|
priv->description = converter.to_bytes (desc.Description);
|
||||||
|
|
Loading…
Reference in a new issue