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

# ShapeXmaContext

> ShapeXmaContext

# ShapeXmaContext

ShapeXmaContext API

## Functions

| 函数 | 说明 |
| - | - |
| [GetShapeXmaCurrentInputBuffer](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmacurrentinputbuffer.md) | 获取当前输入缓冲区。 |
| [GetShapeXmaErrorSet](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaerrorset.md) | 获取指示是否发生错误的标志。 |
| [GetShapeXmaErrorStatus](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaerrorstatus.md) | 获取当前错误值。 |
| [GetShapeXmaInputBuffer0](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmainputbuffer0.md) | 获取左输入缓冲区的地址。 |
| [GetShapeXmaInputBuffer0Size](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmainputbuffer0size.md) | 获取左输入缓冲区的大小。 |
| [GetShapeXmaInputBuffer0Valid](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmainputbuffer0valid.md) | 获取左输入缓冲区的有效性标志。 |
| [GetShapeXmaInputBuffer1](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmainputbuffer1.md) | 获取右输入缓冲区的地址。 |
| [GetShapeXmaInputBuffer1Size](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmainputbuffer1size.md) | 获取右输入缓冲区的大小。 |
| [GetShapeXmaInputBuffer1Valid](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmainputbuffer1valid.md) | 获取右输入缓冲区的有效性标志。 |
| [GetShapeXmaInputBufferReadOffset](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmainputbufferreadoffset.md) | 获取当前输入缓冲区的读取偏移量。 |
| [GetShapeXmaInputBufferValid](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmainputbuffervalid.md) | 获取输入缓冲区的有效性标志。 |
| [GetShapeXmaInterruptWhenDone](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmainterruptwhendone.md) | 保留供内部使用。 |
| [GetShapeXmaLoopEndOffset](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaloopendoffset.md) | 获取 XMA 上下文循环的结束偏移量。 |
| [GetShapeXmaLoopStartOffset](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaloopstartoffset.md) | 获取 XMA 上下文循环的起始偏移量。 |
| [GetShapeXmaLoopSubframeEnd](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaloopsubframeend.md) | 获取循环的最后一个子帧的编号。 |
| [GetShapeXmaLoopSubframeSkip](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaloopsubframeskip.md) | 获取在循环开始处要跳过的子帧数量。 |
| [GetShapeXmaNumChannels](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmanumchannels.md) | 获取通道数。 |
| [GetShapeXmaNumLoops](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmanumloops.md) | 获取 XMA 上下文循环的数量。 |
| [GetShapeXmaNumSubframesToDecode](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmanumsubframestodecode.md) | 获取每次运行要解码的子帧数量。 |
| [GetShapeXmaNumSubframesToSkip](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmanumsubframestoskip.md) | 获取要跳过的子帧数量。 |
| [GetShapeXmaOutputBuffer](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaoutputbuffer.md) | 获取输出缓冲区的地址。 |
| [GetShapeXmaOutputBufferNumBytesAvailable](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaoutputbuffernumbytesavailable.md) | 获取可从输出缓冲区读取的字节数。 |
| [GetShapeXmaOutputBufferNumFramesAvailable](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaoutputbuffernumframesavailable.md) | 获取可从输出缓冲区读取的帧数。 |
| [GetShapeXmaOutputBufferReadOffset](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaoutputbufferreadoffset.md) | 获取输出缓冲区的读取偏移量。 |
| [GetShapeXmaOutputBufferSize](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaoutputbuffersize.md) | 获取输出缓冲区的大小。 |
| [GetShapeXmaOutputBufferValid](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaoutputbuffervalid.md) | 获取输出缓冲区的有效性标志。 |
| [GetShapeXmaOutputBufferWriteOffset](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaoutputbufferwriteoffset.md) | 获取输出缓冲区的写入偏移量。 |
| [GetShapeXmaOverlapAddBuffer](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaoverlapaddbuffer.md) | 获取重叠相加缓冲区的地址。 |
| [GetShapeXmaPacketMetadata](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmapacketmetadata.md) | 保留供内部使用。 |
| [GetShapeXmaParserErrorSet](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaparsererrorset.md) | 获取指示是否发生 XMA 解析器错误的标志。 |
| [GetShapeXmaParserErrorStatus](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmaparsererrorstatus.md) | 获取当前 XMA 解析器错误值。 |
| [GetShapeXmaSampleRate](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmasamplerate.md) | 获取采样率。 |
| [GetShapeXmaStopWhenDone](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/getshapexmastopwhendone.md) | 保留供内部使用。 |
| [SetShapeXmaCurrentInputBuffer](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmacurrentinputbuffer.md) | 设置当前输入缓冲区。 |
| [SetShapeXmaInputBuffer0(SHAPE\_XMA\_CONTEXT\*, const void\*)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbuffer0.md) | 设置左输入缓冲区的地址。 |
| [SetShapeXmaInputBuffer0(SHAPE\_XMA\_CONTEXT\*, APU\_ADDRESS)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbuffer0_2.md) | 设置左输入缓冲区的地址。 |
| [SetShapeXmaInputBuffer0Size](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbuffer0size.md) | 设置左输入缓冲区的大小。 |
| [SetShapeXmaInputBuffer0Valid](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbuffer0valid.md) | 设置左输入缓冲区的有效性标志。 |
| [SetShapeXmaInputBuffer1(SHAPE\_XMA\_CONTEXT\*, const void\*)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbuffer1.md) | 设置右输入缓冲区的地址。 |
| [SetShapeXmaInputBuffer1(SHAPE\_XMA\_CONTEXT\*, APU\_ADDRESS)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbuffer1_2.md) | 设置右输入缓冲区的地址。 |
| [SetShapeXmaInputBuffer1Size](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbuffer1size.md) | 设置右输入缓冲区的大小。 |
| [SetShapeXmaInputBuffer1Valid](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbuffer1valid.md) | 设置右输入缓冲区的有效性标志。 |
| [SetShapeXmaInputBufferReadOffset](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbufferreadoffset.md) | 设置当前输入缓冲区的读取偏移量。 |
| [SetShapeXmaInputBufferValid](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbuffervalid.md) | 设置输入缓冲区的有效性标志。 |
| [SetShapeXmaInterruptWhenDone](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainterruptwhendone.md) | 保留供内部使用。 |
| [SetShapeXmaLoopEndOffset](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaloopendoffset.md) | 设置 XMA 上下文循环的结束偏移量。 |
| [SetShapeXmaLoopStartOffset](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaloopstartoffset.md) | 设置 XMA 上下文循环的起始偏移量。 |
| [SetShapeXmaLoopSubframeEnd](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaloopsubframeend.md) | 指定循环的最后一个子帧。 |
| [SetShapeXmaLoopSubframeSkip](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaloopsubframeskip.md) | 设置在循环开始处要跳过的子帧数量。 |
| [SetShapeXmaNumChannels](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmanumchannels.md) | 设置通道数。 |
| [SetShapeXmaNumLoops](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmanumloops.md) | 设置 XMA 上下文循环的数量。 |
| [SetShapeXmaNumSubframesToDecode](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmanumsubframestodecode.md) | 设置每次运行要解码的子帧数量。 |
| [SetShapeXmaNumSubframesToSkip](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmanumsubframestoskip.md) | 设置要跳过的子帧数量。 |
| [SetShapeXmaOutputBuffer(SHAPE\_XMA\_CONTEXT\*, void\*)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaoutputbuffer.md) | 设置输出缓冲区的地址。 |
| [SetShapeXmaOutputBuffer(SHAPE\_XMA\_CONTEXT\*, APU\_ADDRESS)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaoutputbuffer_2.md) | 设置输出缓冲区的地址。 |
| [SetShapeXmaOutputBufferReadOffset](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaoutputbufferreadoffset.md) | 设置输出缓冲区的读取偏移量。 |
| [SetShapeXmaOutputBufferSize](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaoutputbuffersize.md) | 设置输出缓冲区的大小。 |
| [SetShapeXmaOutputBufferValid](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaoutputbuffervalid.md) | 设置输出缓冲区的有效性标志。 |
| [SetShapeXmaOverlapAddBuffer(SHAPE\_XMA\_CONTEXT\*, void\*)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaoverlapaddbuffer.md) | 设置重叠相加缓冲区的地址。 |
| [SetShapeXmaOverlapAddBuffer(SHAPE\_XMA\_CONTEXT\*, APU\_ADDRESS)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaoverlapaddbuffer_2.md) | 设置重叠相加缓冲区的地址。 |
| [SetShapeXmaPacketMetadata](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmapacketmetadata.md) | 保留供内部使用。 |
| [SetShapeXmaSampleRate(SHAPE\_XMA\_CONTEXT\*, SHAPE\_XMA\_SAMPLE\_RATE)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmasamplerate.md) | 设置采样率。 |
| [SetShapeXmaSampleRate(SHAPE\_XMA\_CONTEXT\*, UINT32)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmasamplerate_2.md) | 设置采样率。 |
| [SetShapeXmaStopWhenDone](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmastopwhendone.md) | 保留供内部使用。 |

## Structures

| 结构 | 说明 |
| - | - |
| [SHAPE\_XMA\_CONTEXT](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/structs/shape_xma_context.md) | XBOX 媒体音频 (XMA) 上下文。 |

## Enumerations

| 枚举 | 说明 |
| - | - |
| [SHAPE\_XMA\_SAMPLE\_RATE](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/enums/shape_xma_sample_rate.md) | 有效的采样率。 |


## Related topics

- [SHAPE_XMA_CONTEXT](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/structs/shape_xma_context.md)
- [SetShapeXmaSampleRate(SHAPE_XMA_CONTEXT*, SHAPE_XMA_SAMPLE_RATE)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmasamplerate.md)
- [SetShapeXmaOutputBuffer(SHAPE_XMA_CONTEXT*, void*)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmaoutputbuffer.md)
- [SetShapeXmaInputBuffer0(SHAPE_XMA_CONTEXT*, const void*)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbuffer0.md)
- [SetShapeXmaInputBuffer1(SHAPE_XMA_CONTEXT*, const void*)](https://docs.xbox.com/zh-CN/reference/audio/shapexmacontext/functions/setshapexmainputbuffer1.md)
