diff options
| author | Yong He <yonghe@outlook.com> | 2021-07-08 13:55:21 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-07-08 13:55:21 -0700 |
| commit | aba2731f0427a04a119a59567e6715ba4034920a (patch) | |
| tree | b5b127f776db65c7154c31a41f1e91eaeb738503 /tools/gfx/d3d12/render-d3d12.cpp | |
| parent | 09950676b3f73bb9967aea183d27a30d63098475 (diff) | |
Allow render-test to run inline ray tracing tests. (#1903)
* Update VS projects to 2019.
* Empty commit to trigger build
* Implement gfx inline ray tracing on D3D12.
* Allow render-test to run inline ray tracing tests.
Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'tools/gfx/d3d12/render-d3d12.cpp')
| -rw-r--r-- | tools/gfx/d3d12/render-d3d12.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/tools/gfx/d3d12/render-d3d12.cpp b/tools/gfx/d3d12/render-d3d12.cpp index 277491ccd..e85fa84a3 100644 --- a/tools/gfx/d3d12/render-d3d12.cpp +++ b/tools/gfx/d3d12/render-d3d12.cpp @@ -4316,6 +4316,22 @@ Result D3D12Device::initialize(const Desc& desc) auto minPrecisionSupport = options.MinPrecisionSupport; } } + // Check ray tracing support + { + D3D12_FEATURE_DATA_D3D12_OPTIONS5 options; + if (SLANG_SUCCEEDED(m_device->CheckFeatureSupport( + D3D12_FEATURE_D3D12_OPTIONS5, &options, sizeof(options)))) + { + if (options.RaytracingTier != D3D12_RAYTRACING_TIER_NOT_SUPPORTED) + { + m_features.add("ray-tracing"); + } + if (options.RaytracingTier >= D3D12_RAYTRACING_TIER_1_1) + { + m_features.add("ray-query"); + } + } + } } m_desc = desc; |
