vault backup: 2025-10-08 16:49:03
This commit is contained in:
@@ -44,4 +44,23 @@ typedef struct DXGI_SAMPLE_DESC
|
|||||||
- DXGI_MODE_SCALING:缩放方式。
|
- DXGI_MODE_SCALING:缩放方式。
|
||||||
|
|
||||||
# 功能支持检测
|
# 功能支持检测
|
||||||
使用
|
使用ID3D12Device::CheckFeatureSupport()检查功能支持情况。
|
||||||
|
- D3D12_FEATURE
|
||||||
|
- D3D12_FEATURE_D3D12_OPTIONS
|
||||||
|
- D3D12_FEATURE_ARCHITECHTURE
|
||||||
|
- D3D12_FEATURE_FEATURE_LEVELS
|
||||||
|
- D3D12_FEATURE_FORMAT_SUPPORT
|
||||||
|
- D3D12_FEATURE_MULTISAMPLE_QUALITY_LEVELS
|
||||||
|
|
||||||
|
# CPU与GPU间的交互
|
||||||
|
## 命令队列
|
||||||
|
DX12的命令队列被抽象为ID3D12CommandQueue。使用ID3D12Device::CreateCommandQueue()来创建。
|
||||||
|
```c++
|
||||||
|
Microsoft::WRL::ComPtr<ID3D12Debug> mCommandQueue;
|
||||||
|
D3D12_COMMAND_QUEUE_DESC queueDesc={};
|
||||||
|
queueDesc.Type = D3D12_COMMAND_LIST_TYPE_DIRECT;
|
||||||
|
queueDesc.Flags = D3D12_COMMAND_QUEUE_FLAG_NONE;
|
||||||
|
ThrowIfFailed(md3Device->CreateCommandQueue(&queueDesc,IID_PPV_ARGS(&mCommandQueue)));
|
||||||
|
```
|
||||||
|
|
||||||
|
IID_PPV_ARGS
|
Reference in New Issue
Block a user