Closed john-h-k closed 4 years ago
That's a great suggestion. That said, I think only D3D12_COMMAND_LIST_TYPE_DIRECT
, D3D12_COMMAND_LIST_TYPE_BUNDLE
, or D3D12_COMMAND_LIST_TYPE_COPY
would actually work. The class issues copy commands on the command-list, so D3D12_COMMAND_LIST_TYPE_COMPUTE
wouldn't work.
The ResourceUploadBatch can also not use a D3D12_COMMAND_LIST_TYPE_COPY
command-list when generating mipmaps.
And there are a few challenges with the implicit resource barrier.
The ResourceUploadBatch can also not use a D3D12_COMMAND_LIST_TYPE_COPY command-list when generating mipmaps.
I guess the easiest way to go around this is check if mGenMipsResources
isn't null in End
, and if it isn't, then throw an exception?
Here's a PR for the library:
https://github.com/microsoft/DirectXTK12/pull/71
Here's a PR for the test suite:
https://github.com/walbourn/directxtk12test/pull/17
Please take a look at these instructions to try it out yourself as I can use some help in testing this on more systems.
Currently providing a
ID3D12CommandQueue*
toResourceUploadBatch::End
generates an error if the queue is not of typeD3D12_COMMAND_LIST_TYPE_DIRECT
;This can just be changed to
and this is now all fixed. Would be useful