[d3d11] Flush CS chunks when executing/finalizing command lists

Fixes rendering issues and validation errors in Kingdom Come: Deliverance.
This commit is contained in:
Philip Rebohle 2018-03-12 23:36:55 +01:00
parent fa78259459
commit 06cff50453
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99
2 changed files with 6 additions and 0 deletions

View File

@ -31,6 +31,8 @@ namespace dxvk {
void STDMETHODCALLTYPE D3D11DeferredContext::ExecuteCommandList(
ID3D11CommandList* pCommandList,
BOOL RestoreContextState) {
FlushCsChunk();
static_cast<D3D11CommandList*>(pCommandList)->EmitToCommandList(m_commandList.ptr());
if (RestoreContextState)
@ -43,6 +45,8 @@ namespace dxvk {
HRESULT STDMETHODCALLTYPE D3D11DeferredContext::FinishCommandList(
BOOL RestoreDeferredContextState,
ID3D11CommandList **ppCommandList) {
FlushCsChunk();
if (ppCommandList != nullptr)
*ppCommandList = m_commandList.ref();
m_commandList = CreateCommandList();

View File

@ -66,6 +66,8 @@ namespace dxvk {
void STDMETHODCALLTYPE D3D11ImmediateContext::ExecuteCommandList(
ID3D11CommandList* pCommandList,
BOOL RestoreContextState) {
FlushCsChunk();
static_cast<D3D11CommandList*>(pCommandList)->EmitToCsThread(&m_csThread);
if (RestoreContextState)