> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# FFT

> FFT

# FFT

具有任意样本数的快速傅里叶变换。

## Syntax

```cpp theme={null}
void FFT(  
         XMVECTOR* __restrict pReal,  
         XMVECTOR* __restrict pImaginary,  
         const XMVECTOR* __restrict pUnityTable,  
         const size_t uLength,  
         const size_t uCount= 1  
)  
```

### Parameters

*pReal*   \_Inout\_updates\_((uLength \* uCount) / 4)\
Type: XMVECTOR\* \_\_restrict

FFT 的实部分量。必须至少具有 (*uLength* × *uCount*) ÷ 4 个元素。

*pImaginary*   \_Inout\_updates\_((uLength \* uCount) / 4)\
Type: XMVECTOR\* \_\_restrict

FFT 的虚部分量。必须至少具有 (*uLength* × *uCount*) ÷ 4 个元素。

*pUnityTable*   \_In\_reads\_(uLength \* uCount)\
Type: XMVECTOR\* \_\_restrict

供 FFT 使用的单位根表。必须至少具有 *uLength* × *uCount* 个 XMVECTOR。有关详细信息,请参阅 [FFTInitializeUnityTable](/reference/audio/xdsp/functions/fftinitializeunitytable)。

*uLength*   \_In\_\
Type: size\_t

FFT 长度(以样本数表示)。*uLength* 必须是 2 的幂并大于 16。

*uCount*   \_In\_\
Type: size\_t

FFT 迭代次数。

### Return value

Type: void

无。

## Remarks

对于样本数小于或等于 16 的 FFT,请使用 [FFT16](/reference/audio/xdsp/functions/fft16)、[FFT8](/reference/audio/xdsp/functions/fft8) 或 [FFT4](/reference/audio/xdsp/functions/fft4)。

所有缓冲区参数必须按 16 字节对齐。音频数据必须为 FLOAT32 单声道。

## Requirements

**头文件:** xdsp.h

**支持的平台:** XBOX One 系列主机和 XBOX Series 主机

## See also

[xdsp](/reference/audio/xdsp/xdsp_members)


## Related topics

- [使用 XDSP API 进行单流 FFT/IFFT 概述](/zh-CN/build/console-features/audio/overviews/xdsp-overview-single-stream-fft-ifft.md)
- [FFT16](/zh-CN/reference/audio/xdsp/functions/fft16.md)
- [FFT4](/zh-CN/reference/audio/xdsp/functions/fft4.md)
- [FFT8](/zh-CN/reference/audio/xdsp/functions/fft8.md)
- [FFTInitializeUnityTable](/zh-CN/reference/audio/xdsp/functions/fftinitializeunitytable.md)
