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

# EnumerateMetaCommands (XBOX Series 主机)

> 查询有关可用元命令的反射元数据。

查询有关可用元命令的反射元数据。

## 语法

```cpp theme={null}
HRESULT EnumerateMetaCommands(
    UINT  pNumMetaCommands,
    D3D12_META_COMMAND_DESC  pDescs
)
```

### 参数

*pNumMetaCommands*\
类型：UINT \*

指向 [UINT](https://learn.microsoft.com/en-us/windows/desktop/WinProg/windows-data-types) 的指针，其中包含要查询的元命令数量。此字段决定 <i>pDescs</i> 数组的大小，除非 <i>pDescs</i> 为 **nullptr**。

*pDescs*\
类型：D3D12\_META\_COMMAND\_DESC \*

一个可选指针，指向 [D3D12\_META\_COMMAND\_DESC](/reference/graphics/d3d12/structs/d3d12_meta_command_desc_public) 数组，其中包含可用元命令的描述。传递 `nullptr` 可在 <i>pNumMetaCommands</i> 中返回可用元命令的数量。

### 返回值

类型：HRESULT

如果此方法成功，则返回 **S\_OK**。否则，返回 [HRESULT](https://learn.microsoft.com/en-us/windows/win32/com/structure-of-com-error-codes) 错误代码。

## 要求

**头文件：** d3d12\_xs.h\
**库：** d3d12\_xs.lib\
**支持的平台**：XBOX Series 主机

## 另请参阅

[ID3D12Device5](/reference/graphics/d3d12/interfaces/id3d12device5/id3d12device5_public)


## Related topics

- [EnumerateMetaCommandParameters (XBOX Series 主机)](/zh-CN/reference/graphics/d3d12/interfaces/id3d12device5/methods/id3d12device5_enumeratemetacommandparameters_public.md)
- [InitializeMetaCommand (XBOX Series 主机)](/zh-CN/reference/graphics/d3d12/interfaces/id3d12graphicscommandlist4/methods/id3d12graphicscommandlist4_initializemetacommand_public.md)
- [CreateMetaCommand (XBOX Series 主机)](/zh-CN/reference/graphics/d3d12/interfaces/id3d12device5/methods/id3d12device5_createmetacommand_public.md)
- [CreateCommandQueue1 (XBOX Series 主机)](/zh-CN/reference/graphics/d3d12/interfaces/id3d12device9/methods/id3d12device9_createcommandqueue1_public.md)
- [CreateCommandList1 (XBOX Series 主机)](/zh-CN/reference/graphics/d3d12/interfaces/id3d12device4/methods/id3d12device4_createcommandlist1_public.md)
