> ## 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.

# ApuHeapState

> ApuHeapState

# ApuHeapState

APU 的堆状态。

## Syntax

```cpp theme={null}
typedef struct ApuHeapState {  
    UINT32 bytesFree;  
    UINT32 bytesAllocated;  
    UINT32 bytesLost;  
    UINT32 maximumBlockSizeAvailable;  
    UINT32 allocationCount;  
} ApuHeapState  
```

### Members

*bytesFree*\
Type: UINT32

所有未分配区域的大小。

*bytesAllocated*\
Type: UINT32

所有已分配区域的大小(从游戏视角所见)。

*bytesLost*\
Type: UINT32

因对齐请求以及碎片化后过小无法分配而损失的所有内存的大小。

*maximumBlockSizeAvailable*\
Type: UINT32

可用的最大块。由于对齐要求,实际可用空间可能更小。

*allocationCount*\
Type: UINT32

所有已分配块的计数。

## Remarks

此结构由 [ApuHeapGetState](/reference/audio/apu/functions/apuheapgetstate) 输出。

APU 堆由 [ApuCreateHeap](/reference/audio/apu/functions/apucreateheap) 创建。堆在进程的整个生命周期内保持有效。

## Requirements

**头文件:** apu.h

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

## See also

[ApuHeapGetState](/reference/audio/apu/functions/apuheapgetstate)\
[APU](/reference/audio/apu/apu_members)


## Related topics

- [ApuHeapGetState](/zh-CN/reference/audio/apu/functions/apuheapgetstate.md)
- [APU(音频处理单元)](/zh-CN/reference/audio/apu/apu_members.md)
- [ApuCreateHeap](/zh-CN/reference/audio/apu/functions/apucreateheap.md)
- [XApuStateOptions](/zh-CN/reference/audio/xapu/enums/xapustateoptions.md)
- [XApuProcessType](/zh-CN/reference/audio/xapu/enums/xapuprocesstype.md)
