-
-
Notifications
You must be signed in to change notification settings - Fork 67
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cherry-pick from gles3-dev: Add and implement ANGLE_device_mtl extens…
…ion. Allow user to query internal MTLDevice used by MetalANGLE. Change-Id: If310917c091b80ad605084403b94ffee5e803553 # Conflicts: # include/EGL/eglext_angle.h # src/libANGLE/Caps.h # src/libANGLE/renderer/metal/DisplayMtl.mm # src/libGLESv2/entry_points_egl_ext.cpp
- Loading branch information
1 parent
a457b90
commit f2ae5d3
Showing
6 changed files
with
142 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,90 @@ | ||
Name | ||
|
||
ANGLE_device_mtl | ||
|
||
Name Strings | ||
|
||
EGL_ANGLE_device_mtl | ||
|
||
Contributors | ||
|
||
Le Hoang Quyen | ||
|
||
Contact | ||
|
||
Le Hoang Quyen (lehoangq 'at' gmail.com) | ||
|
||
Status | ||
|
||
Draft | ||
|
||
Version | ||
|
||
Version 1, Jul 19, 2020 | ||
|
||
Number | ||
|
||
EGL Extension #XXX | ||
|
||
Extension Type | ||
|
||
EGL device extension | ||
|
||
Dependencies | ||
|
||
This extension is written against the language of EGL 1.5 as | ||
modified by EGL_EXT_device_query. | ||
|
||
EGL_EXT_device_query is required. | ||
|
||
Overview | ||
|
||
ANGLE has the ability to run GPU commands on a metal device. | ||
This extension defines a mapping from an EGL device to a metal | ||
device, after it's queried from an EGL display. | ||
|
||
IP Status | ||
|
||
No known claims. | ||
|
||
New Types | ||
|
||
None. | ||
|
||
New Procedures and Functions | ||
|
||
None. | ||
|
||
New Tokens | ||
|
||
Accepted as a queried <attribute> in eglQueryDeviceAttribEXT: | ||
|
||
EGL_MTL_DEVICE_ANGLE 0x33A2 | ||
|
||
Add a new section 2.1.3 (Metal Devices) after 2.1.2 (Devices) | ||
|
||
Somewhat analogous to an EGL device, a Metal device establishes a | ||
namespace for Metal operations. In the Metal APIs, such devices are | ||
represented by pointers. For more details, see the Metal | ||
documentation. | ||
|
||
Changes to section 3.2 (Devices) | ||
|
||
Replace the paragraph immediately following the prototype for | ||
eglQueryDeviceAttribEXT: | ||
|
||
<attribute> may be EGL_MTL_DEVICE_ANGLE. | ||
On success, EGL_TRUE is returned, and a valid MTLDevice pointer | ||
corresponding to the EGL device is returned in <value>. This handle | ||
is compatible with Metal API functions. If the EGL device is not currently | ||
associated with a Metal device and <attribute> is EGL_MTL_DEVICE_ANGLE, | ||
EGL_BAD_ATTRIBUTE is returned, and <value> is left unchanged. | ||
|
||
Issues | ||
|
||
None | ||
|
||
Revision History | ||
|
||
Version 1, Jul 19, 2020 (Le Hoang Quyen) | ||
- Initial Draft |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters