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

# D3D12_ROOT_PARAMETER

> 描述根簽章 1.0 版的插槽。

描述根簽章 1.0 版的插槽。

## 語法

```cpp theme={null}
typedef struct D3D12_ROOT_PARAMETER
{
    D3D12_ROOT_PARAMETER_TYPE ParameterType;
    D3D12_ROOT_DESCRIPTOR_TABLE DescriptorTable;
    D3D12_ROOT_CONSTANTS Constants;
    D3D12_ROOT_DESCRIPTOR Descriptor;
    D3D12_SHADER_VISIBILITY ShaderVisibility;
} D3D12_ROOT_PARAMETER
```

### 成員

*ParameterType*\
類型：D3D12\_ROOT\_PARAMETER\_TYPE

[D3D12\_ROOT\_PARAMETER\_TYPE](/zh-TW/reference/graphics/d3d12/enums/d3d12_root_parameter_type_public) 類型的值，指定根簽章插槽的類型。此成員會決定要使用下方聯集中的哪一種類型。

*DescriptorTable*\
類型：D3D12\_ROOT\_DESCRIPTOR\_TABLE

[D3D12\_ROOT\_DESCRIPTOR\_TABLE](/zh-TW/reference/graphics/d3d12/structs/d3d12_root_descriptor_table_public) 結構，將描述元表格的配置描述為在描述元堆積中依序出現的描述元範圍集合。

*Constants*\
類型：D3D12\_ROOT\_CONSTANTS

[D3D12\_ROOT\_CONSTANTS](/zh-TW/reference/graphics/d3d12/structs/d3d12_root_constants_public) 結構，描述根簽章中內嵌的常數，這些常數在著色器中會顯示為一個常數緩衝區。

*Descriptor*\
類型：D3D12\_ROOT\_DESCRIPTOR

[D3D12\_ROOT\_DESCRIPTOR](/zh-TW/reference/graphics/d3d12/structs/d3d12_root_descriptor_public) 結構，描述根簽章中內嵌、會在著色器中顯示的描述元。

*ShaderVisibility*\
類型：D3D12\_SHADER\_VISIBILITY

[D3D12\_SHADER\_VISIBILITY](/zh-TW/reference/graphics/d3d12/enums/d3d12_shader_visibility_public) 類型的值，指定可存取根簽章插槽內容的著色器。

## 備註

[D3D12\_ROOT\_SIGNATURE\_DESC](/zh-TW/reference/graphics/d3d12/structs/d3d12_root_signature_desc_public) 可以包含描述元表格和內嵌常數。功能更強的硬體也可以支援根簽章中的內嵌描述元。根簽章中的繫結插槽數目若保持在特定大小以下效率最高，而且也可能有上限。

## 需求

**標頭:** d3d12\_xs.h 或 d3d12\_x.h\
**程式庫:** d3d12\_xs.lib 或 d3d12\_x.lib\
**支援的平台**: XBOX Series 主機與 XBOX One 系列

## 另請參閱

[CD3DX12\_ROOT\_PARAMETER](https://learn.microsoft.com/en-us/windows/desktop/direct3d12/cd3dx12-root-parameter)

[核心結構](https://learn.microsoft.com/en-us/windows/desktop/direct3d12/direct3d-12-structures)

[建立根簽章](https://learn.microsoft.com/en-us/windows/desktop/direct3d12/creating-a-root-signature)

[D3D12\_ROOT\_PARAMETER1](/zh-TW/reference/graphics/d3d12/structs/d3d12_root_parameter1_public)


## Related topics

- [D3D12_ROOT_PARAMETER_TYPE](/zh-TW/reference/graphics/d3d12/enums/d3d12_root_parameter_type_public.md)
- [D3D12_ROOT_DESCRIPTOR](/zh-TW/reference/graphics/d3d12/structs/d3d12_root_descriptor_public.md)
- [D3D12_ROOT_PARAMETER1](/zh-TW/reference/graphics/d3d12/structs/d3d12_root_parameter1_public.md)
- [D3D12_ROOT_CONSTANTS](/zh-TW/reference/graphics/d3d12/structs/d3d12_root_constants_public.md)
- [D3D12_ROOT_DESCRIPTOR_TABLE](/zh-TW/reference/graphics/d3d12/structs/d3d12_root_descriptor_table_public.md)
