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

# CreateConstantBufferView

> 建立用於存取資源資料的常數緩衝區檢視。

建立用於存取資源資料的常數緩衝區檢視。

## 語法

```cpp theme={null}
void CreateConstantBufferView(
    const D3D12_CONSTANT_BUFFER_VIEW_DESC  pDesc,
    D3D12_CPU_DESCRIPTOR_HANDLE DestDescriptor
)
```

### 參數

*pDesc \[in, optional]*\
類型：const D3D12\_CONSTANT\_BUFFER\_VIEW\_DESC \*

指向描述常數緩衝區檢視之 [D3D12\_CONSTANT\_BUFFER\_VIEW\_DESC](/zh-TW/reference/graphics/d3d12/structs/d3d12_constant_buffer_view_desc_public) 結構的指標。

*DestDescriptor \[in]*\
類型：D3D12\_CPU\_DESCRIPTOR\_HANDLE

描述代表保存常數緩衝區檢視之堆積起點的 CPU 描述元控制代碼。

### 傳回值

類型：void

無。

## 需求

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

## 另請參閱

[ID3D12Device](/zh-TW/reference/graphics/d3d12_x/interfaces/id3d12device/id3d12device)


## Related topics

- [D3D12_CONSTANT_BUFFER_VIEW_DESC](/zh-TW/reference/graphics/d3d12/structs/d3d12_constant_buffer_view_desc_public.md)
- [D3D12_CPU_DESCRIPTOR_HANDLE](/zh-TW/reference/graphics/d3d12/structs/d3d12_cpu_descriptor_handle_public.md)
- [SetGraphicsRootConstantBufferView](/zh-TW/reference/graphics/d3d12/interfaces/id3d12graphicscommandlist/methods/id3d12graphicscommandlist_setgraphicsrootconstantbufferview_public.md)
- [SetComputeRootConstantBufferView](/zh-TW/reference/graphics/d3d12/interfaces/id3d12graphicscommandlist/methods/id3d12graphicscommandlist_setcomputerootconstantbufferview_public.md)
- [CreateRenderTargetView](/zh-TW/reference/graphics/d3d12/interfaces/id3d12device/methods/id3d12device_createrendertargetview_public.md)
