D3D10_BUFFER_DESC structure (d3d10.h)

Describes a buffer resource.

Syntax

typedef struct D3D10_BUFFER_DESC {
  UINT        ByteWidth;
  D3D10_USAGE Usage;
  UINT        BindFlags;
  UINT        CPUAccessFlags;
  UINT        MiscFlags;
} D3D10_BUFFER_DESC;

Members

ByteWidth

Type: UINT

Size of the buffer in bytes.

Usage

Type: D3D10_USAGE

Identify how the buffer is expected to be read from and written to. Frequency of update is a key factor. The most common value is typically D3D10_USAGE_DEFAULT; see D3D10_USAGE for all possible values.

BindFlags

Type: UINT

Identify how the buffer will be bound to the pipeline. Applications can logically OR flags together (see D3D10_BIND_FLAG) to indicate that the buffer can be accessed in different ways.

CPUAccessFlags

Type: UINT

CPU access flags (see D3D10_CPU_ACCESS_FLAG) or 0 if no CPU access is necessary. Applications can logically OR flags together.

MiscFlags

Type: UINT

Miscellaneous flags (see D3D10_RESOURCE_MISC_FLAG) or 0 if unused. Applications can logically OR flags together.

Remarks

This structure is used by ID3D10Device::CreateBuffer to create buffer resources.

In addition to this structure, there is also a derived structure in D3D10.h (CD3D10_BUFFER_DESC) which behaves like an inherited class to help create a buffer description.

Requirements

Requirement Value
Header d3d10.h

See also

Resource structures