-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Removed ALLOW_TEARING flag and disabled multi-thread protection when …
…not needed.
- Loading branch information
Showing
3 changed files
with
13 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -306,15 +306,6 @@ bool CContext::CreateContext() | |
featureLevels.size(), D3D11_SDK_VERSION, &pD3DDevice, nullptr, | ||
&pD3DDeviceContext); | ||
|
||
if (SUCCEEDED(hr)) | ||
{ | ||
// enable multi-threaded protection | ||
ComPtr<ID3D11Multithread> multithread; | ||
hr = pD3DDevice.As(&multithread); | ||
if (SUCCEEDED(hr)) | ||
multithread->SetMultithreadProtected(1); | ||
} | ||
|
||
if (FAILED(hr)) | ||
{ | ||
CLog::LogF(LOGWARNING, "unable to create device for decoding, fallback to using app device."); | ||
|
@@ -339,6 +330,15 @@ bool CContext::CreateContext() | |
return false; | ||
} | ||
|
||
if (FAILED(hr) || !m_sharingAllowed) | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
thexai
Author
Owner
|
||
{ | ||
// enable multi-threaded protection only if is used same d3d11 device for rendering and decoding | ||
ComPtr<ID3D11Multithread> multithread; | ||
hr = pD3DDevice.As(&multithread); | ||
if (SUCCEEDED(hr)) | ||
multithread->SetMultithreadProtected(1); | ||
} | ||
|
||
QueryCaps(); | ||
|
||
// Some older Ati devices can only open a single decoder at a given time | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
please check that video bookmarks and taking screenshot work well without protection. I'm not sure that we can safety disable protection.