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

# GetRequiredParameterResourceSize

> 检索元命令在指定阶段所需的指定运行时参数资源的内存量。

检索元命令在指定阶段所需的指定运行时参数资源的内存量。

## 语法

```cpp theme={null}
UINT64 GetRequiredParameterResourceSize(
    D3D12_META_COMMAND_PARAMETER_STAGE Stage,
    UINT ParameterIndex
)
```

### 参数

*Stage \[in]*\
类型：D3D12\_META\_COMMAND\_PARAMETER\_STAGE

一个 **D3D12\_META\_COMMAND\_PARAMETER\_STAGE**，指定参数所属的阶段。

*ParameterIndex \[in]*\
类型：UINT

阶段中参数的从零开始的索引。

### 返回值

类型：UINT64

指定运行时参数资源所需的字节数。

## 要求

**头文件：** d3d12\_xs.h 或 d3d12\_x.h\
**库：** d3d12\_xs.lib 或 d3d12\_x.lib\
**支持的平台**：XBOX Series 主机和 XBOX One 系列

## 另请参阅

[ID3D12MetaCommand](/reference/graphics/d3d12/interfaces/id3d12metacommand/id3d12metacommand_public)


## Related topics

- [D3D12_META_COMMAND_PARAMETER_DESC](/zh-CN/reference/graphics/d3d12/structs/d3d12_meta_command_parameter_desc_public.md)
- [XAsyncGetResult](/zh-CN/reference/system/xasyncprovider/functions/xasyncgetresult.md)
- [GetResourceAllocationInfo](/zh-CN/reference/graphics/d3d12/interfaces/id3d12device/methods/id3d12device_getresourceallocationinfo_public.md)
- [XAsyncGetResultSize](/zh-CN/reference/system/xasync/functions/xasyncgetresultsize.md)
- [GetResourceAllocationInfo1 (XBOX Series 主机)](/zh-CN/reference/graphics/d3d12/interfaces/id3d12device4/methods/id3d12device4_getresourceallocationinfo1_public.md)
