PIX Counters
Microsoft DirectX 9.0 SDK Update (October 2004)

PIX Counters


PIX contains a number of counters for collecting and displaying information about each rendered frame. The counters are configured in an experiment. There are three types of counters:

  1. Microsoft Direct3D counters, which report information specifically about Direct3D.
  2. Performance counters, which report system performance information.
  3. Plugin counters, which can be implemented by third parties to provide custom information.

PIX Direct3D Counters

These counters keep track of Direct3D application programming interface (API) calls. There are several types of counters:

TypesDescription
General CountersCalculate general Direct3D performance metrics.
Primitive CountersCount the number of draw calls.
Resource CountersKeep track of memory allocation and object creation.
State Change CountersCount the number of state changes.
Shader Constant CountersCount the number of shader constants.

General Counters

These counters calculate metrics for the entire application such as:

Primitive Counters

These counters monitor drawing activity by watching each type of draw call. There are separate counters for each of the four types of drawing methods:

For each type of drawing method, you can track:

Alternately, you can use the Draw* counter to gather information about all draw calls.

Resource Counters

These counters measure the memory activity related to resources. Things like memory allocations for creating resources or objects. You can measure individual types of resources such as vertex buffers, index buffers, or textures. For each resource, memory resources may exist in many different types of memory pools. For each pool type (default pool, managed pool, system pool, scratch pool), you can use any of the following counters:

Alternately, you can use the All Resources counter to gather information about all resource calls. And you can use the All pools counter to gather information about calls to all the memory pools.

State Change Counters

These counters keep track of the number of state changes. Each of the state changes is tracked as the number of times each of these methods is called:

Shader Constant Counters

These counters keep track of the number of shader constants that are set by tracking:

Performance Data Counters

Performance counters track overall performance of the application.

Common in-process counters measure in-process metrics such as:

On the other hand, there are also system-wide counters for measuring metrics across processes such as:

In addition there are many other performance counters available. Run PIX and look under All Performance Counters to see a full listing.

User Plug-in Counters

PIX also supports user plug-ins. This allows you to create your own plug-ins, in a separate dynamic-link library (DLL), and then access them from PIX. See the sample program PIXPluginSample for more information about writing a plugin counter.

Countersets

Countersets provide a convenient way to group together a list of counters for easy access. To create a counterset, add the counters you want to an experiment, then click Save As Counterset. After naming the counterset, the counterset will appear under My Countersets in the counter chooser. You can add all counters in a counterset to an experiment by selecting it and clicking Add. You can rename or delete a counterset by right-clicking its name. You can also remove counters from a counterset by right-clicking them.



© 2004 Microsoft Corporation. All rights reserved.
Feedback? Please provide us with your comments on this topic.
For more help, visit the DirectX Developer Center.