New read-only types:
(RW)ByteAddressBuffertype is a buffer that is DWORD-aligned byte-addressable. What this means is that I can pack an arbitrary mix of scalar and struct types into a buffer, and then pull the data out with a cast.
(RW)StructuredBuffertype is an extension to the
Buffertype in that it allows arbitrary structures to be stored. For example, we might wish to store per-instance data in a structure for cleaner code:
float3 color1, color2;
PS_INPUT VS(VS_INPUT input)
Vert v = data[input.instanceid];
// Use v to compute vertex properties
RWBuffertype is simply an extension to the
Buffertype in that it allows reading and writing in pixel and compute shaders.
Next, we have the read-write texture types. These new types will have exciting new possibilities and will eliminate the need to ping-pong two textures in some cases. These types are pixel-addressable.
Finally, we have the stream data types. The stream types are meant for applications that deal with variable amounts of data that need not preserve ordering of records. For example, say we want to emit per-fragment data from the pixel shader, but not into a texture. We can define a structure that describes a fragment, and then we can emit the structures.
f.color = ...;
f.depth = ...;
f.location = ...;
Now say we would like to process each fragment in a compute shader.
// Compute result and write to texture
frame[f.location] = ...;