
Frame Debugger
The Frame Debugger gives you access to the drawcalls within your application and allows you to view their states and resources. It is possible to pause your application on any given frame and analyze the elements that make up the current frame buffer image. The user may scrub through the draw calls to locate the draw call of interest. The Frame Debugger specializes in viewing the active state for any draw call in a frame and has specialized data viewers for image and description based data. Each data viewer is a dockable window that can be placed and resized by the user to make custom layouts that can be saved and reloaded.
|

|
|
This screen shot is a typical window layout for the Frame Debugger showing the active textures, the depth buffer, the geometry being drawn, and the vertex buffer information. |
Image based data windows include:
- RenderTargets
- Textures
- Swapchain
- Depth buffer
- Stencil buffer
- Input geometry
|

|
|
Screen shot of the texture viewer showing the resource and resource view information. Users can select the mipmap level and index of the cube array to be displayed, zoom and pan around the image. |
Text based data windows include:
- Index Buffer
- Vertex Buffer
- Input layout
- Topology
- Render State
|

|
|
Screen shot of the index buffer, topology, input layout, vertex buffer, and render state viewers. |
Shader Debugger
The Shader Debugger allows you to debug HLSL and ASM Pixel Shaders inside your application. It allows you to step through pixel shaders one line at a time and view the registers, variables, and constant values at each pixel. It is even possible to insert breakpoints in the code so that you can quickly jump to a particular line and start debugging. To aid in understanding the flow control of your shader, a Draw Mask image visualizes which pixels were written by the previous instruction.
Shader Debugger Features:
- Step through HLSL or ASM code line by line
- View registers, constants, and variable values at each pixel
- Insert and run to breakpoints
- Step forwards or backwards
- View the draw mask for each instruction
|

|
|
This screen shot shows a typical shader debug session. Stepping through the HLSL code updates the draw masks on the right hand side, and updates the variables table at the bottom. |
The Shader Debugger features a code window that offers the conventional debug features, including user break points, run to, run back, step forward, and step back. Two images provide access to the pixel values currently output by the shader. One image shows the draw mask indicating the pixels that have been rendered, and the second image shows the current register values of the pixels. In addition, a table of the current constants and variable buffer values is displayed. The user can click in the either of the images to select the pixel being debugged.
|

|
|
The Shader Debugger renders the shader output at the breakpoint to the swapchain. This allows you to see where your shader is rendering on your application screen as well as in the Draw Mask. |
|

|
|
This image shows the constants and variables for a specific pixel. |
Frame Profiler
The Frame Profiler provides both a simple overview of the current frame profile – along with more in depth analysis tools. The initial overview allows you to determine if your application is bound by the CPU or GPU. The in-depth analysis provides access to individual counters and allows you to save custom selections for specialized workflow.
|

|
|
This screen shot shows the simple overview of the frame profile and indicates if your application is CPU or GPU bound. |
By performing a more detailed profile of your application using the full counter set or a custom set, you can identify which draw calls are the most expensive. With the integration of the Shader Debugger and Frame Debugger it is possible to identify which aspect of the frame is causing bottlenecks.
|

|
|
Screen shot of the counter selection window. Users select the counters they wish to profile individually or by group. |
The profiler results link directly to the drawcalls in the Frame Debugger allowing you to select a draw call from the Frame Profiler and jump to that draw call in the Frame Debugger.
|

|
|
Screen shot of the Frame Profiler showing the integration with FrameDebugger usage. Users click on a drawcall in the table and the Frame Dbugger jumps to that draw call and updates the viewers with current information. |
Frame Profiler features:
- Supports a simple timing pass to get a quick understanding of where performance issues are.
- Users can make custom counters selections to get in-depth counter information for each draw call.
- Custom counter selections can be saved to disk.
- The Profiler results can be saved to disk and re-loaded allowing offline analysis.
- The Profiler is integrated with the Frame Debugger allowing you to quickly identify performance issues with specific draw calls.