EGL: Add support for EGL_ANGLE_platform_angle

This adds basic support for selecting the platform type (rendering
backend) when running on ANGLE.

Related to #1380.
This commit is contained in:
Camilla Löwy
2020-06-25 18:22:08 +02:00
parent e6a6a99813
commit 0dea8a4441
13 changed files with 224 additions and 16 deletions
+4
View File
@@ -53,6 +53,7 @@ static GLFWerrorfun _glfwErrorCallback;
static _GLFWinitconfig _glfwInitHints =
{
GLFW_TRUE, // hat buttons
GLFW_ANGLE_PLATFORM_TYPE_NONE, // ANGLE backend
{
GLFW_TRUE, // macOS menu bar
GLFW_TRUE // macOS bundle chdir
@@ -287,6 +288,9 @@ GLFWAPI void glfwInitHint(int hint, int value)
case GLFW_JOYSTICK_HAT_BUTTONS:
_glfwInitHints.hatButtons = value;
return;
case GLFW_ANGLE_PLATFORM_TYPE:
_glfwInitHints.angleType = value;
return;
case GLFW_COCOA_CHDIR_RESOURCES:
_glfwInitHints.ns.chdir = value;
return;