d3d12: Recreate RTTs if size doesn't match.

Fix Bomberman Ultra
This commit is contained in:
Vincent Lejeune 2015-12-29 18:09:59 +01:00
parent 07f6896622
commit 324b2da3ec

View File

@ -272,7 +272,7 @@ ID3D12Resource *render_targets::bind_address_as_render_targets(ID3D12Device *dev
{
ComPtr<ID3D12Resource> rtt;
rtt = It->second.Get();
if (rtt->GetDesc().Format == dxgi_format)
if (rtt->GetDesc().Format == dxgi_format && rtt->GetDesc().Width == width && rtt->GetDesc().Height == height)
{
cmdList->ResourceBarrier(1, &CD3DX12_RESOURCE_BARRIER::Transition(rtt.Get(), D3D12_RESOURCE_STATE_GENERIC_READ, D3D12_RESOURCE_STATE_RENDER_TARGET));
return rtt.Get();