SV_PrimitiveID is only valid as a pixel shader input if there's either
no geometry shader, or the geometry shader emits SV_PrimitiveID. With
D3D11, the debug layer will complain but rendering will proceed. With
D3D12, the PSO fails to compile. For both APIs, pixel shader debugging
now checks whether this is true, and disables its usage if it isn't.
Added tests for various valid scenarios with SV_PrimitiveID.
The logical identifiers, rather than shader registers, were used to
populate reflection info, causing the wrong slots in large descriptor
tables to be referenced for the pipeline state.
* It's not particularly scalable and can be brittle to driver changes, and we
can use targeted specific pixel tests to check what we really want - to see if
the output has rendered correctly.
* Overlay tests still check files directly - this is a future refactor to
remove.
This mimics the D3D11 shader debugging test, but performs the draws
twice - once with SM 5.0 and once with SM 5.1. The python test performs
the same checks as the D3D11 version, but is explicitly disabled since
D3D12 shader debugging is not yet enabled by default.
* This is kind of what VK_Parameter_Zoo is intended to test, but I don't want to
add conditional extension tests in there unless there's nowhere else to put
it, since it adds mental overhead to reading the code.
Made the API filters inclusive, so that if any are checked, only the
selected ones are shown. If none are selected, then all tests are
shown as before. Moved the test name filter to the top pane, so that
it is always visible - before if you scrolled down in the test list,
it would be hidden. Added more room for test descriptions in the bottom
pane - long descriptions were previously truncated.
D3D11 may default to a different adapter than D3D12. For the sharing
test, both adapters must be D3D12 compatible. Tell D3D11 to use the
adapter that D3D12 is using to ensure compatibility.
Also fixed a memory leak in the test.
On laptops with integrated+discrete adapters, adapter 0 may not
support D3D12, so a default create device call will fail. Adapters
other than the 0th one need to be specified explicitly.
* It's required for replay applications to call InitialiseReplay() before doing
any work, and to call ShutdownReplay() once they're finished.
* This lets us do more heavyweight shutdown work before global destructors are
being invoked and the RenderDoc instance is being destroyed.
* Anything that needs to be shut down during capture still has to happen in
RenderDoc::~RenderDoc since we obviously can't get the application to call a
shutdown function in that situation.
* This is needed so that the functional tests can elevate and run renderdoccmd
to register the vulkan layer, if needed.
* At the same time remove the old spammy message and ignore flag - this dates
back to before the UI existed, and that should be the way users run RenderDoc
generally and it has a good UI for walking through layer registration if
needed.
* The command is always available, but will only show up in help if attention is
needed.
* Also fix registering installs on shared drives.