src/libANGLE/validationEGL.cpp


Log

Author Commit Date CI Message
Jamie Madill 8403e4c5 2022-10-10T20:59:29 EGL: Resource IDs for Surface, Context and EGL Image. This will make these classes play nicely with resource maps. As these objects are used in a lot of places, and simplified C can't handle unordered_map, it's necessary to index the maps by simple packed IDs in capture/replay code. This indirection will also have increased safety as we validate EGL resource ID handle values before accessing the memory directly. Also hides some of the other EGL capture methods behind helper methods to simplify the C code and hide assignments and other complex maps. Bug: angleproject:7758 Change-Id: Ibc7bb56430d3068bd38877c9dfb011979d4ea234 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3957164 Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Dan Glastonbury d2a58f00 2022-09-08T14:19:21 EGL: Implement eglCopyMetalSharedEventANGLE Add eglCopyMetalSharedEventANGLE function to the ANGLE_metal_shared_event_sync extension. This brings the extension on par with the EGL_ANDROID_native_fence_sync extension. eglCopyMetalSharedEventANGLE allows for copying the Metal event object from EGLSync objects implemented by the ANGLE Metal renderer. This function follows Objective-C convention for "copy" methods and increases the retain count of the Metal event object. The EGL API user is thus responsible for ensuring to release the returned object to avoid memory leaks. Test: angle_end2end_tests --gtest_filter=EGLSyncTestMetalSharedEvent.* Bug: angleproject:7561 Change-Id: I8c35b559014b85cb8c6a0e76ac2ab7891eed5da0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3881423 Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Kenneth Russell <kbr@chromium.org> Reviewed-by: Quyen Le <lehoangquyen@chromium.org>
Dan Glastonbury a89f678f 2022-06-16T13:59:16 EGL: Implement ANGLE_metal_shared_event_sync on metal Implement creation of fence sync object taking an external MTLSharedEvent and optional value to use when signaling completion of prior commands. Extended end2end test suite with metal shared event test cases. Test: angle_end2end_tests --gtest_filter=EGLSyncTestMetalSharedEvent.* Bug: angleproject:7561 Change-Id: I0e72b5417275a20a24e535670ceb995ecc87abcb Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3865060 Reviewed-by: Quyen Le <lehoangquyen@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Kenneth Russell <kbr@chromium.org>
Eddie Hatfield 3960e63b 2022-08-09T14:02:59 Infra: Enable angle_deqp_gl46_tests on SwiftShader This change disables the WGL frontend by default on Windows when building ANGLE for desktop GL. This is because the WGL frontend is not yet fully implemented and it causes some of the trace tests to fail. The WGL frontend should be enabled by default on windows when more of its functionality gets implemented. Test: angle_deqp_gl46_tests --use-angle=swiftshader Bug: angleproject:7566 Bug: angleproject:7628 Change-Id: I69c695eb56d3858f715eeb86d28cc805e25c60eb Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3858142 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Cody Northrop <cnorthrop@google.com>
Mohan Maiya 2d48a370 2022-08-26T11:11:19 Vulkan: Support passthrough of colorspace attributes On Android, the EGL loader supports and implements the necessary functionality for the following colorspace extensions - 1. EGL_EXT_gl_colorspace_display_p3 2. EGL_EXT_gl_colorspace_display_p3_linear 3. EGL_EXT_gl_colorspace_display_p3_passthrough 4. EGL_EXT_gl_colorspace_scrgb 5. EGL_EXT_gl_colorspace_scrgb_linear Add support for "EGL_ANGLE_colorspace_attribute_passthrough" extension that allows vendors that support wide color gamut to passthrough colorspace attribute values to the underlying Vulkan implementation to be used during VkImage creation. Bug: angleproject:7319 Test: PbufferColorspaceTest.CreateSurfaceWithColorspace* Change-Id: Ibd78bb5fea4ede394f4dc5027c1d4a730746f2ee Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3855048 Commit-Queue: mohan maiya <m.maiya@samsung.com> Reviewed-by: Ian Elliott <ianelliott@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya aa2a558e 2022-08-23T09:47:02 Vulkan: Add support for setting timestamp surface attribute On Android the EGL wrapper handles most of the functionality required by EGL_ANDROID_get_frame_timestamps. However if for some reason the swapchain is recreated, the timestamp state would be lost resulting in stuttering. Introduce EGL_ANGLE_timestamp_surface_attribute extension that adds support for toggling the EGL_TIMESTAMPS_ANDROID attribute of a surface. Cache this state and recreate the swapchain accordingly. Bug: angleproject:7489 Test: EGLSurfaceTest.TimestampSurfaceAttribute* Test: dEQP-EGL.functional.get_frame_timestamps* Change-Id: I3660f7137c006d904164d243a682a4ff520eabd8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3753396 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Ian Elliott <ianelliott@google.com> Commit-Queue: mohan maiya <m.maiya@samsung.com>
Eddie Hatfield c54ed790 2022-07-21T10:38:47 Get desktop GL conformance tests to build The target for these tests is angle_deqp_gl_tests. Bug: angleproject:7533 Change-Id: I290822671d99da020f9a6a1f02bee43987644bf9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3766435 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Eddie Hatfield <eddiehatfield@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Antonio Caggiano 44d8bf76 2022-03-16T14:38:37 Vulkan: Support EGL_EXT_platform_wayland Improve GetPlatformDisplay by supporting EGL_PLATFORM_WAYLAND_EXT. Bug: angleproject:6902 Change-Id: Ia4c342097f47b7c41778ac02517451f51a94d8be Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3528758 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Geoff Lang 785353fd 2022-05-24T12:40:16 Support Desktop OpenGL context creation in end2end tests Validation of Desktop GL versions and profile masks is unimplemented. Bug: angleproject:7360 Change-Id: Ifae94215b6aada895c2b02318a1d05c9515e9b96 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3664916 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com>
Patrick To 45def3d4 2022-06-15T13:49:08 Remove non-negative offsets restriction in D3D extension The EGL_ANGLE_d3d_texture_client_buffer extension currently fails if either EGL_TEXTURE_OFFSET_[X|Y]_ANGLE offsets are negative. This restriction is unnecessary, as D3D allows for negative offsets. Bug: angleproject:7446 Change-Id: I2e258a3a558eae51794f6533e28a0c06532f156d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3715956 Commit-Queue: Rafael Cintron <rafael.cintron@microsoft.com> Reviewed-by: Rafael Cintron <rafael.cintron@microsoft.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Mohan Maiya d50b2276 2022-06-21T12:05:28 Reland "Vulkan: Support EGL_ANDROID_front_buffer_auto_refresh" This is a reland of commit ef60d38ecf12d6663e9ecccacbff9803b1fba7c6 There are no fixes as the revert itself was a speculative one Original change's description: > Vulkan: Support EGL_ANDROID_front_buffer_auto_refresh > > Cache value of EGL_FRONT_BUFFER_AUTO_REFRESH_ANDROID attribute > and set swapchain present mode accordingly when recreating > swapchain in single buffer mode. > > Bug: angleproject:7224 > Tests: EGLAndroidAutoRefreshTest.Basic* > Change-Id: I2dbb92ce5c3fa047e0b02ea9011725311f346027 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3707570 > Reviewed-by: Ian Elliott <ianelliott@google.com> > Commit-Queue: mohan maiya <m.maiya@samsung.com> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> > Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org> Bug: angleproject:7224 Bug: angleproject:7465 Change-Id: Ia876ea17169c0f1b3afdb7753570e0b1aca985f5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3733521 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Yuly Novikov 46ddcc44 2022-06-27T14:53:31 Revert "Vulkan: Support EGL_ANDROID_front_buffer_auto_refresh" This reverts commit ef60d38ecf12d6663e9ecccacbff9803b1fba7c6. Reason for revert: crashes in end2end tests on Win Intel Vulkan Original change's description: > Vulkan: Support EGL_ANDROID_front_buffer_auto_refresh > > Cache value of EGL_FRONT_BUFFER_AUTO_REFRESH_ANDROID attribute > and set swapchain present mode accordingly when recreating > swapchain in single buffer mode. > > Bug: angleproject:7224 > Tests: EGLAndroidAutoRefreshTest.Basic* > Change-Id: I2dbb92ce5c3fa047e0b02ea9011725311f346027 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3707570 > Reviewed-by: Ian Elliott <ianelliott@google.com> > Commit-Queue: mohan maiya <m.maiya@samsung.com> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> > Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org> Bug: angleproject:7224, angleproject:7465 Change-Id: Ia48a31124c8e0a3e4bcd4b7dc6f62b0782b42d97 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3726099 Commit-Queue: Yuly Novikov <ynovikov@chromium.org> Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Mohan Maiya ef60d38e 2022-06-21T12:05:28 Vulkan: Support EGL_ANDROID_front_buffer_auto_refresh Cache value of EGL_FRONT_BUFFER_AUTO_REFRESH_ANDROID attribute and set swapchain present mode accordingly when recreating swapchain in single buffer mode. Bug: angleproject:7224 Tests: EGLAndroidAutoRefreshTest.Basic* Change-Id: I2dbb92ce5c3fa047e0b02ea9011725311f346027 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3707570 Reviewed-by: Ian Elliott <ianelliott@google.com> Commit-Queue: mohan maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
Geoff Lang bfab7e60 2022-06-01T11:22:42 Ignore eglBind/ReleaseTexImage calls for lost contexts. eglBindTexImage and eglReleaseTexImage no-op when no context is current. Extend this to lost contexts to match the behaviour of making a GL call on a lost context. This avoids potential unexpected bad accesses in the backends. Bug: chromium:1316578 Change-Id: I7b309c297e0c803019720733dee2950abb4c4b5f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3683869 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Alexis Hétu <sugoi@google.com> Reviewed-by: Alexis Hétu <sugoi@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Antonio Caggiano 2fb58a95 2022-02-15T15:40:23 Re-land: "Vulkan: GBM platform" Add support for GBM platform by implementing a Display with no WSI extension. Re-land fixes build script, including GBM Vulkan backend whenever ozone platform GBM is enabled. Bug: angleproject:7217 Change-Id: Icbf2d034b700e22ab4c351e479f472d65d832ebe Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3637562 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Yuly Novikov 0db4c39b 2022-05-09T20:02:58 Revert "Vulkan: GBM platform" This reverts commit 825d5b2c59b463253c82262a0c50f75d28860db4. Reason for revert: Fails link rolling into Chrome crrev.com/c/3635013 https://ci.chromium.org/ui/p/chromium/builders/try/chromeos-amd64-generic-rel/1149608/overview https://ci.chromium.org/ui/p/chromium/builders/try/linux-chromeos-compile-dbg/1013047/overview https://ci.chromium.org/ui/p/chromium/builders/try/linux-chromeos-rel/1189185/overview Original change's description: > Vulkan: GBM platform > > Add support for GBM platform by implementing a Display with no WSI > extension. > > Bug: angleproject:7217 > Change-Id: Ia9089131c5984dfdd926d2f85f1c218df1e84d9a > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3596042 > Commit-Queue: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Bug: angleproject:7217 Change-Id: Ia8a4ca753a8f18d6a2c607010b5afabf6a78fe9a No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3636059 Auto-Submit: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com> Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Antonio Caggiano 825d5b2c 2022-02-15T15:40:23 Vulkan: GBM platform Add support for GBM platform by implementing a Display with no WSI extension. Bug: angleproject:7217 Change-Id: Ia9089131c5984dfdd926d2f85f1c218df1e84d9a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3596042 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jeff Vigil 6c248691 2022-04-21T10:10:03 Enable SINGLE_BUFFER with eglCreateWindowSurface Enable core EGL feature for Vulkan using: VK_PRESENT_MODE_SHARED_DEMAND_REFRESH_KHR Test: angle_end2end_test --gtest_filter=EGLSingleBufferTest Bug: angleproject:7224 Change-Id: I3e85f932471f7b3c97bbc5c2f5314f25eb9b2867 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3610975 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jeff Vigil 95c1ff52 2022-02-24T08:31:52 EGL: Fix EGL_KHR_mutable_render_buffer Fixes for eglSurfaceAttrib error cases. Improve query for render buffer Add test case to EGLSurfaceTest Test: angle_end2end_test --gtest_filter=EGLSingleBufferTest Bug: angleproject:7134 Change-Id: I4fa568c9530312003dc17111be212bf5b66d97fb Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3556088 Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Antonio Caggiano 01811839 2022-03-17T15:08:38 Refactor platform code Use switch constructs instead of if-else to allow reuse of code and simplify addition of other platforms as new cases. Bug: angleproject:6902 Change-Id: Ia941d0d7bc03538bbc8d96ebece60224994a6c66 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3532260 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Antonio Caggiano <antonio.caggiano@collabora.com> Commit-Queue: Antonio Caggiano <antonio.caggiano@collabora.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Steven Noonan dd493b5c 2022-04-11T17:49:36 EGL: allow eglQueryString(EGL_NO_DISPLAY, EGL_VERSION) According to the EGL 1.5 specification, this should be okay: If dpy is EGL_NO_DISPLAY, then the EGL_VERSION string describes the supported client version. If dpy is a valid, initialized display, then the EGL_VERSION string describes the supported EGL version for dpy. Bug: angleproject:7194 Change-Id: I0d851742695293d553465175ce4b59ce7f5d5336 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3583143 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Steven Noonan <steven@valvesoftware.com> Auto-Submit: Steven Noonan <steven@valvesoftware.com> Commit-Queue: Kenneth Russell <kbr@chromium.org>
Kimmo Kinnunen 9637185c 2022-03-10T15:38:13 Add ForceGPUSwitch to EGL_ANGLE_power_preference eglHandleGPUSwitch() does not work with WebKit sandbox profile. The root cause is that we do not know the primary display, and as such we do not know which GPU drives this. Add eglForceGPUSwitchANGLE(display, gpuIDHigh, gpuIDLow). This lets the caller figure out the GPU in another process. Then the caller can just set the GPU in the sandboxed process. Add tests that are disabled by default until the runner and the infrastructure supports running the tests with automatic switching enabled. Bug: angleproject:7092 Change-Id: I316ee431156596effbdb89659a5e24291719a204 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3516274 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Kenneth Russell <kbr@chromium.org>
Constantine Shablya e74d0e81 2022-02-11T18:05:12 Vulkan: Implement EGL_KHR_partial_update This change provides a trivial implementation of partial update that does nothing, making apps that want this extension happy. A possible efficient Vulkan implementation would use the damage set to narrow down render area, but it appears to only be useful for only some TBDR hardware. Bug: angleproject:6960 Reviewed-by: Antonio Caggiano <antonio.caggiano@collabora.com> Change-Id: Ic553ac9590c336093f1bf25a6521574622599bf6 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3427640 Reviewed-by: Ian Elliott <ianelliott@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Auto-Submit: Constantine Shablya <constantine.shablya@collabora.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Brandon Schade 2d12b321 2022-03-03T10:42:03 Remove limit on exposeNonConformantExtensionsAndVersions to expose 3.2 Fix an issue where using the feature exposeNonConformantExtensionsAndVersions would still be limited to version 3.1. Remove this restraint when the feature is enabled. Continue to limit version to 3.1 if either it is a WebGL context or Geometry and Tessellation shader support is not present. Bug: angleproject:3647 Change-Id: I17f46756c22d95b39f2fd9ecb2db7ce4de903a2a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3502173 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: mohan maiya <m.maiya@samsung.com> Commit-Queue: Brandon Schade <b.schade@samsung.com>
Antonio Caggiano 47977b0e 2022-03-01T15:24:51 EGL: Validate and implement dmabuf extensions Add validation and default implementation of dmabuf extensions. Actual implementation should be defined by concrete Display subclasses. Bug: angleproject:7065 Change-Id: Ie8d7081f7bcb065c809a52a42abdb7af0e75c816 Signed-off-by: Antonio Caggiano <antonio.caggiano@collabora.com> Signed-off-by: Constantine Shablya <constantine.shablya@collabora.com> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3497840 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Antonio Caggiano b92ebdb7 2022-02-24T12:23:09 EGL: Add code-gen for dmabuf extensions Add code-gen for EGL_EXT_image_dma_buf_import and EGL_EXT_image_dma_buf_import_modifiers. Bug: angleproject:7065 Change-Id: Ib1bd2a881f11e96b1e7e5128975bdba3bdc41e0f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3495122 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Antonio Caggiano f762cb1b 2022-01-05T20:33:06 EGL: CreatePlatformWindowSurfaceEXT Implement CreatePlatformWindowSurfaceEXT just like CreatePlatformWindowSurface in egl_stubs.cpp taking into account that native window for X11 should be Window* instead of Window. Bug: angleproject:6961 Change-Id: Ic129bd3e9dd264fdee12b062b5b422a9a6012dd8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3427425 Reviewed-by: Jeff Vigil <jvigilsamsung@gmail.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Auto-Submit: Antonio Caggiano <antonio.caggiano@collabora.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Constantine Shablya 3f0a28ba 2022-02-11T16:18:37 Add entry points for EGL_KHR_partial_update Bug: angleproject:6960 Change-Id: If248b7ef5ebacd7dfb8c612e5a9106ba0060282e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3455787 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Peng Huang 706f8a31 2022-02-04T04:22:10 Support gl internal format for creating EGLImage from VkImage Bug: chromium:1290638 Change-Id: I5c9815b727497f63b9f04ecbd8c27deef4b929c8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3438666 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Peng Huang <penghuang@chromium.org>
Mohan Maiya 29e25468 2022-01-07T07:02:53 Account for EGL 1.5 version when dealing with robustness EGL 1.5 spec allows for EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY and EGL_CONTEXT_OPENGL_ROBUST_ACCESS enums to be passed in to eglCreateContext. Update the validation layer and queries to account for the new enums. Bug: angleproject:6883 Tests: KHR-NoContext.es32.context_flags.*flag* Tests: KHR-NoContext.es32.robustness.*reset* Change-Id: I7088e0dca08cea2cfdcf1877b6d999c0e0336e5e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3373133 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: mohan maiya <m.maiya@samsung.com>
Jonah Ryan-Davis 2f4f5f8a 2021-12-14T17:30:42 Add EGL_ANGLE_platform_angle_device_id for the Metal backend. This extension takes in a 64-bit device ID in two parts as parameters to eglGetPlatformDisplay and uses it to initialize a display backed by a specific device. The deviceID should match the MTLDevice's registryId. Bug: angleproject:6143 Change-Id: I02188b8266f8d0ac657b04325d191ab89bbef751 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3337985 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
Lingfeng Yang 926b43e7 2022-01-06T13:31:54 Reland: Frontend: separate lock in swap prep Swapchain-based backends like Vulkan might block a lot in vkAcquireNextImageKHR, which is bad for overall fast progress if we also hold the global EGL lock there. This CL starts to split the global EGL lock. We release the EGL lock when performing vkAcquireNextImageKHR, and only maintain a lock for surfaces. This is done via a new custom entry point, EGL_PrepareSwapBuffers, so that we can control how the global lock is used throughout the entire call. Bug: angleproject:6851 Change-Id: I095cd8b3bdbb13c842cab0a46148e2122582cdfd Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3373426 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Lingfeng Yang <lfy@google.com>
Peng Huang 32f572b7 2021-12-03T17:58:51 Support creating EGLImage from VkImage Bug: chromium:1264439 Change-Id: I520182143e748f25b44d0725f3f171b7b33a85d8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3311131 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Peng Huang <penghuang@chromium.org>
John Cunningham 42bd4fc2 2021-12-10T14:58:17 Metal: add ANGLE_metal_create_context_ownership_identity. This Metal-specific EGL extension allows a given context and the GPU resources it allocates to be associated with a particular task ID on the system, for system-level bookkeeping purposes. Bug: angleproject:6795 Change-Id: I19ee0993564169b01c4a450e63dcfacd339b98b5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3335172 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Kenneth Russell <kbr@chromium.org>
Jeff Vigil 1fc9b7c6 2021-12-08T14:10:36 EGL: Add queries for EGL_KHR_protected_content Add surface and context query for EGL_PROTECTED_CONTENT_EXT attribute. Bug: angleproject:6693 Change-Id: Iad3d8d7e0db89414c44a0101c26cda6e60308e71 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3324963 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Brandon Schade <b.schade@samsung.com>
Peng Huang e00ad443 2021-11-15T20:16:16 Add EGL_ANGLE_vulkan_image extension This extension is for exporting VkImage from EGLImage. The VkImage must be used with the same VkDevice used by ANGLE Vulkan backend. Bug: chromium:1264439 Change-Id: I222d900465cf2716d94fc64f06e240390ec518ac Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3285025 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Peng Huang <penghuang@chromium.org>
Shahbaz Youssefi 41a8981e 2021-11-21T21:52:37 Use AttributeMap in eglLockSurfaceKHR's validation Bug: angleproject:6062 Change-Id: I0eea431313700b11184265a9ff895417ce4b1d4d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3295164 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: (use @chromium please) Shahbaz Youssefi <syoussefi@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Peng Huang 3a84ef5e 2021-11-12T17:40:40 Add EGL_VULKAN_GET_INSTANCE_PROC_ADDR Add EGL_VULKAN_GET_INSTANCE_PROC_ADDR for query Vulkan vkGetInstanceProcAddr function pointer associate with the Vulkan EGLDevice. Bug: chromium:1264439 Change-Id: I4ff14e2aef7b8ca651e13b4d2867a540aed1b321 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3279100 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Peng Huang <penghuang@chromium.org>
Jamie Madill a4a52f78 2021-11-10T12:43:37 EGL: Validate CreatePbufferSurface attributes. This fixes an ASAN issue with a dEQP negative test: dEQP.EGL/functional_negative_api_create_pbuffer_surface Bug: angleproject:6660 Change-Id: I2d052f9f948b7a2a6fe3fbb1f1621dd280bb0d36 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3270978 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 393785b7 2021-11-10T12:14:03 Add attribute validation for context creation. This fixes another ASAN bug that popped up with the dEQP EGL tests: dEQP.EGL/functional_negative_api_create_context Bug: angleproject:6660 Change-Id: I8f5ca1cc9ca77f2be28ecf120a90c9efcf9d4b24 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3270977 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 2d4bee83 2021-11-04T10:16:16 EGL: Add early exit when hitting invalid attribute. According to the EGL spec, we stop checking attributes when we encounter an invalid enum. That means it's valid for an application to pass in a list of attributes without EGL_NONE as long as one of them is invalid. To handle this, we add lazy attribute validation to the AttributeMap class, that gets triggered in the validation calls. We only implement the early exit validation for the config attributes to fix an EGL test that would access out of bounds memory. Bug: angleproject:6660 Change-Id: I264d0f98b4ddd9e74187846e9e668270a6fbaee1 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3262478 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Jonah Ryan-Davis f422f21a 2021-11-09T18:42:15 Reland "Metal: Reintroduce GPU power preference selection code." This reverts commit 67a8cf07a740c5ce3aafd2ad7fddd370451b3525. Reason for revert: Landed Chromium-side dependency: https://chromium-review.googlesource.com/c/chromium/src/+/3271170 Original change's description: > Revert "Metal: Reintroduce GPU power preference selection code." > > This reverts commit 017161701b7dbf70a13f3c180a39e1fa45c27d9f. > > Reason for revert: Blocking roller, please re-land with the fix. > > Original change's description: > > Metal: Reintroduce GPU power preference selection code. > > > > This CL re-introduces the GPU power preference code to > > the metal backend. It also reworks EGLDisplay caching > > in the frontend to cache based on the native display > > as well as the power preference attribute. > > A new extension, EGL_ANGLE_display_power_preference is > > added based on EGL_ANGLE_power_preference. This extension > > is a client extension that allows selection of GPU on > > display creation, similar to how GPUs are selected on > > context creation in EGL_ANGLE_power_preference. > > This CL adds EGLDisplayPowerPreferenceTest and enables it on > > the metal backend. > > > > Bug: angleproject:6143 > > Change-Id: I0a081dcd2e3f18ab365fdd3498ddcb6e2ba35212 > > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3231986 > > Reviewed-by: Kenneth Russell <kbr@chromium.org> > > Reviewed-by: Jamie Madill <jmadill@chromium.org> > > Reviewed-by: Gregg Tavares <gman@chromium.org> > > Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> > > TBR=kbr@chromium.org,gman@chromium.org,jonahr@google.com,jmadill@chromium.org,angle-scoped@luci-project-accounts.iam.gserviceaccount.com > > Change-Id: I4f775bf7139253a87b033a30e0da2100b3c1bb02 > No-Presubmit: true > No-Tree-Checks: true > No-Try: true > Bug: angleproject:6143 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3270749 > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Commit-Queue: Jamie Madill <jmadill@chromium.org> # Not skipping CQ checks because this is a reland. Bug: angleproject:6143 Change-Id: Id9b0a5cbb76e4dea9e2f2da2b1c47a0587dfdaf5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3270970 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
Jeff Vigil 5eb86d4a 2021-09-21T15:17:04 EGL: EGL_KHR_lock_surface3 frontend Add queries to get locked buffer attributes Add validation for LockSurface, QuerySurface Bug: angleproject:6062 Change-Id: I4919bef2a17d3505cccad08f7c4f8a3ca5d7e4e6 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3174322 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jeff Vigil d3e67716 2021-09-21T15:03:15 EGL: EGL_KHR_lock_surface3 Add new extension KHR__lock_surface3 Add new interfaces for locking and unlocking a surface. Test: angle_end2end_test --gtest_filter=EGLLockSurface3Test Bug: angleproject:6062 Change-Id: Ic40708db4db552107025635540a0c62f956d741e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3161447 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 67a8cf07 2021-11-09T15:10:50 Revert "Metal: Reintroduce GPU power preference selection code." This reverts commit 017161701b7dbf70a13f3c180a39e1fa45c27d9f. Reason for revert: Blocking roller, please re-land with the fix. Original change's description: > Metal: Reintroduce GPU power preference selection code. > > This CL re-introduces the GPU power preference code to > the metal backend. It also reworks EGLDisplay caching > in the frontend to cache based on the native display > as well as the power preference attribute. > A new extension, EGL_ANGLE_display_power_preference is > added based on EGL_ANGLE_power_preference. This extension > is a client extension that allows selection of GPU on > display creation, similar to how GPUs are selected on > context creation in EGL_ANGLE_power_preference. > This CL adds EGLDisplayPowerPreferenceTest and enables it on > the metal backend. > > Bug: angleproject:6143 > Change-Id: I0a081dcd2e3f18ab365fdd3498ddcb6e2ba35212 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3231986 > Reviewed-by: Kenneth Russell <kbr@chromium.org> > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Gregg Tavares <gman@chromium.org> > Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> TBR=kbr@chromium.org,gman@chromium.org,jonahr@google.com,jmadill@chromium.org,angle-scoped@luci-project-accounts.iam.gserviceaccount.com Change-Id: I4f775bf7139253a87b033a30e0da2100b3c1bb02 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: angleproject:6143 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3270749 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis 01716170 2021-10-14T13:24:41 Metal: Reintroduce GPU power preference selection code. This CL re-introduces the GPU power preference code to the metal backend. It also reworks EGLDisplay caching in the frontend to cache based on the native display as well as the power preference attribute. A new extension, EGL_ANGLE_display_power_preference is added based on EGL_ANGLE_power_preference. This extension is a client extension that allows selection of GPU on display creation, similar to how GPUs are selected on context creation in EGL_ANGLE_power_preference. This CL adds EGLDisplayPowerPreferenceTest and enables it on the metal backend. Bug: angleproject:6143 Change-Id: I0a081dcd2e3f18ab365fdd3498ddcb6e2ba35212 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3231986 Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Gregg Tavares <gman@chromium.org> Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
Peng Huang d7090f5d 2021-10-29T10:45:19 Add more attributes for EGL_ANGLE_device_vulkan Bug: chromium:1264439 Change-Id: Ibc9676cef16411b17c833abe9559721811016eef Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3264164 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Peng Huang <penghuang@chromium.org>
Peng Huang 81d964a1 2021-10-28T10:50:51 vulkan: implement EGLDevice for vulkan backend It allows ANGLE clients to get and use VkDevice and VkQueue used by vulkan backend. Bug: chromium:1264439 Change-Id: I338ac08152cfec50bb34c5025730e5e6368efba9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3250964 Reviewed-by: Peng Huang <penghuang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Peng Huang <penghuang@chromium.org>
Geoff Lang d2c01d2c 2021-09-17T12:57:14 GL: Allow selecting virtualization groups at context creation Rewrite EGL_ANGLE_platform_angle_context_virtualization to EGL_ANGLE_context_virtualization, changing the context virtualization parameter to an identifier for what virtualization group the frontend context should be added to. This allows ANGLE's GL backend to be used by multiple threads if the user creates contexts with different virtualization groups. Bug: angleproject:6406 Change-Id: I7414d4705ce10bdf63a9b824043d5dd040dad875 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3169193 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Ian Elliott 6c448659 2021-10-15T15:43:18 Improve EGL validation errors Improvements: - Report the numeric value of a bad attribute - Show the requested/desired/unsupported version and the max version - Correct printf attribute set and previous errors fixed Bug: b/186543601 Change-Id: I889f2384afbe134496cad9e349766b7ff756dcee Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3224566 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Geoff Lang ad8e4d99 2021-09-28T11:48:46 Remove EGL_ANGLE_flexible_surface_compatibility This extension has been superseded by EGL_KHR_no_config_context. Bug: chromium:1253930 Change-Id: Ie299c34baa84e9f47c73ddb5a0636536bf510d72 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3190612 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill e84b0154 2021-09-13T16:04:20 Update extension boolean names. This is in preparation for auto-gen, which uses a simple naming scheme. This fixes the bool names to be totally consistent with the extension names. Bug: angleproject:6379 Change-Id: Ia212449be04accb0e4f006b55b1813ab4481fa0b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3157417 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill 1ca1589f 2021-09-13T10:56:58 Give GLES extension bools a vendor suffix. This is in preparation for auto-generation which will give all of these bools suffixes. Bug: angleproject:6379 Change-Id: I7e3f6c9b644c41a2165e6bf7b62d661fd352a250 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3158503 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
YuxinHu af57475e 2021-08-27T00:33:39 Improve Error Messaging Improving error messaging for egl validations. Bug: b/186543601 Change-Id: Iec9a8f14998bc105785eca990f6512b72385191a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3124071 Reviewed-by: Ian Elliott <ianelliott@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Yuxin Hu <yuxinhu@google.com>
Jamie Madill d2d1f41f 2021-08-16T08:05:55 Add EGL extension to create window with a swap interval set. On Vulkan this allows creating a window once without needing to recreate the swapChain after we specify the swap interval. Also adds a simple regression test and EGL enum assertion printing formatting. Bug: angleproject:5133 Change-Id: I72af124cb0e8f7cddfa810988a9862c0f36a0e46 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3097806 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Reviewed-by: Cody Northrop <cnorthrop@google.com>
Jeff Vigil 6136620b 2021-03-25T15:43:06 Reland "EGL: GLES: Implement GL_EXT_protected_textures" This is a reland of 6210a9b34a721df2c84cf69170ad9bf7ba40e4aa This removes changes in gl backend. Original change's description: > EGL: GLES: Implement GL_EXT_protected_textures > > Implement EGL_EXT_protected_content Images > Add protected member to Images and Textures > Add error when creating objects if not supported or > does't match native buffer > When creating siblings pass protected state > Add extension caps > Add Validation > Add GetTexParameter and SetTextparameter > Add protected to Texture and state > Expand tests for images and textures > > Test: angle_end2end_test --gtest_filter=EGLProtectedContentTest > > Bug: angleproject:3965 > Change-Id: I35a89b4e80bba6d9b6831c68e71630eef304dacb > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2802852 > Commit-Queue: Mohan Maiya <m.maiya@samsung.com> > Reviewed-by: Geoff Lang <geofflang@chromium.org> > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Test: angle_end2end_test --gtest_filter=EGLProtectedContentTest Bug: angleproject:3965 Change-Id: Id36d697c53afc0f0dadf92bda4565f9157f4fc2a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3076825 Commit-Queue: Brandon Schade <b.schade@samsung.com> Reviewed-by: Ian Elliott <ianelliott@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill c408926f 2021-07-22T12:00:59 Revert "EGL: GLES: Implement GL_EXT_protected_textures" This reverts commit 6210a9b34a721df2c84cf69170ad9bf7ba40e4aa. Reason for revert: Suspected for breaking ANGLE->Chrome roller. Bug: angleproject:6204 Original change's description: > EGL: GLES: Implement GL_EXT_protected_textures > > Implement EGL_EXT_protected_content Images > Add protected member to Images and Textures > Add error when creating objects if not supported or > does't match native buffer > When creating siblings pass protected state > Add extension caps > Add Validation > Add GetTexParameter and SetTextparameter > Add protected to Texture and state > Expand tests for images and textures > > Test: angle_end2end_test --gtest_filter=EGLProtectedContentTest > > Bug: angleproject:3965 > Change-Id: I35a89b4e80bba6d9b6831c68e71630eef304dacb > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2802852 > Commit-Queue: Mohan Maiya <m.maiya@samsung.com> > Reviewed-by: Geoff Lang <geofflang@chromium.org> > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Bug: angleproject:3965 Change-Id: Ia3ef260a17097b474189ccad5b235a9db99ee00b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3043889 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org> Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Jeff Vigil 6210a9b3 2021-03-25T15:43:06 EGL: GLES: Implement GL_EXT_protected_textures Implement EGL_EXT_protected_content Images Add protected member to Images and Textures Add error when creating objects if not supported or does't match native buffer When creating siblings pass protected state Add extension caps Add Validation Add GetTexParameter and SetTextparameter Add protected to Texture and state Expand tests for images and textures Test: angle_end2end_test --gtest_filter=EGLProtectedContentTest Bug: angleproject:3965 Change-Id: I35a89b4e80bba6d9b6831c68e71630eef304dacb Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2802852 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jeff Vigil d2b659f9 2021-03-25T15:40:58 EGL: implement EGL_EXT_protected_content Context Add Validation check to Contexts and Surfaces Add Vulkan protected memory features and properties Add protected member to Surfaces and Contexts Implement hasProtectedContent in Vulkan Add QueueFamily helper, extent DeviceQueueMap Protected Swapchains always on for Android Add EGLProtectedContentTest Test: angle_end2end_test --gtest_filter=EGLProtectedContentTest Bug: angleproject:3965 Change-Id: I9352b1e594f71bb4e89cee7137a468940d186b1b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2800413 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 8c1cbc5a 2021-07-16T14:01:53 Implement EGL_KHR_mutable_render_buffer in the front-end. Note that we do not currently expose any mutable configs. Bug: b/192352791 Change-Id: Ib97f7889fedd91d09ef32dc7e7494ea4476cd7bd Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3035583 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com> Reviewed-by: Tim Van Patten <timvp@google.com>
Peter Kasting 1bffabe8 2021-06-29T18:13:39 Fix -Wunreachable-code-aggressive. Bug: chromium:1066980 Change-Id: I1fa08a40dbf223d60a10681af33ca8a29b12bf8b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2991094 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
John Plate cddb2003 2021-04-23T18:26:51 Stubs for CL validation entry points Bug: angleproject:5775 Change-Id: Ic3b15efdf602bad8f5f170f03ba24b421a398ca8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2848504 Reviewed-by: Cody Northrop <cnorthrop@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: John Plate <jplate@google.com>
Mohan Maiya 904ac340 2021-04-26T15:54:25 Bug fix for WaitClient, WaitGL and WaitNative It is valid to call eglWaitClient, eglWaitGL and eglWaitNative when there is no active context in the current thread. Update code to account for that possibility. Bug: angleproject:5898 Test: EGLSyncTest.WaitClient* EGLSyncTest.WaitGL* EGLSyncTest.WaitNative* Change-Id: I81f05a27f1f641cf8986e2e6c05c183ea8471889 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2849587 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Le Hoang Quyen f2aa9d5d 2021-04-11T14:55:19 Reland: Metal: Support importing external metal textures This relands I4d4a88cfbb77d8b7508b787c7fec44073d3b11b0. Fixes: - uninstantiated ImageTestMetal error - failed ImageTest.ANGLEExtensionAvailability on ARM mac. Bug: angleproject:5763 Bug: angleproject:5814 Change-Id: I906fe52baefd6be3c6e00f594795bd527df01616 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2820178 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Le Hoang Quyen <le.hoang.q@gmail.com>
Kai Ninomiya 256100b2 2021-04-02T01:45:14 Revert "Metal: Support importing external metal textures" This reverts commit 2ec3e0a1e6890da56de9dfd3da5c9f31a3f7fbb7. Reason for revert: Test suite ImageTestMetal never instantiated https://anglebug.com/5814 Original change's description: > Metal: Support importing external metal textures > > via KHR_image_base and ANGLE_metal_texture_client_buffer > > Bug: angleproject:5763 > Change-Id: I4d4a88cfbb77d8b7508b787c7fec44073d3b11b0 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2757811 > Commit-Queue: Le Hoang Quyen <le.hoang.q@gmail.com> > Reviewed-by: Kenneth Russell <kbr@chromium.org> > Reviewed-by: Jamie Madill <jmadill@chromium.org> Bug: angleproject:5763, angleproject:5814 Change-Id: Ia862aa37a6c914f6e21f9b3121c7c36d449475ea No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2801155 Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com> Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Kenneth Russell <kbr@chromium.org>
Le Hoang Quyen 2ec3e0a1 2021-03-13T22:17:49 Metal: Support importing external metal textures via KHR_image_base and ANGLE_metal_texture_client_buffer Bug: angleproject:5763 Change-Id: I4d4a88cfbb77d8b7508b787c7fec44073d3b11b0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2757811 Commit-Queue: Le Hoang Quyen <le.hoang.q@gmail.com> Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Le Hoang Quyen 4ac6ea2a 2020-07-18T21:05:37 Metal: implement ANGLE_device_metal extension. Allow user to query internal MTLDevice used by Metal back-end. Bug: angleproject:2634 Change-Id: I9b0a6eaad8c634069f43e47d5f4f88f61da35f74 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2757810 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jeff Vigil cef5b717 2021-03-11T09:22:33 EGL: Add attribute check in ValidateQueryContext Implementation of EGL_IMG_context_priority was missing attribute check in ValidateQueryContext Add test case. Test: angle_end2end_test --gtest_filter=EGLCreateContextAttribsTest Bug: angleproject:5746 Change-Id: Idf5df29fcb343d969a031675b6c5985a9be0a705 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2752891 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jeff Vigil 22fc9523 2021-02-03T15:32:48 EGL: implement EGL_EXT_buffer_age Add extension flag. Add Validation check to surface query. Enable extension for vulkan. Modify AcquireNextImage to ++frame count and tag images with frame number. Buffer age is the difference between current frame count and the tagged frame number on the buffer. getBuffeAge may need to trigger AcquireNextImage to be current. Pass through egl extension and query. Add EGLBufferAgeTest Test: angle_end2end_test --gtest_filter=EGLBufferAgeTest Test: angle_deqp_egl_tests --deqp-case=dEQP-EGL.functional.buffer_age.* Bug: angleproject:3529 Change-Id: I0cb94be1c3e85d6f33e82a6a1ccdc9731b6a7f23 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2684724 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Sunny Sachanandani 137271ff 2021-01-13T14:34:12 Support specifying array slice for D3D11 texture EGLImage Client can specify array slice for creating the SRV/RTV with EGL_D3D11_TEXTURE_ARRAY_SLICE_ANGLE. Test: D3DTextureTest.TextureArrayImage* Bug: angleproject:5538, chromium:1116101 Change-Id: I81cb2823df2145f1d05ad1526b0e36d6a0724d5e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2628609 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org>
Peng Huang 043fcf18 2021-01-07T13:23:57 Support create ANGLE EGLContext from an external EGLContext For Android WebView, Android creates an EGLContext, EGLSurface and FBO, and makeCurrent on them, and then calls WebView draw function to draw the WebView content on the current EGLSurface or binded FBO. So to use ANGLE in WebView, this CL adds a way to create ANGLE EGLContext from an external EGLContext, and save and restore GL state in eglMakeCurrent(). Bug: angleproject:5509 Change-Id: I874986813117f125e23e975ea1adc51ac5b3a631 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2615239 Commit-Queue: Peng Huang <penghuang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Sunny Sachanandani 198dc345 2020-08-06T16:32:03 Support importing NV12/P010/P016 D3D textures as EGLImage Allow importing individual planes of NV12/P010/P016 D3D textures with supported SRV/RTV formats. Restrict these to GL_TEXTURE_EXTERNAL_OES to limit to using as shader inputs or render targets and prevent unsupported operations like ReadPixels. Test: D3DTextureYUVTest* Bug: angleproject:5538, chromium:1116101 Change-Id: If5bf54f4f75bb2c703890ce3f5fbd67e4461c98f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2338827 Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 3f564fc7 2020-11-23T13:59:17 EGL: Generate entry points. This adds two final auto-generated files for the EGL and EXT extension entry points. It adds a new data file that stores a mapping between object types and entry points for associating labeled objects with certain methods. When we generate errors we record the associated object in the debug message output. This places the remainder of the hand-written code in "stub" files. Going forward the work for implementing new extension entry points for EGL will be to update the registry XML files and then implement the corresponding stub methods. Event logging, parameter packing, and validation are all handled by the auto-generated code. Bug: angleproject:2621 Change-Id: I28153432802c37b929ff2ea1e1a3e3ce9de91605 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2562680 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com> Reviewed-by: Tim Van Patten <timvp@google.com>
Jamie Madill 3efa290d 2020-11-19T14:36:16 EGL: Auto-generate validation header. This is a first step towards auto-generating more EGL code. It includes format handling for all the EGL parameter types, type reinterpretation for EGL types using the "packed enum" handling, and code refactoring to support the new consistent validation entry point pattern. Bug: angleproject:2621 Change-Id: I2740e82928db311aa934825cbe74bd75bf49c33c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2552976 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Reviewed-by: Cody Northrop <cnorthrop@google.com>
Jamie Madill cfe14e28 2020-11-19T18:11:42 EGL: Remove egl::Error from validation code. Instead of using an egl::Error return value, errors are recorded on the egl::Thread immediately at the call site. This makes the code work the same way as in the GL entry points. Updates the EGL "try" macros to include a special handler for the EGL validation entry points. Uses a special ValidationContext helper class to preserve the existing info. Bug: angleproject:5378 Change-Id: I897f221a41fe406676950600e4ac559081b9f541 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2551790 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com> Reviewed-by: Tim Van Patten <timvp@google.com>
Jamie Madill 56663dbf 2020-11-19T21:21:19 EGL: Expose device query as a client extension. This matches the extension spec. Previously we were exposing the ext as a normal display extension. The extension should work without needing a display. Because the extension requires a non-null device for every display we also add a MockDevice class to handle back-ends which don't implement any attribute query extensions. By default the device query ext does not expose any way to use devices so this works fine. Bug: angleproject:5372 Change-Id: I474310a86aff6a83bd6f9a6b21c8a07c649f306d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2551543 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 8d63a7fc 2020-11-17T15:15:44 Basic support for running deqp khr gles32 tests Bug: angleproject:3647 Change-Id: Ia707ffcd41926662d1513f1a3bf49149b76f6b9c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2544920 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
James Darpinian 27af0b2d 2020-10-19T16:49:48 Reland "ANGLE_platform_angle_device_context_volatile_* extensions" This is a reland of e70f6aa679dd72eca5c88c71b0932928e92d6067 Original change's description: > ANGLE_platform_angle_device_context_volatile_* extensions > > Change from Kimmo Kinnunen downstream: > https://bugs.webkit.org/show_bug.cgi?id=216106 > > Add two extensions for EAGL and CGL backends to declare the > underlying platform context being "volatile". It means that > the thread-global current context is being modified behind > ANGLE. If ANGLE context is marked volatile for a particular > API, it will sync the underlying context for every EGL > function that needs the context. Most intuitive use is > for the client to call eglMakeCurrent before calling any > gl function if the client knowns the platform state might > be dirty. > > Implement eglReleaseThread for EAGL and CGL backends. > Releasing thread will unset the platform current context. > > Fix a bug of omitting EGL_ANGLE_device_eagl from being > advertised. > > Bug: angleproject:5104 > Change-Id: I1ec98ad35bc0caada23556ae8697fdef20f65b1a > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2486548 > Commit-Queue: James Darpinian <jdarpinian@chromium.org> > Reviewed-by: Kenneth Russell <kbr@chromium.org> > Reviewed-by: Geoff Lang <geofflang@chromium.org> Bug: angleproject:5104 Change-Id: I88265625a4bb4c1412532768d17d7b4356c7be41 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2508842 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: James Darpinian <jdarpinian@chromium.org>
Geoff Lang 68b95b63 2020-10-29T14:09:08 Revert "ANGLE_platform_angle_device_context_volatile_* extensions" This reverts commit e70f6aa679dd72eca5c88c71b0932928e92d6067. Reason for revert: dEQP failures: dEQP.EGL/functional_get_frame_timestamps_rgb565_no_depth_no_stencil dEQP.EGL/functional_get_frame_timestamps_rgb565_no_depth_stencil dEQP.EGL/functional_hdr_metadata_cta861_3 dEQP.EGL/functional_hdr_metadata_smpte2086 dEQP.EGL/functional_mutable_render_buffer_basic dEQP.EGL/functional_swap_buffers_with_damage_resize_after_swap_buffer_age_clear dEQP.EGL/functional_swap_buffers_with_damage_resize_after_swap_buffer_age_clear_clear dEQP.EGL/functional_swap_buffers_with_damage_resize_after_swap_buffer_age_render dEQP.EGL/functional_swap_buffers_with_damage_resize_before_swap_buffer_age_clear dEQP.EGL/functional_swap_buffers_with_damage_resize_before_swap_buffer_age_clear_clear dEQP.EGL/functional_swap_buffers_with_damage_resize_before_swap_buffer_age_render Original change's description: > ANGLE_platform_angle_device_context_volatile_* extensions > > Change from Kimmo Kinnunen downstream: > https://bugs.webkit.org/show_bug.cgi?id=216106 > > Add two extensions for EAGL and CGL backends to declare the > underlying platform context being "volatile". It means that > the thread-global current context is being modified behind > ANGLE. If ANGLE context is marked volatile for a particular > API, it will sync the underlying context for every EGL > function that needs the context. Most intuitive use is > for the client to call eglMakeCurrent before calling any > gl function if the client knowns the platform state might > be dirty. > > Implement eglReleaseThread for EAGL and CGL backends. > Releasing thread will unset the platform current context. > > Fix a bug of omitting EGL_ANGLE_device_eagl from being > advertised. > > Bug: angleproject:5104 > Change-Id: I1ec98ad35bc0caada23556ae8697fdef20f65b1a > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2486548 > Commit-Queue: James Darpinian <jdarpinian@chromium.org> > Reviewed-by: Kenneth Russell <kbr@chromium.org> > Reviewed-by: Geoff Lang <geofflang@chromium.org> TBR=geofflang@chromium.org,kbr@chromium.org,jdarpinian@chromium.org,jonahr@google.com # Not skipping CQ checks because original CL landed > 1 day ago. Bug: angleproject:5104 Change-Id: Ib683625a55a582c39e5a4a0466038cfa6e782e6c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2507260 Reviewed-by: Geoff Lang <geofflang@chromium.org>
James Darpinian e70f6aa6 2020-10-19T16:49:48 ANGLE_platform_angle_device_context_volatile_* extensions Change from Kimmo Kinnunen downstream: https://bugs.webkit.org/show_bug.cgi?id=216106 Add two extensions for EAGL and CGL backends to declare the underlying platform context being "volatile". It means that the thread-global current context is being modified behind ANGLE. If ANGLE context is marked volatile for a particular API, it will sync the underlying context for every EGL function that needs the context. Most intuitive use is for the client to call eglMakeCurrent before calling any gl function if the client knowns the platform state might be dirty. Implement eglReleaseThread for EAGL and CGL backends. Releasing thread will unset the platform current context. Fix a bug of omitting EGL_ANGLE_device_eagl from being advertised. Bug: angleproject:5104 Change-Id: I1ec98ad35bc0caada23556ae8697fdef20f65b1a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2486548 Commit-Queue: James Darpinian <jdarpinian@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jeff Vigil 00a49766 2020-10-14T10:27:56 EGL: Implement EGL_KHR_reusable_sync Add extension string and flags Add EGLReusableSync files to libANGLE and gni Test: angle_deqp_egl_tests --deqp-case=dEQP-EGL.functional.reusable_sync.* --deqp-case=dEQP-EGL.functional.fence_sync.* Bug: angleproject:5168 Change-Id: I967a10cf387047c9ee1963acfc854a8288325a8e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2477293 Commit-Queue: Jeff Vigil <j.vigil@samsung.com> Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis 96a49a48 2020-10-06T13:34:09 GLX, EGL: Support NV_robustness_video_memory_purge Chrome is showing rendering issues on Linux/Nvidia after returning from the lock screen. This could be related to the fact that Nvidia drivers are not able to guarantee conformance after certain events. By exposing this extension, we can instruct Chrome to reinitialize contexts after they are purged by the driver. If this is not explicitly requested, we can still generate an UnknownContextReset to tell apps to discard the invalid context anyway. Bug: chromium:1113040 Change-Id: Ie99b6356cc27fea33643d61b1d74f4f68a271d70 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2453689 Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
Mohan Maiya c99c22bb 2020-09-15T16:53:26 EGL: Add support for EGL_ANDROID_create_native_client_buffer This EGL extension will add support for creating EGLClientBuffer backed by an Android window buffer (struct ANativeWindowBuffer) which can be later used to create an EGLImage. Bug: angleproject:5018 Tests: angle_end2end_tests --gtest_filter=ImageTest.SourceNativeClientBufferTarget* Change-Id: If78ed7b80ad09629b8c5f5b5a0eb07a548e82e6e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2404320 Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Peng Huang 4cf2501c 2020-07-27T13:19:27 Add extension EGL_ANGLE_display_semaphore_share_group For sharing semaphores globally. Bug: angleproject:4877 Change-Id: I472e0902fd04ca8350d74e6c0ae6925ee930ccf9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2319370 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 4e6f6545 2020-04-16T16:31:24 GLX: Support X11 pixmaps Add support for creating EGL pixmaps from X11 pixmaps using GLX. Pixmaps are needed for various external APIs such as VAAPI. Add support for EGL_NOK_texture_from_pixmap to allow binding pixmaps to textures. BUG=angleproject:4560 Change-Id: I4a6d3ad7e87151ff5317bbdaaf093ac1b46daf5f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2153805 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Tim Van Patten <timvp@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Sunny Sachanandani 3d5f0c82 2020-05-19T20:05:57 Use surface texture offset for clears and blits https://chromium-review.googlesource.com/c/angle/angle/+/2186176 added surface texture offset attributes for D3D11 pbuffer surfaces, but the implementation didn't apply the offset to blits or clears. This CL fixes that and includes a unit test for blit, clear, and draw. Also renames textureOffset to surfaceTextureOffset throughout since it's clearer, and fixes the dcomp surface test to specify the update offset returned by dcomp BeginDraw(). Bug: angleproject:2997 Change-Id: I9298ccf55cbb2d04c3b8f78e12f9d07dc8fa54b5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2210967 Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Sunny Sachanandani 4b225c70 2020-05-06T15:38:12 Add texture offset attributess for D3D texture pbuffer surfaces Add EGL_TEXTURE_OFFSET_X_ANGLE and EGL_TEXTURE_OFFSET_Y_ANGLE attributes to EGL_ANGLE_d3d_texture_client_buffer which are used to specify offsets used for rendering into the pbuffer surface backed by a D3D11 texture. Rendering with the correct offset is needed when Chrome gets a texture and offset from an external source e.g. when calling BeginDraw() on IDCompositionSurface. Bug: angleproject:2997 Change-Id: I363f739f3f05c38720f385e34c91e98fc6a622a0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2186176 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org>
Patrick To a2ec926c 2020-01-02T19:07:38 Specify LUID in D3D11 Add an extension to provide the ability to specify the LUID of the GPU adapter to use when using D3D11. Corresponding chromium CL: https://chromium-review.googlesource.com/c/chromium/src/+/2096778 Bug: chromium:792657 Change-Id: Iefebea221a4b7a20f150b445ae1adf375444726d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2096663 Commit-Queue: Rafael Cintron <rafael.cintron@microsoft.com> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Jiajia Qin 85ae836f 2020-03-30T16:03:47 GL: Implement EGL_EXT_image_dma_buf_import Add support for the EGL_EXT_image_dma_buf_import on EGL implementations that support it natively. This extensin is used on ozone to import native compositing buffers. This patch also adds new tokens in EGL_EXT_image_dma_buf_import_modifiers which are used in eglCreateImageKHR. BUG=angleproject:4529 Change-Id: I49bff831b591fb19fcdcec1145c7a61f5d8020c4 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2128190 Commit-Queue: Jiajia Qin <jiajia.qin@intel.com> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jeff Vigil e20f36f4 2020-04-21T15:45:44 EGL: Implement EGL_ANDROID_native_fence_sync on vulkan Check the following - 1. Vulkan ICD supports VK_KHR_external_fence_fd 2. ExternalFenceProperties and ExternalSemaphoreProperties support Android FD. eglCreateSync - if FD was provided import to VkFence, else create VkFence with new FD and then flush and submit VkFence on next vkQueueSubmit. eglGetSyncAttrib - for status call vkGetFenceStatus. eglDupNativeFenceFdANDROID - return FD from vkGetFenceFD call. eglClientWaitSync - call vkWaitForFences. eglWaitSync - dup FD, create VkSemaphore and import FD, then flush() and add VkSemaphore to next vkQueueSubmit as a waiting semaphore. Extended end2end test suite with nativefence test cases. Bug: angleproject:2517 Test: angle_end2end_tests --gtest_filter=EGLSyncTest.AndroidNativeFence_* Change-Id: I8f6a6f4c3d71d83007f662b78377aa015a740035 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2026177 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Mohan Maiya dac5cc3b 2020-04-08T18:26:46 EGL: Add support for EGL_EXT_image_gl_colorspace extension Add support for creating images with custom colorspace. Bug: angleproject:3756 Tests: angle_end2end_tests --gtest_filter=ImageTest* Change-Id: I9c332c012541c094728d9d9bde7add4189084a33 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2104088 Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Jonah Ryan-Davis 4b94d7bb 2020-03-24T17:23:19 Split EGL_CHROMIUM_sync_control into EGL_ANGLE_sync_control_rate eglGetMscRateCHROMIUM was added to EGL_CHROMIUM_sync_control based on the original extension GLX_OML_sync_control. However, this new function is not universally implemented. This CL moves it to a new extension, EGL_ANGLE_sync_control_rate, and renames it to eglGetMscRateANGLE. Bug: chromium:1064078 Change-Id: Ia2a29c6776b2b2bf2b98e58ee83b5f141ed01301 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2118154 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Tim Van Patten <timvp@google.com>
Julien Isorce 07044c65 2020-03-03T00:13:03 Reland "Instantiate rx::DisplayEGL when device type EGL is selected" This is a reland of 7455b54401dd55833944b5ad857ccd9852ef6a79 Original change's description: > Instantiate rx::DisplayEGL when device type EGL is selected > > Define EGL_PLATFORM_ANGLE_DEVICE_TYPE_EGL_ANGLE that should be > used to request a driver egl-backed implementation with ANGLE. > > Bug: angleproject:4328 > Change-Id: I6871d3a27e2bfc02af9815dcf86ae1cb6524f0cc > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2030038 > Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> > Reviewed-by: Geoff Lang <geofflang@chromium.org> Bug: angleproject:4328 Change-Id: I4e997c4fa1b5b59f081436f05bd208303ffe38e9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2093412 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Julien Isorce <julien.isorce@chromium.org>
Ian Elliott 03ed5f6c 2020-03-06T22:15:42 Revert "Instantiate rx::DisplayEGL when device type EGL is selected" This reverts commit 7455b54401dd55833944b5ad857ccd9852ef6a79. Reason for revert: This appears to break the "Linux FYI Ozone (Intel)" bots on the chromium.gpu.fyi waterfall. Ozone means ChromeOS. Original change's description: > Instantiate rx::DisplayEGL when device type EGL is selected > > Define EGL_PLATFORM_ANGLE_DEVICE_TYPE_EGL_ANGLE that should be > used to request a driver egl-backed implementation with ANGLE. > > Bug: angleproject:4328 > Change-Id: I6871d3a27e2bfc02af9815dcf86ae1cb6524f0cc > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2030038 > Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> > Reviewed-by: Geoff Lang <geofflang@chromium.org> TBR=geofflang@chromium.org,syoussefi@chromium.org,jonahr@google.com,julien.isorce@chromium.org Change-Id: I8aec6c2783b0acb67d3315d351cdc9e526f58d6b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: angleproject:4328 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2091864 Reviewed-by: Ian Elliott <ianelliott@google.com> Commit-Queue: Ian Elliott <ianelliott@google.com>
Julien Isorce 7455b544 2020-03-03T00:13:03 Instantiate rx::DisplayEGL when device type EGL is selected Define EGL_PLATFORM_ANGLE_DEVICE_TYPE_EGL_ANGLE that should be used to request a driver egl-backed implementation with ANGLE. Bug: angleproject:4328 Change-Id: I6871d3a27e2bfc02af9815dcf86ae1cb6524f0cc Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2030038 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jonah Ryan-Davis 698ffd02 2020-02-27T10:59:13 eglGetConfigAttrib validation missing extension check The extension EGL_ANGLE_iosurface_client_buffer adds a new attribute to the config: EGL_BIND_TO_TEXTURE_TARGET_ANGLE. However, validation was not checking the extension was present when this attribute was requested. Bug: chromium:1015454 Change-Id: I24c6e20f3b602e8a71a46f0f1e99c1472d5bbb1e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2078892 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis 806ba566 2019-12-12T13:02:01 Extend ANGLE_iosurface_client_buffer to Vulkan backend for Swangle Implement an IOSurface-backed pBuffer surface for the Vulkan backend on Mac, through SwANGLE. ANGLE will pass a raw pointer to Swiftshader and handle locking/unlocking the IOSurface. Bug: chromium:1015454 Change-Id: Ia3ead55334736003d405b54ba8dcc7701706fbb2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1965434 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis 1a1a1427 2020-01-23T13:57:21 Expose eglGetMscRateCHROMIUM from EGL_CHROMIUM_sync_control When ANGLE is using the GL backend on GLX, we can expose eglGetMscRateCHROMIUM via glXGetMscRateOML. Otherwise, this function should return false. Bug: chromium:1042393 Change-Id: Id9b308c2217e07ee9860e2869be0e23b7a0c7411 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2017048 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jeff Vigil 564eb6f2 2019-11-22T16:46:02 Implement EGL_IMG_context_priority Change RendererVk to have 3 VkQueues instead of one. Each queue has a priority. To match extension: Low, Med, High. gl::Context contains priority. ContextVk contains a reference to one of the queues. Every call to vulkan that uses queue, uses the associated context queue. Bug: angleproject:3962 Change-Id: Ibd913a07a81c77bd975921d6dbae6a222842e88b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1978154 Commit-Queue: Jeff Vigil <j.vigil@samsung.com> Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jeff Gilbert 23521ca3 2020-01-22T18:42:56 Validate `context` before use in ValidateStreamConsumerGLTextureExternalAttribsNV. Firefox bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1608235 Bug: angleproject:4333 Change-Id: I957b6412f7c744e4bbaa7d8084b3c81ee58d45ca Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2015838 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>