mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-06-10 00:23:43 +00:00
Only default ANGLE to swiftshader if envvar empty.
Only set SwiftShader as the default ANGLE backend if the ANGLE_DEFAULT_PLATFORM environment var is empty. This will allow devs to set it. Bug: dawn:447 Change-Id: I49aac4bcb4b0b7c56903eca68248ee22cdf1e6f2 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/41140 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Austin Eng <enga@chromium.org> Commit-Queue: Stephen White <senorblanco@chromium.org>
This commit is contained in:
parent
58a471ae25
commit
e7e42ebbed
@ -381,7 +381,9 @@ std::unique_ptr<dawn_native::Instance> DawnTestEnvironment::CreateInstanceAndDis
|
|||||||
adapterOptions.getProc = reinterpret_cast<void* (*)(const char*)>(glfwGetProcAddress);
|
adapterOptions.getProc = reinterpret_cast<void* (*)(const char*)>(glfwGetProcAddress);
|
||||||
instance->DiscoverAdapters(&adapterOptions);
|
instance->DiscoverAdapters(&adapterOptions);
|
||||||
|
|
||||||
SetEnvironmentVar("ANGLE_DEFAULT_PLATFORM", "swiftshader");
|
if (GetEnvironmentVar("ANGLE_DEFAULT_PLATFORM").empty()) {
|
||||||
|
SetEnvironmentVar("ANGLE_DEFAULT_PLATFORM", "swiftshader");
|
||||||
|
}
|
||||||
|
|
||||||
glfwDefaultWindowHints();
|
glfwDefaultWindowHints();
|
||||||
glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3);
|
glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user