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

View File

@@ -1104,6 +1104,14 @@ extern "C" {
#define GLFW_EGL_CONTEXT_API 0x00036002
#define GLFW_OSMESA_CONTEXT_API 0x00036003
#define GLFW_ANGLE_PLATFORM_TYPE_NONE 0x00037001
#define GLFW_ANGLE_PLATFORM_TYPE_OPENGL 0x00037002
#define GLFW_ANGLE_PLATFORM_TYPE_OPENGLES 0x00037003
#define GLFW_ANGLE_PLATFORM_TYPE_D3D9 0x00037004
#define GLFW_ANGLE_PLATFORM_TYPE_D3D11 0x00037005
#define GLFW_ANGLE_PLATFORM_TYPE_VULKAN 0x00037007
#define GLFW_ANGLE_PLATFORM_TYPE_METAL 0x00037008
/*! @defgroup shapes Standard cursor shapes
* @brief Standard system cursor shapes.
*
@@ -1220,6 +1228,11 @@ extern "C" {
* Joystick hat buttons [init hint](@ref GLFW_JOYSTICK_HAT_BUTTONS).
*/
#define GLFW_JOYSTICK_HAT_BUTTONS 0x00050001
/*! @brief ANGLE rendering backend init hint.
*
* ANGLE rendering backend [init hint](@ref GLFW_ANGLE_PLATFORM_TYPE_hint).
*/
#define GLFW_ANGLE_PLATFORM_TYPE 0x00050002
/*! @brief macOS specific init hint.
*
* macOS specific [init hint](@ref GLFW_COCOA_CHDIR_RESOURCES_hint).