Fix D3D12CommandQueue::ExecuteCommandLists type confusion bug
- Cast void* to ID3D12CommandList* directly instead of D3D12CommandList* - Remove erroneous Reset() call - caller is responsible for resetting - Fixes SEH exception 0xc0000005 when executing command lists
This commit is contained in:
@@ -58,10 +58,8 @@ void D3D12CommandQueue::ExecuteCommandLists(uint32_t count, void** lists) {
|
||||
|
||||
std::vector<ID3D12CommandList*> cmdLists(count);
|
||||
for (uint32_t i = 0; i < count; ++i) {
|
||||
auto* cmdList = static_cast<D3D12CommandList*>(lists[i]);
|
||||
if (cmdList) {
|
||||
cmdList->Reset();
|
||||
cmdLists[i] = cmdList->GetCommandList();
|
||||
if (lists[i]) {
|
||||
cmdLists[i] = static_cast<ID3D12CommandList*>(lists[i]);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user