A read/write buffer.

Method Description
GetDimensions Gets the resource dimensions.
Load Gets one value in a read-write buffer.
Operator[] Returns a resource variable.


A resource variable can also be passed into any unordered or interlocked operation.

RWBuffer objects can be prefixed with the storage class globallycoherent. This storage class causes memory barriers and syncs to flush data across the entire GPU such that other groups can see writes. Without this specifier, a memory barrier or sync will flush a UAV only within the current group.

Minimum Shader Model

This object is supported in the following shader models.

Shader Model Supported
Shader Model 5 and higher shader models yes


This object is supported for the following types of shaders:

Vertex Hull Domain Geometry Pixel Compute
x x


See also

Shader Model 5 Objects