• Advertisement
Sign in to follow this  

Reuse commands in DirectX 12

Recommended Posts

Hi. It is a little bit unclear for me. I have in hands demos from Intel and they create reset and put commands to the command lists at any frame. If my commands are going to be always the same for the whole program and in the same order, how can I reuse for real the commands. How to create the command list, put the commands inside and just use it in each frame, not issuing all the commands again and again? I need to know why all the demos are doing it this way(re-issuing the command to the command list)? Is it required to be that way by the designers of the API? Do I have to create a bundle of the size of the whole command list if I want pre-compilation?

Share this post


Link to post
Share on other sites
Advertisement

You can just reuse the command list instead of resetting it (make sure you also don't reset the allocator).

Most games don't do this because the specific rendering commands and the order that they should be processed in does tend to change every frame. If you've got small bits of re-use (e.g. one object / under 10 draws), then bundles are ok. If you've got massive bits of reuse, then record a whole command buffer and keep it around.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this  

  • Advertisement