mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-19 06:46:38 +00:00
d3d11memory: Allow CreateSharedHandle() without keyed mutex
For d3d11 resource to be shared with d3d12, keyed mutex shouldn't be enabled since d3d12 resource does not expose the keyed mutex interface Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5356>
This commit is contained in:
parent
bb040ce571
commit
2aa88033b2
1 changed files with 3 additions and 3 deletions
|
@ -1416,8 +1416,6 @@ gboolean
|
|||
gst_d3d11_memory_get_nt_handle (GstD3D11Memory * mem, HANDLE * handle)
|
||||
{
|
||||
GstD3D11MemoryPrivate *priv;
|
||||
const guint misc_flags = D3D11_RESOURCE_MISC_SHARED_KEYEDMUTEX |
|
||||
D3D11_RESOURCE_MISC_SHARED_NTHANDLE;
|
||||
ComPtr < IDXGIResource1 > resource;
|
||||
HRESULT hr;
|
||||
|
||||
|
@ -1437,8 +1435,10 @@ gst_d3d11_memory_get_nt_handle (GstD3D11Memory * mem, HANDLE * handle)
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
if ((priv->desc.MiscFlags & misc_flags) != misc_flags)
|
||||
if ((priv->desc.MiscFlags & D3D11_RESOURCE_MISC_SHARED_NTHANDLE) !=
|
||||
D3D11_RESOURCE_MISC_SHARED_NTHANDLE) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
hr = priv->texture->QueryInterface (IID_PPV_ARGS (&resource));
|
||||
if (!gst_d3d11_result (hr, mem->device))
|
||||
|
|
Loading…
Reference in a new issue