Commit c5146c76 by Jamie Madill

Add more D3D11 init errors to stats collection.

We ran into the UNSUPPORTED value when looking at D3D11 on a VM. It's quite possible that systems which don't support D3D11 return this value when initialization fails. Also add a few more severe errors such as device removed. BUG=477701 Change-Id: I2ebbfff5f7eed6fe3939dea86b25845a748caedc Reviewed-on: https://chromium-review.googlesource.com/270346Reviewed-by: 's avatarGeoff Lang <geofflang@chromium.org> Tested-by: 's avatarJamie Madill <jmadill@chromium.org>
parent 6cd03cf9
......@@ -375,6 +375,14 @@ egl::Error Renderer11::initialize()
return GenerateD3D11CreateDeviceErr(D3D11_INIT_CREATEDEVICE_NOTAVAILABLE);
case DXGI_ERROR_DEVICE_HUNG:
return GenerateD3D11CreateDeviceErr(D3D11_INIT_CREATEDEVICE_DEVICEHUNG);
case DXGI_ERROR_UNSUPPORTED:
return GenerateD3D11CreateDeviceErr(D3D11_INIT_CREATEDEVICE_UNSUPPORTED);
case DXGI_ERROR_DEVICE_RESET:
return GenerateD3D11CreateDeviceErr(D3D11_INIT_CREATEDEVICE_RESET);
case DXGI_ERROR_DEVICE_REMOVED:
return GenerateD3D11CreateDeviceErr(D3D11_INIT_CREATEDEVICE_REMOVED);
case DXGI_ERROR_DRIVER_INTERNAL_ERROR:
return GenerateD3D11CreateDeviceErr(D3D11_INIT_CREATEDEVICE_INTERNALERROR);
default:
return GenerateD3D11CreateDeviceErr(D3D11_INIT_CREATEDEVICE_ERROR);
}
......
......@@ -80,6 +80,14 @@ enum D3D11InitError
D3D11_INIT_CREATEDEVICE_DEVICEHUNG,
// CreateDevice returned NULL
D3D11_INIT_CREATEDEVICE_NULL,
// CreateDevice returned DXGI_ERROR_UNSUPPORTED
D3D11_INIT_CREATEDEVICE_UNSUPPORTED,
// CreateDevice returned DXGI_ERROR_DEVICE_RESET
D3D11_INIT_CREATEDEVICE_RESET,
// CreateDevice returned DXGI_ERROR_DEVICE_REMOVED
D3D11_INIT_CREATEDEVICE_REMOVED,
// CreateDevice returned DXGI_ERROR_DRIVER_INTERNAL_ERROR
D3D11_INIT_CREATEDEVICE_INTERNALERROR,
NUM_D3D11_INIT_ERRORS
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment