Godot Engine – Multi-platform 2D and 3D game engine
Don't use CreateCommandList1 on D3D12.
Dario568833cb86ca
diff --git a/drivers/d3d12/rendering_device_driver_d3d12.cpp b/drivers/d3d12/rendering_device_driver_d3d12.cppindex 976f3af6e2d..5afb1b7aa09 100644--- a/drivers/d3d12/rendering_device_driver_d3d12.cpp+++ b/drivers/d3d12/rendering_device_driver_d3d12.cpp@@ -2577,18 +2577,9 @@ RDD::CommandBufferID RenderingDeviceDriverD3D12::command_buffer_create(CommandPoComPtr<ID3D12GraphicsCommandList> cmd_list;{- ComPtr<ID3D12Device4> device_4;- device->QueryInterface(device_4.GetAddressOf());- HRESULT res = E_FAIL;- if (device_4) {- res = device_4->CreateCommandList1(0, list_type, D3D12_COMMAND_LIST_FLAG_NONE, IID_PPV_ARGS(cmd_list.GetAddressOf()));- } else {- res = device->CreateCommandList(0, list_type, cmd_allocator.Get(), nullptr, IID_PPV_ARGS(cmd_list.GetAddressOf()));- }+ HRESULT res = device->CreateCommandList(0, list_type, cmd_allocator.Get(), nullptr, IID_PPV_ARGS(cmd_list.GetAddressOf()));ERR_FAIL_COND_V_MSG(!SUCCEEDED(res), CommandBufferID(), "CreateCommandList failed with error " + vformat("0x%08ux", (uint64_t)res) + ".");- if (!device_4) {- cmd_list->Close();- }+ cmd_list->Close();}CPUDescriptorHeapPool::Allocation uav_alloc;