Add Adapter::GetDeviceType() (integrate vs. discrete vs. CPU)

BUG=chromium:852089
Change-Id: Ia447448392e09c5d604ae038b4758776ed3e66ee
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/5180
Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
This commit is contained in:
Corentin Wallez
2019-04-15 16:36:25 +00:00
committed by Commit Bot service account
parent bff933affc
commit 2ec74dcc3f
9 changed files with 65 additions and 1 deletions

View File

@@ -37,6 +37,13 @@ namespace dawn_native {
Vulkan,
};
enum class DeviceType {
DiscreteGPU,
IntegratedGPU,
CPU,
Unknown,
};
class InstanceBase;
class AdapterBase;
@@ -53,6 +60,7 @@ namespace dawn_native {
~Adapter();
BackendType GetBackendType() const;
DeviceType GetDeviceType() const;
const PCIInfo& GetPCIInfo() const;
explicit operator bool() const;