Changes to the capture experience

Matt Amert

Summary

As some of you have likely noticed by now, PIX.2008-26 comes with some improvements to the overall capture and Start-Analysis experience, made possible by the rewrite of the capture layer within PIX on Windows. This is a list of the major changes – read on for a detailed explanation!

  • When launching your application, PIX no longer has the option for “Ignore D3D11” – it is not necessary under the new capture layer.
  • Capture files now only contain one capture.
  • Captures can be opened without closing your application.
  • New Start Analysis UI to reflect the changes.

API selection change – no more “ignore D3D11”

Background

In previous versions of PIX, there were three different options when launching your application: Default, D3D12 (force 11on12), and D3D12 (ignore D3D11).

However, PIX only captures D3D12 work, so you might be wondering: what’s with the “ignore D3D11” option?

The answer is that it changed the layer at which PIX inserted itself into the D3D/DXGI stack, which had effects on how PIX handled D3D11 API calls. Before PIX.2008-26, the “Default” option made PIX intercept all D3D12 and DXGI calls made by your application so that it could accurately replay them later. However, due to DXGI’s implementation, intercepting all calls to DXGI meant that PIX was required to also intercept all D3D11 calls as well. Since PIX on Windows does not support capturing/replaying D3D11 work, PIX would stop your application with an error message if your application used D3D11.

Although the “force D3D11on12” option existed, it sometimes proved difficult to use if e.g. your D3D12 code was hosted in a D3D11 UI framework/game and you didn’t want to see the translated D3D11 work. Consequently, PIX introduced the “ignore D3D11” option, which effectively moved PIX down a layer. It no longer captured DXGI work, and as a result didn’t need to capture D3D11 work. Instead, PIX captured just your application’s D3D12 work and the D3D12 work generated by DXGI.

This would have solved most of the issues mentioned, but unfortunately, PIX’s old capture layer architecture would occasionally cause lock inversions with this method, meaning some applications could not run with this option enabled.

New Capture Layer

With the new capture layer, PIX always sits below DXGI and, with no lock inversion issues from the old version, doesn’t have issues capturing applications that use both D3D11 and D3D12.

Therefore, the “ignore D3D11” option is now redundant and has been removed with this version, leaving only “Force D3D11On12.” If you are interested in learning more about the D3D11On12 option, keep your eye out for a future blog post which will explain it in a bit more detail.

A screenshot of a cell phone Description automatically generated

Implications

Since PIX on Windows now only captures GPU work done by D3D12, it can capture resources that have been modified by D3D11 but used within D3D12. Note, though, that there are some limitations to this: for example, after starting a capture and using a resource in D3D12, then any modifications that you make to the resource through D3D11 will not be captured unless you enable “Force D3D11On12.”

Also, now that PIX will capture work done by DXGI – but not DXGI calls themselves – you may notice some differences in your event list. For instance, the Present event is now an internal DXGI version, and not the one your application called. Additionally, if you use PIX on a device that has both an integrated and discrete GPU, you may notice that the Present call has been translated into some copy commands which move the data over to the other GPU for the OS to compose.

Only one capture per file

In the previous versions of PIX on Windows, all captures made during a session were saved into the same capture file. This was often confusing, especially since the UI did not convey this at all. For example, if you opened 3 captures from the same session and saved them all individually, then you would have 3 captures files and all 3 of them would contain every capture made during that capture session.

This understandably proved confusing to users, especially to those that also use the Xbox version of PIX, where there is only one capture per file. Ultimately, to better align with Xbox, PIX on Windows now also keeps only one capture per file. Don’t forget this the next time you want to save your captures 😊

Open captures without closing your application

PIX on Windows has already supported opening captures while the application continues to run, enabled with the setting “Keep capture session alive on GPU capture open.” However, each time you opened a capture while the application was running, PIX internally created a new capture file. This proved very confusing because there was no way to tell which file each capture belonged to, sometimes leading to lost work. As such, this feature was turned off by default.

Now that there is only one capture per file, this is not an issue. Therefore, PIX will no longer close your application when you open a capture. But keep in mind that starting analysis on a capture will take up a chunk of your machine’s GPU resources; you may notice slow-downs in both PIX and your application if you decide to leave both running. To better reflect this, we have updated the Start Analysis UI:

Start Analysis UI

A screenshot of a cell phone Description automatically generated

By default, pressing the Start Analysis button will have no effect on your running application. The second option is available if you do want PIX to close your application before it starts replaying the captured events. This is important if you don’t want to forget that both PIX and your application are fighting for resources.

The option is also sticky – the next time you need to start analysis, your most recent choice will be used by default and the icon will reflect this.

And lastly, when you open a capture with your application still running for the very first time, PIX will greet you with this popup as a reminder.

A screenshot of a cell phone Description automatically generated

Feedback

As always, feel free to reach out to us with any feedback or questions on our Discord server or simply use the little feedback button in the top right corner of your PIX window 😊

Up next, the illustrious Austin Kinross will discuss in more detail how PIX.2008-26 has added support for D3D12 video APIs. Keep your eyes out for that!

0 comments

Discussion is closed.

Feedback usabilla icon