From f537474fe43dff25bf6659771f5fa3fdf71ce5d8 Mon Sep 17 00:00:00 2001 From: Joshua Ashton Date: Sat, 6 Jun 2020 20:17:13 +0100 Subject: [PATCH] [d3d9] Add missing locks to mipmap auto gen --- src/d3d9/d3d9_texture.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/d3d9/d3d9_texture.h b/src/d3d9/d3d9_texture.h index 47f09a84f..4b070a3c5 100644 --- a/src/d3d9/d3d9_texture.h +++ b/src/d3d9/d3d9_texture.h @@ -77,6 +77,8 @@ namespace dxvk { if (unlikely(FilterType == D3DTEXF_NONE)) return D3DERR_INVALIDCALL; + auto lock = this->m_parent->LockDevice(); + m_texture.SetMipFilter(FilterType); return D3D_OK; } @@ -89,6 +91,8 @@ namespace dxvk { if (!m_texture.NeedsMipGen()) return; + auto lock = this->m_parent->LockDevice(); + this->m_parent->MarkTextureMipsUnDirty(&m_texture); this->m_parent->EmitGenerateMips(&m_texture); }