255 Commits
Author SHA1 Message Date
Alexey Knyazev 067ace47d0 Add ANGLE_clip_cull_distance extension
Added an extension spec.

Trivially exposed it on GL, Vulkan, and D3D11.

Adjusted tests and validation to allow no cull
distance support for this extension string.

Removed extra built-in variable definitions.

Bug: angleproject:7904
Change-Id: Ic60772dfe28132c316eaa29aadc1afd66e3b0fa7
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4114290
Reviewed-by: Shahbaz Youssefi <[email protected]>
Commit-Queue: Alexey Knyazev <[email protected]>
2022-12-23 01:57:59 +00:00
Gregg Tavares be9e8e7b03 Add EGL_ANGLE_wait_until_work_scheduled extension
We're changing eglReleaseTexImage so it calls
flushCommandBuffer(mtl::NoWait) instead of
flushCommandBuffer(mtl::WaitUntilScheduled)
and then adding an extension to allow us to
WaitUntilScheduled.

This is because Chrome calls eglReleaseTexImage for
every canvas and having it WaitUntilScheduled per call
is very slow. So instead we'll call eglWaitUntilWorkScheduledANGLE
once which will effectively wait just once.

Bug: angleproject:7890
Change-Id: I87bc9f9a1a7f4a0f99d93736cc3083799e76afeb
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4109311
Reviewed-by: Kenneth Russell <[email protected]>
Commit-Queue: Gregg Tavares <[email protected]>
2022-12-17 02:33:59 +00:00
Chris Dalton 004c5c9452 Prefix all PLS enums with "GL_"
Bug: angleproject:7279
Change-Id: Ifb4062e502305f4e59546f067d195d1a05fbabe4
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4095380
Reviewed-by: Shahbaz Youssefi <[email protected]>
Commit-Queue: Chris Dalton <[email protected]>
Reviewed-by: Steven Noonan <[email protected]>
2022-12-13 16:32:24 +00:00
Chris Dalton eb1a13d8cf Improve PLS load and store op tokens
Define more new tokens that are more clearly named, as opposed to
recycling tokens that were meant for a different purpose.

Bug: angleproject:7279
Change-Id: I840e5ea168235c49eec2693b2231c2d329027b0e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4082057
Reviewed-by: Shahbaz Youssefi <[email protected]>
Commit-Queue: Shahbaz Youssefi <[email protected]>
Reviewed-by: Kenneth Russell <[email protected]>
2022-12-09 15:32:37 +00:00
Jamie Madill aaee3c23c1 Build and test ANGLE with Vulkan secondary CBs.
This will allow us to run tests with both permutations of
ANGLE (custom secondaries & Vulkan secondaries) in the same
build directory. It will also allow us to run these configs
as tests on our infra. This CL adds a few simple test to CI.

Bug: angleproject:6811
Change-Id: I053f8cc5bafc2a7ab7d0665da9301f0ba7f8417f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4067806
Reviewed-by: Shahbaz Youssefi <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
2022-12-02 15:46:53 +00:00
Peng Huang 2805e164a6 Fix EGLImage related race condition crash
Bug: chromium:1383195
Change-Id: Ibd74126f19674dad9425d2c8f5b3a217cfd590e4
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4062912
Reviewed-by: Geoff Lang <[email protected]>
Commit-Queue: Peng Huang <[email protected]>
2022-11-29 21:46:19 +00:00
Alexey Knyazev 27727e501a Fix ProvokingVertex typos
Aligned the parameter name with the upstream specs

Moved ValidateProvokingVertexANGLE to validationESEXT.cpp

Bug: angleproject:2829
Change-Id: I820a90c20ef0a1873640c933b1de52526cac7e70
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4043701
Reviewed-by: Jamie Madill <[email protected]>
Reviewed-by: Geoff Lang <[email protected]>
Commit-Queue: Alexey Knyazev <[email protected]>
2022-11-22 22:20:58 +00:00
Alexey Knyazev 44d8fef850 Add ANGLE_provoking_vertex spec
Renamed provoking vertex enums to use _ANGLE suffix.
The newly defined enums alias those from the
desktop OpenGL extensions.

Updated tests to use the new enum names.

Bug: angleproject:2829
Change-Id: I72b686773536d3d54a653114cee5292007510a55
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4013700
Commit-Queue: Alexey Knyazev <[email protected]>
Reviewed-by: Geoff Lang <[email protected]>
Reviewed-by: Kenneth Russell <[email protected]>
2022-11-14 21:51:47 +00:00
Chris Dalton 9bda9a79b4 Add Store Ops to pixel local storage
Browsers will need the ability to pre-empt pixel local storage, which
means every plane will need a backing store to dump to. Store Ops allow
the app to still avoid memory transactions at the end of PLS even if
their plane has a backing texture.

Bug: angleproject:7279
Change-Id: I3a3efa21773f87c03cd346a996e3c638028c68ab
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3974652
Commit-Queue: Chris Dalton <[email protected]>
Reviewed-by: Shahbaz Youssefi <[email protected]>
Reviewed-by: Kenneth Russell <[email protected]>
2022-11-04 23:13:35 +00:00
Chris Dalton 3605b399e0 Move PLS clear values back into context state
The API that required packing raw data into a buffer was un-ergonomic
for developers and difficult to implement for WebGL vendors.

Bug: angleproject:7279
Change-Id: If7c98908c285462c5775e8e2d8811883be139f64
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3972376
Commit-Queue: Chris Dalton <[email protected]>
Reviewed-by: Kenneth Russell <[email protected]>
Reviewed-by: Shahbaz Youssefi <[email protected]>
2022-11-04 00:55:08 +00:00
Chris Dalton 86d9d8768f Finish renaming GL_PIXEL_LOCAL_STORAGE_ACTIVE_PLANES_ANGLE
Fix a couple spots that missed the rename.

Bug: angleproject:7797
Change-Id: Iee44b525f70e00e631e07ec2e984c7a41c3b616a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3996109
Reviewed-by: Steven Noonan <[email protected]>
Commit-Queue: Shahbaz Youssefi <[email protected]>
Reviewed-by: Shahbaz Youssefi <[email protected]>
2022-11-02 13:46:30 +00:00
Chris Dalton 9f693aa383 Implement an allow list for PLS
In order to guarantee no data is lost while using the
EXT_shader_pixel_local_storage extension, we need to restrict
applications to a small subset of commands while pixel local storage is
active. This CL implements the allow list for GL entrypoints using
wildcard matching inside the code generator, and adds custom validation
for the more specific restrictions that go into effect when PLS is
active.

Bug: angleproject:7279
Change-Id: I5dd48bd93c10e8775f32be32a4fcf17855eb2f0e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3932552
Reviewed-by: Kenneth Russell <[email protected]>
Reviewed-by: Shahbaz Youssefi <[email protected]>
Commit-Queue: Chris Dalton <[email protected]>
2022-11-01 16:32:11 +00:00
Jamie Madill dc62b3eef6 Capture/Replay: Add trace interpreter.
Also adds a self-test using the retrace script.

Bug: angleproject:7752
Change-Id: I1985b47250bef99726d2ca2d90bef859208e357e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3965128
Reviewed-by: Cody Northrop <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
Reviewed-by: Yuxin Hu <[email protected]>
2022-10-21 23:12:02 +00:00
Jamie Madill 6193274a52 Capture/Replay: Redesign in-memory call capture replay.
This will allow the replay to use the call captures returned
by the interpreter's parser.

Bug: angleproject:7752
Change-Id: If1b281d9ce7ccfbdc23bea615e1e2258c8a029f9
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3963367
Reviewed-by: Cody Northrop <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
Reviewed-by: Yuxin Hu <[email protected]>
2022-10-21 00:17:51 +00:00
Jamie Madill fd45cec30b Entry Points: Move enum helper to registry_xml.
This will make it accessible to other generators.

Bug: angleproject:7752
Change-Id: I91bc9a4d6c919266ea329f66d271bf881d99d17a
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3963364
Reviewed-by: Yuxin Hu <[email protected]>
Reviewed-by: Cody Northrop <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
2022-10-20 22:27:40 +00:00
Jamie Madill 4bfb749ff2 Capture/Replay: Move shared trace code into src/common.
This will let them be accessible to the test harnesses. The
trace tests interpreter will need direct access to the classes
that we move in this CL.

This CL also moves the GLenum utils into the common folder,
where they were already used by some other tests.

Bug: angleproject:7752
Change-Id: I97ad607938ef29bc316f6d40098478e002ea8128
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3963362
Reviewed-by: Yuxin Hu <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
Reviewed-by: Cody Northrop <[email protected]>
2022-10-20 14:18:58 +00:00
Jamie Madill 8403e4c512 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 <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
Reviewed-by: Yuxin Hu <[email protected]>
2022-10-20 14:11:18 +00:00
Jamie Madill 2265e37bf9 Capture/Replay: Auto-generate EGL capture code.
Replaces the custom code in the EGL stubs. Skips a few "Get"
entry points because this CL doesn't implement pointer capture
like we do for all the GL entry points.

Includes a new state in the AttributeMap that indicates which
type of attribute values we used when initializing the map.

Bug: angleproject:4035
Change-Id: I272eac5e4068602ce710ef66c9a1dce5387943a5
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3949911
Reviewed-by: Yuxin Hu <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
Reviewed-by: Cody Northrop <[email protected]>
2022-10-14 22:25:49 +00:00
Jamie Madill 7c4dc25328 Capture/Replay: Clean up EGL capture.
This switches the EGL capture types to ANGLE-casted pointers since
that's what we receive in the capture layer. Note that even if the
capture layer were used as a pure layer, not an EGL implementation,
we'd still have these types for state tracking.

This also prefixes each EGL class in the entry points with the egl
namespace for consistency and for simplifying the ParamType code.

Required changing to non-const gl::Context * in a few places. Also
changes the gSurfaceMap to be indexed by the raw pointer value,
which cleans up the code somewhat.

Bug: angleproject:4035
Change-Id: Id800c1ba25e5819ac7ea1df8aab806bc393fe192
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3949910
Reviewed-by: Cody Northrop <[email protected]>
Reviewed-by: Yuxin Hu <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
2022-10-14 20:43:53 +00:00
Jamie Madill ad2fbc7da4 Roll third_party/OpenGL-Registry/src/ 11d7b7bae..5bae8738b (5 commits)
Also removes our copy of gl.xml now that upstream patches are merged.

https://chromium.googlesource.com/external/github.com/KhronosGroup/OpenGL-Registry/+log/11d7b7baebfc..5bae8738b23d

$ git log 11d7b7bae..5bae8738b --date=short --no-merges --format='%ad %ae %s'
2022-09-29 sunserega2 [xml] Fixes for defined but unused enum groups (#520)
2022-09-29 julius_hager Added group PixelType to multiple-enums (#529)
2022-09-29 gnl021 EXT_separate_depth_stencil: Explicit unsupported cases (#531)
2022-09-29 jmadill Add enum groups for ANGLE use cases. (#538)
2022-09-29 syoussefi Clarify that PLS doesn't allow leak from outside framebuffer (#540)

Created with:
  roll-dep third_party/OpenGL-Registry/src

Bug: angleproject:6461
Change-Id: I6b7d8471144babe5cdd465c64574804f85c9e4f2
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3937049
Commit-Queue: Jamie Madill <[email protected]>
Auto-Submit: Jamie Madill <[email protected]>
Reviewed-by: Shahbaz Youssefi <[email protected]>
Commit-Queue: Shahbaz Youssefi <[email protected]>
2022-10-07 20:43:23 +00:00
Jamie Madill 5b3781ecff Remove namespacing from all ANGLE loaders.
This will make it easier to work with pure C files.

Bug: angleproject:7731
Change-Id: I2fe9af486af5f339d973c9149f082eb1f2efa8c4
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3925426
Reviewed-by: Cody Northrop <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
2022-10-04 12:16:30 +00:00
Dan Glastonbury d2a58f00af 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 <[email protected]>
Commit-Queue: Kenneth Russell <[email protected]>
Reviewed-by: Quyen Le <[email protected]>
2022-09-23 22:01:09 +00:00
Constantine Shablya e82eaff91f Stubs for paletted images
Bug: angleproject:7599
Change-Id: Idb49f8ba07ebd3b6cad461fa9e90b856af666183
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3909396
Reviewed-by: Shahbaz Youssefi <[email protected]>
Reviewed-by: Cody Northrop <[email protected]>
Commit-Queue: Constantine Shablya <[email protected]>
2022-09-22 16:11:44 +00:00
Dan Glastonbury a89f678f8a 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 <[email protected]>
Reviewed-by: Kenneth Russell <[email protected]>
Reviewed-by: Geoff Lang <[email protected]>
Commit-Queue: Kenneth Russell <[email protected]>
2022-09-21 01:42:23 +00:00
Shahbaz Youssefi de73f7cd7d Introduce GL_ANGLE_logic_op
This extension exposes the desktop GL glLogicOp function as a GLES
extension.  This is supported by Vulkan through the logicOp feature as
well.

The goal is to directly use this extension in GLES1 emulation where the
backend supports it, avoiding a more costly fallback.

Bug: angleproject:3862
Change-Id: I7ed436cdf401437157ca9724168849b4c819b91b
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3898310
Commit-Queue: Shahbaz Youssefi <[email protected]>
Reviewed-by: Amirali Abdolrashidi <[email protected]>
Reviewed-by: Geoff Lang <[email protected]>
2022-09-20 04:02:18 +00:00
Chris Dalton 04f46f391d Reland "Generate stubs for ANGLE_shader_pixel_local_storage"
This is a reland of commit 8208e8a234

In Take 2 we omit the GLenum groups PixelLocalLoadOpANGLE and
PixelLocalInternalFormatANGLE. We can add these back once the extension
is published and we can update Khronos's gl.xml, or else once we figure
out how to make this work without updating the Khronos gl.xml.

Original change's description:
> Generate stubs for ANGLE_shader_pixel_local_storage
>
> Bug: angleproject:7279
> Change-Id: I41548ad35c236b67372a12fecaa9a1b9c556d232
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3891972
> Commit-Queue: Chris Dalton <[email protected]>
> Reviewed-by: Shahbaz Youssefi <[email protected]>

Bug: angleproject:7279
Change-Id: I02f42c1cfc685ed95164744108e0c185d3a7fefb
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3900491
Reviewed-by: Shahbaz Youssefi <[email protected]>
Commit-Queue: Chris Dalton <[email protected]>
2022-09-15 19:44:02 +00:00
Chris Dalton 8c45e3c417 Revert "Generate stubs for ANGLE_shader_pixel_local_storage"
This reverts commit 8208e8a234.

Reason for revert: Compile failures

Original change's description:
> Generate stubs for ANGLE_shader_pixel_local_storage
>
> Bug: angleproject:7279
> Change-Id: I41548ad35c236b67372a12fecaa9a1b9c556d232
> Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3891972
> Commit-Queue: Chris Dalton <[email protected]>
> Reviewed-by: Shahbaz Youssefi <[email protected]>

Bug: angleproject:7279
Change-Id: Ic9a232f9d722b42e615de3827ce118616f3acc71
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3897425
Reviewed-by: Shahbaz Youssefi <[email protected]>
Bot-Commit: Rubber Stamper <[email protected]>
Commit-Queue: Chris Dalton <[email protected]>
Commit-Queue: Shahbaz Youssefi <[email protected]>
Auto-Submit: Chris Dalton <[email protected]>
2022-09-15 02:15:31 +00:00
Chris Dalton 8208e8a234 Generate stubs for ANGLE_shader_pixel_local_storage
Bug: angleproject:7279
Change-Id: I41548ad35c236b67372a12fecaa9a1b9c556d232
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3891972
Commit-Queue: Chris Dalton <[email protected]>
Reviewed-by: Shahbaz Youssefi <[email protected]>
2022-09-14 21:37:50 +00:00
Eddie Hatfield 3960e63b1a 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 <[email protected]>
Reviewed-by: Geoff Lang <[email protected]>
Reviewed-by: Cody Northrop <[email protected]>
Commit-Queue: Cody Northrop <[email protected]>
2022-09-02 18:46:02 +00:00
Jamie Madill 64f41972a9 Use canonical gl.xml and update enum to string function.
This replaces our copy of gl.xml with the upstream canonical copy.
Note that one patch is required before we can remove ANGLE's copy:

https://github.com/KhronosGroup/OpenGL-Registry/pull/538

Because the upstream version uses a new method of enum groups, we
also update our enum-to-string generator to use the new groups.
This new code includes many more enums and groups in the mapping.

Bug: angleproject:6461
Change-Id: I1c0ab44c36afce8db04c9661b377bbe5762c913e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3856649
Reviewed-by: Shahbaz Youssefi <[email protected]>
Reviewed-by: Jonah Ryan-Davis <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
2022-08-29 20:29:27 +00:00
Mohan Maiya 2d48a37079 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 <[email protected]>
Reviewed-by: Ian Elliott <[email protected]>
Reviewed-by: Shahbaz Youssefi <[email protected]>
2022-08-26 22:29:35 +00:00
Eddie Hatfield 98d5db7063 Add capture functions for desktop GL entry points
The parameter capture functions are left unimplemented for now.

Bug: angleproject:7533
Change-Id: Ief356e7401805cf9b417e1f5cc3790011237e03f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3858618
Reviewed-by: Jamie Madill <[email protected]>
Reviewed-by: Cody Northrop <[email protected]>
Commit-Queue: Eddie Hatfield <[email protected]>
2022-08-26 20:19:45 +00:00
Jamie Madill f6842cc2cd Revert override for desktop GL extensions in gl.xml.
Instead override the supported APIs in registry_xml.py, which
will transfer to using the canonical gl.xml. Note these are
desktop-GL-only extensions that ANGLE exposes in GLES:

GL_ARB_sync
GL_NV_robustness_video_memory_purge

Bug: angleproject:6461
Change-Id: I25778149ecfc3cb4be0aca2104c08273c260c564
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3856648
Reviewed-by: Shahbaz Youssefi <[email protected]>
Reviewed-by: Jonah Ryan-Davis <[email protected]>
Commit-Queue: Shahbaz Youssefi <[email protected]>
Auto-Submit: Jamie Madill <[email protected]>
2022-08-25 20:23:05 +00:00
Jamie Madill 5d62c05e26 Use canonical Khronos registry XML files for auto-gen.
This switches ANGLE to use the upstream XML files for the CL, EGL
GLX and WGL APIs. Since gl.xml has a few more significant diffs
from the upstream version, that work will come in another CL.

This also removes an ANGLE EGL ext that was added upstream.

Bug: angleproject:6461
Change-Id: I29ead5edc13a4256d1f702c330a5d3d233502cd4
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3854318
Reviewed-by: Shahbaz Youssefi <[email protected]>
Reviewed-by: Jonah Ryan-Davis <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
2022-08-25 17:35:24 +00:00
Eddie Hatfield d89c027e7c Add unimplemented GLX entry points to desktop GL
Test: Run glxgears and hit unimplemented in ANGLE

Bug: angleproject:7533
Change-Id: Ic7ed7506b6d0c5ef5022ae6899cbd6c4d351b178
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3852631
Reviewed-by: Geoff Lang <[email protected]>
Commit-Queue: Eddie Hatfield <[email protected]>
Reviewed-by: Cody Northrop <[email protected]>
2022-08-24 21:26:01 +00:00
Eddie Hatfield c54ed79053 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 <[email protected]>
Commit-Queue: Eddie Hatfield <[email protected]>
Reviewed-by: Geoff Lang <[email protected]>
2022-08-03 22:17:47 +00:00
Peng Huang b78d471aea Add angle_enable_share_context_lock build flag
This flags can be used to enable the share context lock.
Without this lock, the client need to use gl calls in
a threadsafe way. It is true by default.

Bug: chromium:1336126
Change-Id: I984f8cfb0379195f6ebe11b0997e401f2421affa
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3780582
Reviewed-by: Geoff Lang <[email protected]>
Commit-Queue: Peng Huang <[email protected]>
2022-07-21 19:04:00 +00:00
Chris Dalton 15cc001307 Add a GL_ANGLE_shader_pixel_local_storage extension
Plumbs through "GL_ANGLE_shader_pixel_local_storage" and
"GL_ANGLE_shader_pixel_local_storage_coherent" extension strings
advertised by ANGLE and stubs out an initial spec document. This change
doesn't add any new procedures or shader constructs, but it does allow
the PLS tests to start checking for the real extension strings and
requiring the GL_ANGLE_shader_pixel_local_storage extension.

Bug: angleproject:7279
Change-Id: I36877fe4117185a2121f803288123cd69a447cf3
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3739590
Reviewed-by: Shahbaz Youssefi <[email protected]>
Reviewed-by: Kenneth Russell <[email protected]>
Commit-Queue: Chris Dalton <[email protected]>
2022-07-15 20:39:03 +00:00
Faye Zhang 714f680f7b Implement GL_EXT_base_instance
* Added the validation functions for
DrawElementsInstancedBaseVertexBaseInstance(),
DrawElementsInstancedBaseInstance(), and
DrawArraysInstancedBaseInstance() according to the specs.
* Added generic implementation for
glDrawElementsInstancedBaseInstance() that can
be called by back-ends.
* Added flags for back-ends so they can enable the extension.
* Added tests for DrawElementsInstancedBaseVertexBaseInstance(),
glDrawElementsInstancedBaseInstance(), and
DrawArraysInstancedBaseInstance().
* Disabled ES3_D3D11__DynamicDraw tests due to
angleproject:7441 bug.

Bug: angleproject:6983
Bug: angleproject:7441
Change-Id: Ia664b01c87bc64c05e29adec23a8f80792eaa037
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3697206
Reviewed-by: Amirali Abdolrashidi <[email protected]>
Commit-Queue: Faye Zhang <[email protected]>
Reviewed-by: Yuxin Hu <[email protected]>
2022-06-21 20:42:38 +00:00
Constantine Shablya b257d62cdf Add GL_NV_read_depth_stencil
Bug: angleproject:4688
Change-Id: I44d5846f1ae5382b8c046e59643da4c0bf38e135
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3702356
Commit-Queue: Shahbaz Youssefi <[email protected]>
Auto-Submit: Constantine Shablya <[email protected]>
Reviewed-by: Shahbaz Youssefi <[email protected]>
2022-06-15 03:44:55 +00:00
Faye Zhang 06ff0e3cb0 Implement GL_EXT_base_instance
Added new extension GL_EXT_base_instance to registry_xml.py
and auto-generated the entry point function calls for the
following functions introduced by the extension:
* GL_DrawElementsInstancedBaseVertexBaseInstanceEXT
* GL_DrawElementsInstancedBaseInstanceEXT
* GL_DrawArraysInstancedBaseInstanceEXT

Bug: angleproject:6983
Change-Id: I36167faf3ca98e42acf787dbf09ee7052e15e358
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3691952
Reviewed-by: Amirali Abdolrashidi <[email protected]>
Commit-Queue: Faye Zhang <[email protected]>
Reviewed-by: Yuxin Hu <[email protected]>
2022-06-07 23:58:38 +00:00
Jamie Madill 389ae6b9ae Add extension for read-only DS feedback loops.
This will facilitate testing. Also moves some feedback loop tests
from FramebufferTest to a specialized test class.

Bug: angleproject:4778
Bug: angleproject:4969
Change-Id: I61235f2663a58644bf506254a869f550f1706de3
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3634726
Reviewed-by: Shahbaz Youssefi <[email protected]>
Reviewed-by: Geoff Lang <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
2022-05-12 16:23:31 +00:00
Gert Wollny 66b9214fbb Capture/Replay: rename ANGLE_CAPTURE to ANGLE_CAPTURE_GL
In addition gunning "git cl format" on the current tree resulted
in additional changes.

Bug: angleproject:4964
Change-Id: I3df4888aef763d06f91227409dbd943d0d25689e
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3634699
Reviewed-by: Cody Northrop <[email protected]>
Commit-Queue: Cody Northrop <[email protected]>
Reviewed-by: Jamie Madill <[email protected]>
2022-05-10 16:31:06 +00:00
Mohan Maiya ea76cb0f5e Vulkan: Add entry points for GL_QCOM_shading_rate
Bug: angleproject:7172
Change-Id: I837d2697d95c44f47a2fab7411cfd87a4ec65e90
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3599873
Reviewed-by: Shahbaz Youssefi <[email protected]>
Reviewed-by: Jamie Madill <[email protected]>
Commit-Queue: mohan maiya <[email protected]>
2022-04-25 18:24:55 +00:00
Steven Noonan fb093278c1 egl_angle_ext: add more missing extension enum values
I was going to do this bit-by-bit, but there are just too many of them,
so I'm lumping as many of these enums into one commit as I can.

I basically went through all the extensions/EGL_* files and found all
the enum definitions there and added them to the xml.

Bug: angleproject:7193
Change-Id: Idaffd283e9118abf84bdff9c4e140334a1f8ee06
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3582939
Reviewed-by: Jamie Madill <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
2022-04-12 14:52:48 +00:00
Steven Noonan 19582d1201 gl_angle_ext.xml: treat glProvokingVertexANGLE as alias
This allows an OpenGL loader to alias glProvokingVertex and
glProvokingVertexANGLE function pointers. In my case, it helps with
the GLAD loader when using the --alias option.

Bug: angleproject:7193
Change-Id: Id7e6318a5ee1f1b172f0499fc01dd080442471b6
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3582519
Reviewed-by: Jamie Madill <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
2022-04-12 14:36:18 +00:00
Steven Noonan a201bbc982 egl_angle_ext.xml: add missing enums and typedefs
This is necessary for a loader like GLAD to generate a correct egl.h
header with ANGLE extensions.

Bug: angleproject:7193
Change-Id: Id3f07ffee216890418b202520fccff7ccfcaa6dd
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3582273
Reviewed-by: Jamie Madill <[email protected]>
Commit-Queue: Jamie Madill <[email protected]>
2022-04-11 21:45:08 +00:00
Steven Noonan fb91e27cfb add GL_ANGLE_robust_resource_initialization extension to xml
Bug: angleproject:7165
Change-Id: I17a566714bc3e1a0e19dee4bdea10c7360050172
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3567539
Reviewed-by: Jamie Madill <[email protected]>
Reviewed-by: Geoff Lang <[email protected]>
Commit-Queue: Geoff Lang <[email protected]>
2022-04-11 20:04:48 +00:00
Kimmo Kinnunen 9637185c3d 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 <[email protected]>
Reviewed-by: Kenneth Russell <[email protected]>
Commit-Queue: Kenneth Russell <[email protected]>
2022-03-19 01:15:06 +00:00
Shahbaz Youssefi 3ddb21fd6d Front-end support for KHR_blend_equation_advanced
Bug: angleproject:3586
Change-Id: I27086295e7455ce8848db1c6004917fea40202e8
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3484785
Reviewed-by: Jamie Madill <[email protected]>
Reviewed-by: Charlie Lao <[email protected]>
Commit-Queue: Shahbaz Youssefi <[email protected]>
2022-03-17 03:09:11 +00:00