Buffer Tab

A buffer tab displays the contents of a buffer. Use this tab to view the data in a vertex or index buffer.

The buffer tab has two sub-tabs:

Buffer Sub-Tab

Buffer data is displayed in a table in the buffer sub-tab; the default format is a single column of floats. Here are two methods for creating a buffer tab.

Layout Sub-Tab

Use the layout sub-tab to format the way the data is displayed in the buffer sub-tab. The layout sub-tab is looking for a vertex (or index) buffer declaration to identify the layout of the data in the buffer. The easiest way to do this is to use HLSL syntax as if you were writing shader code.

The format is specified with type/name pairs such as:

float3 position

For instance, to format the buffer sub-tab to display a buffer with position, normal and texture data (as shown in the example at the top of the page), you could use a declaration like this.

The layout sub-tab does not require exact HLSL syntax, but you do need to use valid HLSL basic types. The variable names you assign are arbitrary. If the size of the buffer being displayed is not a multiple of the size of the of the HLSL types specified, an error message will be displayed.

The layout sub-tab supports all the HLSL data types including vectors and matrices. All of the following are valid type/name pairs.

float3
vector<uint 3>
float3x3
matrix<xshort,2,2>

In the table, some of the types are displayed differently.

The layout sub-tab also supports the following type modifiers.

s = signed
u = unsigned
x = unsigned hex

Customizing the Layout

To assign a format to a type/name pair, but not display the data, use a percent sign between the type/name declaration.

float3 % position

The type/name pair will be used as a placeholder, but the pair will not be displayed.

See Also

Details View