Skip to main content

Interleave

This function interleaves audio samples so that all samples that correspond to a specified frame are contiguous.

Syntax

Parameters

pOutput   _Out_writes_((uChannelCount * uFrameCount) / 4)
Type: XMVECTOR* __restrict
Caller-provided array of XMVECTOR elements that receives the samples in interleaved form. It cannot overlap pInput, and it must have at least (uChannelCount × uFrameCount) ÷ 4 elements. pInput   _In_reads_((uChannelCount * uFrameCount) / 4)
Type: XMVECTOR* __restrict
Caller-provided array of XMVECTOR elements that supplies audio samples in deinterleaved form. It cannot overlap pOutput, and it must have at least (uChannelCount × uFrameCount) ÷ 4 elements. uChannelCount   _In_
Type: size_t
Number of channels contained in the data. uChannelCount must be greater than 1. uFrameCount   _In_
Type: size_t
Number of frames of valid data. uFrameCount must be greater than 0.

Return value

Type: void None.

Remarks

For example, the audio of the form [LLLRRR] becomes [LRLRLR]. For more information about Interleave classes and members, see Interleave Class. For information about the Deinterleave function, see Deinterleave.

Requirements

Header: xdsp.h Supported platforms: XBOX One family consoles and XBOX Series consoles

See also

xdsp Game for Windows and the DirectX SDK blog Microsoft Audio/Video Interleaved
Last modified on August 20, 2026