Skip to content

Commit

Permalink
Adds feature detection for DirectX 12.
Browse files Browse the repository at this point in the history
  • Loading branch information
Lichtso authored and exrook committed Oct 23, 2023
1 parent 64603cb commit 658fcac
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions wgpu-hal/src/dx12/adapter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,12 @@ impl super::Adapter {
bgra8unorm_storage_supported,
);

features.set(
wgt::Features::SUBGROUP_OPERATIONS,
shader_model_support.HighestShaderModel >= d3d12_ty::D3D_SHADER_MODEL_6_0
&& matches!(dx12_shader_compiler, &wgt::Dx12Compiler::Dxc { .. }),
);

// TODO: Determine if IPresentationManager is supported
let presentation_timer = auxil::dxgi::time::PresentationTimer::new_dxgi();

Expand Down

0 comments on commit 658fcac

Please sign in to comment.