neovide/neovide · error

Failed to find any suitable Direct3D 12 adapters

Error message

Failed to find any suitable Direct3D 12 adapters

What it means

After creating the DXGI factory, D3DSkiaRenderer::new calls get_hardware_adapter(&dxgi_factory) and unwraps it with expect('Failed to find any suitable Direct3D 12 adapters'). get_hardware_adapter walks EnumAdapters1 looking for a hardware adapter that supports D3D12; returning None means no GPU on the system exposes the required feature level. This fires on machines with only software/warp-capable or very old GPUs, headless/remote-desktop sessions without GPU enumeration, or disabled display drivers. Renderer construction cannot proceed, so the expect panics and the application exits during startup.

Source

Thrown at src/renderer/d3d.rs:133

    pub fn new(window: Rc<Window>, settings: Arc<Settings>) -> Self {
        tracy_zone!("D3DSkiaRenderer::new");
        #[cfg(feature = "d3d_debug")]
        let dxgi_factory: IDXGIFactory2 = unsafe {
            let mut debug_controller: Option<ID3D12Debug> = None;
            D3D12GetDebugInterface(&mut debug_controller)
                .expect("Failed to create Direct3D debug controller");

            debug_controller.expect("Failed to enable debug layer").EnableDebugLayer();

            CreateDXGIFactory2(DXGI_CREATE_FACTORY_DEBUG).expect("Failed to create DXGI factory")
        };

        #[cfg(not(feature = "d3d_debug"))]
        let dxgi_factory: IDXGIFactory2 =
            unsafe { CreateDXGIFactory1().expect("Failed to create DXGI factory") };

        let adapter = get_hardware_adapter(&dxgi_factory)
            .expect("Failed to find any suitable Direct3D 12 adapters");

        let mut device: Option<ID3D12Device> = None;
        unsafe {
            tracy_zone!("create_device");
            D3D12CreateDevice(&adapter, D3D_FEATURE_LEVEL_11_0, &mut device)
                .expect("Failed to create a Direct3D 12 device");
        }
        let device = device.expect("Failed to create a Direct3D 12 device");

        // Describe and create the command queue.
        let queue_desc = D3D12_COMMAND_QUEUE_DESC {
            Flags: D3D12_COMMAND_QUEUE_FLAG_NONE,
            Type: D3D12_COMMAND_LIST_TYPE_DIRECT,
            ..Default::default()
        };
        let command_queue: ID3D12CommandQueue = unsafe {
            device
                .CreateCommandQueue(&queue_desc)

View on GitHub (pinned to ade2d9cda7)

Solutions

  1. Fall back to the WARP software adapter (IDXGIFactory4::EnumWarpAdapter) when no hardware D3D12 adapter is found, instead of panicking
  2. Report the failure through the application's error-window path so the user gets an actionable message about GPU/D3D12 support
  3. Relax the adapter selection criteria (lower feature-level requirement) if the current check is too strict for older GPUs
Defensive patterns

Strategy: fallback

When it happens

Trigger: Thrown at src/renderer/d3d.rs:133 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of neovide/neovide@ade2d9cda7 (2026-09-06). Data as JSON: /api/errors/cf815ef24c3e5361. Report an issue: GitHub.