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

> 描述著色器資料。(D3D12_SHADER_BYTECODE)

描述著色器資料。

## 語法

```cpp theme={null}
typedef struct D3D12_SHADER_BYTECODE
{
    const void  pShaderBytecode;
    SIZE_T BytecodeLength;
} D3D12_SHADER_BYTECODE
```

### 成員

*pShaderBytecode*\
類型：const void \*

指向包含著色器資料之記憶體區塊的指標。

*BytecodeLength*\
類型：SIZE\_T

**pShaderBytecode** 成員所指向之著色器資料的大小 (以位元組為單位)。

## 備註

[D3D12\_GRAPHICS\_PIPELINE\_STATE\_DESC](/zh-TW/reference/graphics/d3d12_x/structs/d3d12_graphics_pipeline_state_desc) 和 [D3D12\_COMPUTE\_PIPELINE\_STATE\_DESC](/zh-TW/reference/graphics/d3d12/structs/d3d12_compute_pipeline_state_desc_public) 物件包含描述各種著色器類型的 **D3D12\_SHADER\_BYTECODE** 結構。

從 FXC/DXC 載入著色器時，這可能是從磁碟載入的整個已編譯 Blob。

## 需求

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

## 另請參閱

[CD3DX12\_SHADER\_BYTECODE](https://learn.microsoft.com/en-us/windows/desktop/direct3d12/cd3dx12-shader-bytecode)

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


## Related topics

- [D3D12_COMPUTE_PIPELINE_STATE_DESC](/zh-TW/reference/graphics/d3d12/structs/d3d12_compute_pipeline_state_desc_public.md)
- [D3D12_DXIL_LIBRARY_DESC (XBOX Series 主機)](/zh-TW/reference/graphics/d3d12/structs/d3d12_dxil_library_desc_public.md)
- [D3D12_SHADER_VISIBILITY](/zh-TW/reference/graphics/d3d12/enums/d3d12_shader_visibility_public.md)
- [D3D12_SHADER_COMPONENT_MAPPING](/zh-TW/reference/graphics/d3d12/enums/d3d12_shader_component_mapping_public.md)
- [D3D12_SHADER_CACHE_FLAGS](/zh-TW/reference/graphics/d3d12/enums/d3d12_shader_cache_flags_public.md)
