message: Don't apply graphics state to compute or copy command lists
diff: @@ -130,6 +130,10 @@ ResourceId D3D12RenderState::GetDSVID() const
  }
  void D3D12RenderState::ApplyState(ID3D12GraphicsCommandList *cmd) const
  +{
  + D3D12_COMMAND_LIST_TYPE type = cmd->GetType();
  +
  + if(type == D3D12_COMMAND_LIST_TYPE_DIRECT || type == D3D12_COMMAND_LIST_TYPE_BUNDLE)
  {
  if(pipe != ResourceId())
  cmd->SetPipelineState(GetResourceManager()->GetCurrentAs<ID3D12PipelineState>(pipe));
  @@ -182,15 +186,6 @@ void D3D12RenderState::ApplyState(ID3D12GraphicsCommandList *cmd) const
  }
  }
  - std::vector<ID3D12DescriptorHeap *> descHeaps;
  - descHeaps.resize(heaps.size());
  -
  - for(size_t i = 0; i < heaps.size(); i++)
  - descHeaps[i] = GetResourceManager()->GetCurrentAs<ID3D12DescriptorHeap>(heaps[i]);
  -
  - if(!descHeaps.empty())
  - cmd->SetDescriptorHeaps((UINT)descHeaps.size(), &descHeaps[0]);
  -
  if(!rts.empty() || dsv.heap != ResourceId())
  {
  D3D12_CPU_DESCRIPTOR_HANDLE rtHandles[8];
  @@ -206,6 +201,16 @@ void D3D12RenderState::ApplyState(ID3D12GraphicsCommandList *cmd) const
  Unwrap(cmd)->OMSetRenderTargets((UINT)rts.size(), rtHandles, rtSingle ? TRUE : FALSE,
  dsv.heap != ResourceId() ? &dsvHandle : NULL);
  }
  + }
  +
  + std::vector<ID3D12DescriptorHeap *> descHeaps;
  + descHeaps.resize(heaps.size());
  +
  + for(size_t i = 0; i < heaps.size(); i++)
  + descHeaps[i] = GetResourceManager()->GetCurrentAs<ID3D12DescriptorHeap>(heaps[i]);
  +
  + if(!descHeaps.empty())
  + cmd->SetDescriptorHeaps((UINT)descHeaps.size(), &descHeaps[0]);
  if(graphics.rootsig != ResourceId())
  {
  