src/libANGLE/renderer/vulkan/vk_caps_utils.cpp


Log

Author Commit Date CI Message
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>
Geoff Lang 0b651e42 2021-07-20T11:48:38 Vulkan/D3D11/Metal: Expose GL_NV_framebuffer_blit GL_NV_framebuffer_blit is equivalent to ES3 blit which these backends support. Bug: chromium:1220246 Change-Id: I6ef0b80f9e9ba7828d6720cdbe19c83c4abdc4cf Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3041878 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Brandon Schade 217acac2 2021-07-21T12:42:56 Vulkan: Add support for EXT_primitive_bounding_box 1. Added support for EXT_primitive_bounding_box extension 2. Renamed shader variable gl_BoundingBoxEXT[] to ANGLEBoundingBox[] Bug: angleproject:3576 Test: dEQP-GLES31.functional.primitive_bounding_box.* Change-Id: I15fa9af50c6fd8e86d225670ddd8eb39f6e65d35 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3053618 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@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>
Shahbaz Youssefi a8807cbf 2021-07-17T00:00:27 Vulkan: SPIR-V Gen: Support interpolateAt* The interpolateAt* builtins take their first argument as a pointer, so only the OpAccessChain result should be given to the corresponding SPIR-V instruction. A test is written in this change to handle interpolateAt* when given a swizzled lvalue, which is not representable in SPIR-V. This can be supported by having the AST transform: interpolateAtX(value.zy) to: interpolateAtX(value).zy which can be done right when the function is parsed and the AST node for it is created (by taking the swizzle out of the parameter and applying it to the node). However, swizzled lvalues as parameter to interpolateAt* is only allowed in desktop GLSL, and so the test is disabled. From the GLSL ES3.2 spec: > Component selection operators (e.g. .xy) may not be used when > specifying interpolant. Bug: angleproject:4889 Change-Id: I043969f22011e6171c7ae225ded3a5013e8cfa4e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3035588 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Mohan Maiya 5c8bf081 2021-06-08T13:12:24 Vulkan: Add support for YUV internal format extension 1. Add a function to upload YUV image data to textures 2. Modify stageSubresourceUpdate method to account for YUV images 3. Create VkSamplerYcbcrConversion when initializing ImageHelper 4. Update hasImmutableSampler to account for native YUV format support 5. Skip initializeNonZeroMemory for YUV formats Bug: angleproject:5773 Test: Texture2DTestES3.TexStorage2D*Yuv*Vulkan* Change-Id: I270f04bbf903cf2bf19f100eb95f32953d491c39 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2947767 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi d6202fce 2021-06-28T16:53:45 Vulkan: Disable GL_KHR_texture_compression_astc_sliced_3d 3D ASTC formats are not supported in Vulkan, sliced or not. The non-sliced extension is already disabled, and this change disables the sliced version. Bug: angleproject:6038 Change-Id: I055838345ccb8ad77fe4c05e65dd8b10a8a4d36b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2993459 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 5b314268 2021-06-15T17:37:45 Vulkan: Support OVR_multiview and OVR_multiview2 Multiview is supported in Vulkan simply by specifying the number of views in the render pass, and creating the appropriate image views. A number of changes to the way image views and render targets are stored are made to support those that don't cover the entire range of layers. One particular detail that is not implemented in this change is the use of queries in combination with multiview. Vulkan specifies that N queries are actually produced (N being the number of views) which must be summed by the application, but this is not currently done. Bug: angleproject:6048 Change-Id: I1d4a9894c232d3a93d7a97c9fa0eedc334e57469 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2967625 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Charlie Lao <cclao@google.com>
Cody Northrop 851fbedb 2021-06-10T21:27:01 Vulkan: Switch viewport and scissor to dynamic state Heavily based on http://crrev/c/1316888 Some apps are creating a large number of viewport combinations and are running out of graphics memory. This CL drops their graphics pipeline use from tens of thousands to tens. Performance testing shows little impact to application traces. Bug: b/190026813 Bug: angleproject:3143 Change-Id: Ib7415be1128f8fedae4a7ca72e067b2815201223 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2954925 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Brandon Schade 69f2fb00 2021-03-08T10:49:31 Vulkan: Expose OES_geometry_shader extension Modify the symbol table generation script to accept a list of supported extensions. This allows for the EXT and OES versions of the geometry shader extension to be exposed. Test: angle_deqp_khr_gles31_tests --deqp-case=*geometry_shader* Bug: angleproject:3571 Change-Id: Ia7127a03dbd3fce78957f0505d3ce0c9bab6cb15 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2765011 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya e697e379 2021-03-10T23:59:45 Vulkan: Allow certain usecases to have non-zero stride When glVertexAttribPointer is called with a type parameter that doesn't match the vertex attribute binding's type in shader, the vulkan backend used to force the stride to 0. This is acceptable since this usecase is unspecified in spec. To allow for better app compatibility, introduce a new extension that requires normal glVertexAttribPointer functionality to be maintained if the mismatched vertex attribute type is a mismatched integer type sign. This change also modifies the VkFormat used when a mismatch in signedness occurs to use a VkFormat with the same component width as the type parameter. Bug: angleproject:5762 Test: VertexAttributeTestES3.DrawWithRelaxedVertexAttributeType* Test: VertexAttributeTestES3.DrawWithMismatchedComponentCount* Change-Id: I7e5281500afc3d77f0775821447cabfad3ff2d66 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2765012 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Mohan Maiya dd312cc6 2021-05-21T08:49:48 Reland "Vulkan: Add support for EXT_texture_border_clamp" This is a reland of 4b92e089c01e94730fe26c4c743d76d6c935088d Initializes mPadding to 0 in SamplerDesc::update Original change's description: > Vulkan: Add support for EXT_texture_border_clamp > Add support for GL_EXT_texture_border_clamp. This is implemented by > using VK_EXT_custom_border_color. > > Bug: angleproject:3577 > Test: dEQP-GLES31.functional.texture.border_clamp* > Change-Id: Ie9fa1eb5dd03b997b5ae182787641a53080a9e51 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2830192 > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> > Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Bug: angleproject:3577 Change-Id: I8684242c4bce6e1a006dbe926defaa495fcc2282 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2911571 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Yuly Novikov 44fabb7b 2021-05-21T00:51:06 Revert "Vulkan: Add support for EXT_texture_border_clamp" This reverts commit 4b92e089c01e94730fe26c4c743d76d6c935088d. Reason for revert: breaks "Linux MSan Tests" bot https://ci.chromium.org/ui/p/chromium/builders/ci/Linux%20MSan%20Tests/28489/overview Original change's description: > Vulkan: Add support for EXT_texture_border_clamp > > Add support for GL_EXT_texture_border_clamp. This is implemented by > using VK_EXT_custom_border_color. > > Bug: angleproject:3577 > Test: dEQP-GLES31.functional.texture.border_clamp* > Change-Id: Ie9fa1eb5dd03b997b5ae182787641a53080a9e51 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2830192 > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> > Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Bug: angleproject:3577, angleproject:5996 Change-Id: I6b62f1a4a43fcfe2d0df2c73de24db83606ce430 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2911533 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Mohan Maiya 4b92e089 2021-05-12T09:20:24 Vulkan: Add support for EXT_texture_border_clamp Add support for GL_EXT_texture_border_clamp. This is implemented by using VK_EXT_custom_border_color. Bug: angleproject:3577 Test: dEQP-GLES31.functional.texture.border_clamp* Change-Id: Ie9fa1eb5dd03b997b5ae182787641a53080a9e51 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2830192 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Alexey Knyazev 835bcb1e 2021-05-08T13:24:58 Vulkan: Support GL_EXT_texture_sRGB_RG8 For completeness, added mappings of R8_SRGB and R8G8_SRGB to OpenGL and Metal. Bug: angleproject:4932 Change-Id: Ic8e44e3a94c114e985f6965fcd43fbcb8071432d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2880661 Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Ian Elliott b0c217ba 2021-05-13T13:56:27 Disable GL_EXT_shader_framebuffer_fetch_non_coherent on Arm/QCOM Thie is a shorter-term work-around to games not checking extensions properly. Bug: b/177320565 Bug: b/186643966 Bug: b/186783762 Change-Id: Ic348396db1d081925cd9747cdd9406f5929313b9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2894407 Reviewed-by: Charlie Lao <cclao@google.com> Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Ian Elliott <ianelliott@google.com>
Shahbaz Youssefi 99beb97a 2021-05-03T16:54:11 Vulkan: Fix MAX_VERTEX_OUTPUT_COMPONENTS limit gl_Position is excepted from contributing to MAX_VARYING_VECTORS, which is taken into account when calculating this limit based on Vulkan limits (which don't have such an exception). This exception was mistakenly also being applied to other limits such as MAX_VERTEX_OUTPUT_COMPONENTS. Bug: angleproject:5916 Change-Id: I394761efa02d3093741d2bff21023daf997e5e69 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2869145 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Brandon Schade 5af6306a 2021-03-31T23:23:52 Vulkan: Update layer provoking vertex for geometry shaders Set the GS layer provoking vertex value to GL_LAST_VERTEX_CONVENTION if the provoking vertex extension is enabled. Otherwise, use GL_FIRST_VERTEX_CONVENTION as vulkan follows this convention for provoking vertex. Tests: dEQP-GLES31.functional.geometry_shading.layered.layer_provoking_vertex_* Bug: angleproject:5452 Change-Id: Ie385f3b713486c54114dbfcefd799d180701bb60 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2799033 Commit-Queue: Brandon Schade <b.schade@samsung.com> Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 776c6015 2021-02-26T00:00:57 Vulkan: Call glslang at compile time With this change, the ANGLE translator immediately compiles the generated GLSL into SPIR-V with glslang and discards the source. This is in preparation for generating SPIR-V directly, by making the frontend and backend already able to digest it. This change also allows the expensive glslang calls to be parallelized, improving the following perf test by about 20%: LinkProgramBenchmark.Run/vulkan_compile_and_link_multi_thread Previously, the test was run as such in the Vulkan backend: Main Thread 1 Thread 2 Compile1 ---> Compile2 ---------------------> Translator Translator <--- <--------------------- Link glslang for shader1 glslang for shader2 Done With this change, it is run as such: Main Thread 1 Thread 2 Compile1 ---> Compile2 ---------------------> Translator Translator glslang glslang <--- <--------------------- Link Done glslang_wrapper_utils no longer interacts with glslang! A rename will follow. Bug: angleproject:4889 Change-Id: If4303e8ba0ba43b1a2f47f8c0a9133d0bee1a19a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2721195 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Mohan Maiya f28d63e9 2021-03-24T11:14:24 Vulkan: Enable glBlitFramebuffer for EXT_sRGB_write_control Implements support for the glBlitFramebuffer edge case in the EXT_sRGB_write_control spec, and fully exposes this extension. Bug: angleproject:5075 Test: SRGBFramebufferTest*.*Vulkan* Change-Id: I05f044abbc5cb272825d1fc4b9028217f18e63c2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2785641 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Jamie Madill 716b2cba 2021-03-12T14:46:53 Use bitset masks for active shader buffers. This switches the tracking for the uniform, shader storage, and atomic counter buffers to use bitset masks to determine where there are active buffers. This will make iterating these buffer sets faster. Also renames the limit for atomic counter buffers to be consistent with the other buffer types. Also applies the implementation limit to atomic counter buffer bindings. This fixes out-of-bounds access on some Linux platforms that expose a large number of bindings. Bug: angleproject:5736 Change-Id: Ice801645697592d1dda6aebf0cb69767594cc0c5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2757509 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Mohan Maiya 81dcf078 2021-03-08T11:21:31 Reland "Vulkan: Support EXT_sRGB_write_control" This is a reland of 6073af536cf627742696823edc82c9b0a481a8bc with 2 changes - 1. Don't enable the extension even in nonConformant mode 2. Don't enable VK_KHR_image_format_list for swiftshader Original change's description: > Vulkan: Support EXT_sRGB_write_control > > Implement support for EXT_sRGB_write_control. This extension > requires VK_KHR_image_format_list to be supported. > > The spec requires this functionality to work with glBlitFramebuffer > as well but support for that will be added in a follow up change. > As such, this extension is only exposed in non-conformant mode. > > Bug: angleproject:5075 > Tests: SRGBFramebufferTest.*Vulkan* > Change-Id: I59b38f6cd810a3d0d67ec29f4f19c25f65f70862 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2617243 > Commit-Queue: Mohan Maiya <m.maiya@samsung.com> > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Bug: angleproject:5075 Change-Id: I8e149d196a39c3c4769bfa8690792f3c53831299 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2762647 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Alexey Knyazev b7fc9518 2021-03-08T03:55:36 Do not expose emulated ETC1 textures to WebGL Add a new "emulatedEtc1" limitation. Bug: chromium:1048244 Change-Id: Ia04746773db3ad75781a8adfda988d36bd2c57f7 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2718865 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
Peng Huang b27740f3 2021-03-09T16:15:15 Revert "Vulkan: Support EXT_sRGB_write_control" This reverts commit 6073af536cf627742696823edc82c9b0a481a8bc. Reason for revert: crbug.com/1186140 Original change's description: > Vulkan: Support EXT_sRGB_write_control > > Implement support for EXT_sRGB_write_control. This extension > requires VK_KHR_image_format_list to be supported. > > The spec requires this functionality to work with glBlitFramebuffer > as well but support for that will be added in a follow up change. > As such, this extension is only exposed in non-conformant mode. > > Bug: angleproject:5075 > Tests: SRGBFramebufferTest.*Vulkan* > Change-Id: I59b38f6cd810a3d0d67ec29f4f19c25f65f70862 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2617243 > Commit-Queue: Mohan Maiya <m.maiya@samsung.com> > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Bug: angleproject:5075,chromium:1186140 Change-Id: Ib0d4d60fe7434fb950f99db2c210aab9af7d2d0e No-Presubmit: true No-Tree-Checks: true No-Try: true Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2743663 Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com> Commit-Queue: Peng Huang <penghuang@chromium.org>
Mohan Maiya 6073af53 2021-03-08T11:21:31 Vulkan: Support EXT_sRGB_write_control Implement support for EXT_sRGB_write_control. This extension requires VK_KHR_image_format_list to be supported. The spec requires this functionality to work with glBlitFramebuffer as well but support for that will be added in a follow up change. As such, this extension is only exposed in non-conformant mode. Bug: angleproject:5075 Tests: SRGBFramebufferTest.*Vulkan* Change-Id: I59b38f6cd810a3d0d67ec29f4f19c25f65f70862 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2617243 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya 550f2a3e 2021-02-24T09:49:42 Vulkan: Shader support for EXT_shader_framebuffer_fetch_non_coherent Translator can accept gl_LastFragData and 'inout' variable to gain access to framebuffer attachment data. The Vulkan translator replaces it with the SubpassInput type variable. Note that this works only for the noncoherent version of the extension. Bug: angleproject:5454 Test: *EXTShaderFramebufferFetchNoncoherent*.* Change-Id: I392f84ee3ad3eb9fbd09d0b7ff83731a9a3f33f6 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2598060 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Mohan Maiya 907a3cee 2021-02-17T08:07:45 Vulkan: Add support for EXT_shader_framebuffer_fetch_non_coherent EXT_shader_framebuffer_fetch_non_coherent is implemented using subpass input attachments. The extension will be enabled in a follow up change that adds required changes to the Vulkan translator. Bug: angleproject:5454 Test: FramebufferFetchNonCoherentES31.*Vulkan Change-Id: Ic73c66a476c4a21db5269431166a198841f1dc0c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2598059 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Alexis Hetu 18a5e7a6 2021-02-04T11:19:21 Enable packing extensions for the Vulkan backend The following extensions are ES2 extensions which become core in ES3: - EXT_unpack_subimage - NV_pack_subimage Since the Vulkan backend already fully supports ES3, it should be ok to enable these for ES2 contexts. This fixes all YUV related viz_unittests failures when using SwANGLE with the passthrough command decoder. Bug: chromium:1060139 Change-Id: I24ffd7a58f576799b93fe91e6be4032ca3175eda Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2676201 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Alexis Hétu <sugoi@chromium.org>
Brandon Schade 6cc845bb 2020-12-07T18:14:50 Vulkan: Add support for EXT_blend_func_extended This implementation utilizes vulkan's dualSrcBlend feature. Expose this extension if the underlying vulkan backend allows the use of this feature. Test: angle_end2end_tests --gtest_filter=EXTBlendFuncExtendedDrawTest* Bug: angleproject:5074 Change-Id: I7d2f611df89d65e5cac35158cb5f41a0ebd58aae Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2593151 Commit-Queue: Brandon Schade <b.schade@samsung.com> Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 61f60161 2021-01-27T13:57:13 Vulkan: Set missing geometry/tessellation limits Bug: angleproject:5557 Bug: angleproject:5579 Change-Id: Idb8ebc0c3beee8f273d0df3b4e0d84722a8590b2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2653912 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Mohan Maiya 37a0dced 2021-01-28T17:52:05 Vulkan: Disable clip space transform based on EXT_clip_control When depth is set to "ZERO_TO_ONE_EXT" using EXT_clip_control API, don't transform the z position in shader since it now matches Vulkan's depth range. Toggle transformPositionToVulkanClipSpace accordingly. Bug: angleproject:5471 Tests: dEQP-GLES2.functional.clip_control.depth_mode_zero_to_one Change-Id: I7e715cb3c98cecf5aaa5cdc3822a3a83bae9c720 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2615864 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi c51c3548 2021-01-19T14:15:54 Vulkan: Unconditionally expose OES_shader_io_blocks All relevant tests pass, so no longer conditioned to exposeNonConformantExtensionsAndVersions. Bug: angleproject:3580 Change-Id: I9b398bd962831fabf0ec39ad9aad3b200717d087 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2636687 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi ea71c6b6 2021-01-12T14:13:35 Vulkan: Emulate R32F images with R32UI GL requires that imageAtomicExchange be supported for r32f formats. However VK_FORMAT_FEATURE_STORAGE_*_ATOMIC_BIT is nearly unsupported everywhere without some Vulkan extension that brings in unnecessary support. This GL feature is emulated by transforming the shader to use r32ui for all images that originally specified r32f. floatToUintBits and uintBitsToFloat is used to maintain correct usage of the image* builtin functions. Bug: angleproject:5535 Change-Id: Ie607089935d3283b3ffa054f4b4385b81fb8f53d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2635453 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Shahbaz Youssefi 186fe990 2021-01-15T15:49:30 Vulkan: Redo RewriteAtomicCounters With MonomorphizeUnsupportedFunctionsInVulkanGLSL and RewriteArrayOfArrayOfOpaqueUniforms transformations run, it is no longer possible to encounter array of array of atomic counters, or have any passed to functions. As a result, RewriteAtomicCounters is greatly simplified. Additionally, it is no longer necessary to pass binding/offset information for atomic counters around and they can use constants. This change removes dependency on the shaderStorageBufferArrayDynamicIndexing Vulkan feature. Bug: angleproject:3726 Bug: angleproject:3881 Change-Id: Ia43092a668f60d009eccbbceeed5deaf105a5895 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2633687 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill b912eec5 2020-11-27T11:08:41 Vulkan: Support GL_EXT_tessellation_shader. Shader translator changes done in http://crrev.com/c/2633936 Adds a new DIRTY_BIT_PATCH_VERTICES state to Context. Supportes state query and transform feedback. 4 test suppressions remain as follow-up fixes. Adds a new varying packing mode for a simple Vulkan rule set. Based on work by Mohan Maiya (m.maiya@samsung.com). Test: dEQP-GLES31.functional.tessellation.* Bug: angleproject:3572 Change-Id: I4cad2cca30adb754fd12c83027673906541f566a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2568234 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Mohan Maiya <m.maiya@samsung.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 6c5b766b 2021-01-16T11:33:00 Reland "Vulkan: Generate xfb support code in SPIR-V for extension path" This reverts commit d090627616641f7524655627bfd415de6f8af942. Reason for revert: Fixed parent CL Original change's description: > Revert "Vulkan: Generate xfb support code in SPIR-V for extension path" > > This reverts commit d06feeac1e79d6102e01c123a360bc9099d5bba3. > > Reason for revert: > Earlier CL breaks pre-rotation: > https://chromium-review.googlesource.com/c/angle/angle/+/2598584 > > Original change's description: > > Vulkan: Generate xfb support code in SPIR-V for extension path > > > > The only piece of code that's needed to be generated for the extension > > path is the following, at the right spot (right before depth correction > > and pre-rotation): > > > > ANGLEXfbPosition = gl_Position; > > > > The SPIR-V transformer already has gl_Position loaded for depth > > correction and pre-rotation, so this change simply adds an OpStore to > > ANGLEXfbPosition. > > > > As a result of this change, @@ XFB-OUT @@ is no longer emitted if > > the transform feedback extension is supported. With the above code now > > placed correctly for geometry shaders, transform feedback tests for > > geometry shaders are enabled. > > > > Bug: angleproject:3606 > > Change-Id: I13a7956ab62a1a6b4196ff999442b99b50226c0f > > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2617659 > > Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> > > Reviewed-by: Charlie Lao <cclao@google.com> > > Reviewed-by: Jamie Madill <jmadill@chromium.org> > > TBR=syoussefi@chromium.org,jmadill@chromium.org,cclao@google.com > > Change-Id: I74fa9fafe3c922cdb7cd09ee6351534e38528da9 > No-Presubmit: true > No-Tree-Checks: true > No-Try: true > Bug: angleproject:3606 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2634048 > Reviewed-by: Tim Van Patten <timvp@google.com> > Commit-Queue: Tim Van Patten <timvp@google.com> TBR=timvp@google.com,syoussefi@chromium.org,jmadill@chromium.org,cclao@google.com # Not skipping CQ checks because this is a reland. Bug: angleproject:3606 Change-Id: Ic49a0be10cdb58e2b47896554f272093e24f93b4 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2633711 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Tim Van Patten d0906276 2021-01-16T00:11:27 Revert "Vulkan: Generate xfb support code in SPIR-V for extension path" This reverts commit d06feeac1e79d6102e01c123a360bc9099d5bba3. Reason for revert: Earlier CL breaks pre-rotation: https://chromium-review.googlesource.com/c/angle/angle/+/2598584 Original change's description: > Vulkan: Generate xfb support code in SPIR-V for extension path > > The only piece of code that's needed to be generated for the extension > path is the following, at the right spot (right before depth correction > and pre-rotation): > > ANGLEXfbPosition = gl_Position; > > The SPIR-V transformer already has gl_Position loaded for depth > correction and pre-rotation, so this change simply adds an OpStore to > ANGLEXfbPosition. > > As a result of this change, @@ XFB-OUT @@ is no longer emitted if > the transform feedback extension is supported. With the above code now > placed correctly for geometry shaders, transform feedback tests for > geometry shaders are enabled. > > Bug: angleproject:3606 > Change-Id: I13a7956ab62a1a6b4196ff999442b99b50226c0f > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2617659 > Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> > Reviewed-by: Charlie Lao <cclao@google.com> > Reviewed-by: Jamie Madill <jmadill@chromium.org> TBR=syoussefi@chromium.org,jmadill@chromium.org,cclao@google.com Change-Id: I74fa9fafe3c922cdb7cd09ee6351534e38528da9 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: angleproject:3606 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2634048 Reviewed-by: Tim Van Patten <timvp@google.com> Commit-Queue: Tim Van Patten <timvp@google.com>
Mohan Maiya cea86910 2021-01-14T08:13:00 Vulkan: Support EXT_clip_cull_distance extension EXT_clip_cull_distance extension is supported except for some features related to EXT_tessellation_shader and EXT_geometry_shader. Also added a few compiler tests to validate the transformation from ESSL to GLSL for Vulkan backend. Bug: angleproject:5458 Tests: angle_end2end_tests --gtest_filter=Clip*DistanceTest* angle_unittests --gtest_filter=*Clip*Distance* Change-Id: Ie74e6b2b55112ad92ad111191d629b63506032ab Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2585987 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Shahbaz Youssefi d06feeac 2021-01-08T00:48:18 Vulkan: Generate xfb support code in SPIR-V for extension path The only piece of code that's needed to be generated for the extension path is the following, at the right spot (right before depth correction and pre-rotation): ANGLEXfbPosition = gl_Position; The SPIR-V transformer already has gl_Position loaded for depth correction and pre-rotation, so this change simply adds an OpStore to ANGLEXfbPosition. As a result of this change, @@ XFB-OUT @@ is no longer emitted if the transform feedback extension is supported. With the above code now placed correctly for geometry shaders, transform feedback tests for geometry shaders are enabled. Bug: angleproject:3606 Change-Id: I13a7956ab62a1a6b4196ff999442b99b50226c0f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2617659 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Charlie Lao <cclao@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill d654ac9b 2020-12-30T12:28:41 Program: Support multiple varying packings. Instead of using a single varying packing for all program stages, we switch to using a varying register packing for each pair of input/output shaders. This allows several valid use cases that use many varying to succeed. For instance Geometry Shaders have both an input and output varying packing. With tessellation shaders the upper bound of valid varying packings in one Program goes up even more. We keep multiple varying packings at once inside a new "ProgramVaryingPacking" class. Internally the class keeps a unique varying mapping for each input/output interface in the program. Separable programs with "open" interfaces are handled specially. Fixes a bug where varying counting was artificially limited for programs with more than two shaders. This CL also disables GS support when we're emulating line raster so we don't have to figure out the details on how to place the special position varying. Bug: angleproject:5496 Change-Id: I1f9a327c4750caef570c608d86953e9d0cc5eea3 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2606532 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Cody Northrop d38b9f86 2020-12-02T09:20:09 Allow GL_OES_shader_image_atomic when non-conformant On Android, force allowing it with: adb shell setprop debug.angle.feature_overrides_enabled \ exposeNonConformantExtensionsAndVersions If enabling multiple features, switch to using settings which don't have a character limit, but persist across reboots: adb shell settings put global angle_egl_features \ exposeNonConformantExtensionsAndVersions:foo:bar Test: Fortnite on ANGLE Bug: b/170755560 Bug: angleproject:5503 Change-Id: I58e3b265daa8ea1f645f47e0971c4454b8ddb3f2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2570775 Commit-Queue: Cody Northrop <cnorthrop@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 2e9706d8 2021-01-08T17:29:42 Vulkan: Use angle::FormatID instead of VkFormat. This change switches the internal enums we pass around from VkFormat to FormatID. The end goal of the refactor is to allow the Vulkan back-end to store packed tables indexed by FormatID. Because VkFormat has large gaps in its enum space we'd otherwise need to use unordered data structures like unordered_map. The change removes the redundant VkFormat storage from vk::Format and uses a new table query to return the VkFormat that 1:1 matches an angle::FormatID. We also include a reverse mapping for use with native Vulkan get functions for Android. Also moves sRGB conversion functions into renderer_utils. A couple sRGB formats that don't exist in GL are no longer handled by the sRGB conversion functions. These formats should be extremely rare. Bug: angleproject:5438 Change-Id: Id8b49773ca0c556f9f5a6a10fcf0d9762b93bbea Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2618204 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Ian Elliott <ianelliott@google.com>
Jamie Madill 038ae144 2020-12-31T21:23:30 Vulkan: Fix up varying component limits. We weren't subtracting reserved varying vectors from component limits. We also were using an incorrect value for fragment input components. Bug: angleproject:5496 Change-Id: I44fc3b2f15687f4dee7a1498d50378e69d74afe3 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2606536 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill e91097bf 2020-12-29T14:05:56 Vulkan: Clean up "actual"/"intended" naming. Clarifies that the GL internal format is an "intended" format and the Vulkan formats are "actual" formats. This makes all the format fields use the same consistent naming pattern. Bug: angleproject:5438 Change-Id: I935a49895109e9e06eae5ef98d5614dfd1128ff8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2605728 Reviewed-by: Tim Van Patten <timvp@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi aff17499 2020-12-23T14:40:06 Vulkan: Directly capture non-gl_Postion builtins Building on support for transform feedback capture of I/O block members, this change optimizes capture of builtins other than gl_Position by directly decorating members of gl_PerVertex. Most importantly, this allows us to reserve only one varying for transform feedback, instead of as many builtins there could be (up to 4). Bug: angleproject:3606 Change-Id: Ie0957802c657ed6c5aac538d92b860582ed6da45 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2601072 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Jonah Ryan-Davis fb35201a 2020-12-22T13:14:41 GL: Expose NV_framebuffer_blit for ES2 contexts when available ANGLE_framebuffer_blit is already exposed but has restrictions on scaling/flipping and mismatched color buffer formats. When NV_framebuffer_blit, EXT_framebuffer_blit, or an ES3 context is available we can expose a less restrictive BlitFramebuffer. Bug: angleproject:5474 Bug: chromium:1157057 Change-Id: I916ee39c8d6120216f91461080eb3ee9ca777e29 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2601165 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 56330564 2020-12-10T00:46:04 Vulkan: Support layered framebuffers This feature is introduced by geometry shaders, where all the layers of a texture can be attached to a framebuffer. The geometry shader would use gl_Layer to decide which layer the primitive should be rendered to. Bug: angleproject:3571 Change-Id: Ib2ae8e227b226295f9e2f62f6b230839070bc95c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2582711 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Shahbaz Youssefi 8797714c 2020-12-01T11:39:25 Vulkan: Support OES_shader_io_blocks Enables OES/EXT_shader_io_blocks extensions in Vulkan backends. With shader I/O blocks, the varyings can now be an array of struct (the block itself) of struct (nested in the block). This change is missing a number of features. In particular, if the shader I/O block has a location decoration in the middle of the block, that is not handled yet. Based on changes from m.maiya@samsung.com and jmadill@chromium.org. Bug: angleproject:3580 Tests: dEQP-GLES31.functional.shaders.linkage.es31.io_block.* dEQP-GLES31.functional.separate_shader.validation.es31.io_blocks.* dEQP-GLES31.functional.program_interface_query.program_input.* dEQP-GLES31.functional.program_interface_query.program_output.* Change-Id: I593840475d2365ff6c9ce7b2290f5ee462a30dfb Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2567645 Reviewed-by: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya e674625d 2020-11-20T13:05:49 Reland "Vulkan: Fix incorrect exposure of sRGB extensions" This is a reland of abcabb474bf1c25eea48d7dca14bcafde737eba7 only we continue to suppress the validation error Original change's description: > Vulkan: Fix incorrect exposure of sRGB extensions > > When we check to see what formats we can reinterpret for sRGB > extensions, we need to make sure we can match the image usage > flags as well. If the original format supports framebuffer > attachment usage, we need to make sure that the reinterpreted > format can support it as well. > > Bug: angleproject:5309 > Change-Id: I7e84d01004504f854a3e22227e99b1740ed1a2b2 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2549156 > Commit-Queue: Mohan Maiya <m.maiya@samsung.com> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> > Reviewed-by: Jamie Madill <jmadill@chromium.org> Bug: angleproject:5309 Change-Id: I0efb6180b7be4e14d24b4bb339de01a2b9177e7e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2556571 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi a5da17cd 2020-11-26T17:09:37 Vulkan: Remove vk:: inside namespace vk Bug: angleproject:5404 Change-Id: I51df1ad69a65b17621a3cbe4e5d55621cc9ae6ec Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2562683 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi f60823d3 2020-11-25T17:03:50 Vulkan: Experimentally enable geometry shaders Partial support for GS was added by jaedon1.lee@samsung.com already. This change enables the extension and adds suppressions for GLES3.1 dEQP tests. Suppressions for KHR GLES3.2 will be updated separately as currently GS shaders in "version 320" fail validation. Bug: angleproject:3571 Change-Id: Ic6ed65554937fd0cce2d0f6ea0ac2eb7e6ed9f10 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2561445 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 4dba2767 2020-11-24T16:01:51 Vulkan: Enable OES_shader_multisample_interpolation Bug: angleproject:5395 Change-Id: I5cebb30fa71ad3c6f04a185ee992f77a900e6b26 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2558931 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Charlie Lao 130597e1 2020-11-23T18:59:02 Vulkan: Use PackedScissor struct to reduce GraphicsPipelineDesc size We are running out of space in GraphicsPipelineDesc. According to gpuinfo, the max reported viewport size is 32768. This CL changes scissor's x/y/w/h from uint32_t to uint16_t, which saves two uint32_t for other usages. Bug: b/173800146 Change-Id: Icf2d8ba8ea8a8c412ecef2059401a8d831c410e4 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2557218 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 9041ca0c 2020-11-20T16:27:48 Limit testing of in-progress work to ANGLE's build of dEQP A new feature is added, exposeNonConformantExtensionsAndVersions, which is set by ANGLE's build of dEQP to allow exposing ES3.2 or extensions that are not yet entirely conformant. This would allow ANGLE to expose WIP extensions for regression testing without affecting partners that test ANGLE with dEQP's standalone build. Bug: angleproject:3647 Change-Id: Id1e6219f26b41d3f8cdc9763131b8052227761c5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2552926 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Sunny Sun <sunny.sun@arm.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill 5fac02c8 2020-11-24T14:20:36 Revert "Vulkan: Fix incorrect exposure of sRGB extensions" This reverts commit abcabb474bf1c25eea48d7dca14bcafde737eba7. Reason for revert: Failed on CQ and build passed, see bug. Bug: angleproject:5394 Original change's description: > Vulkan: Fix incorrect exposure of sRGB extensions > > When we check to see what formats we can reinterpret for sRGB > extensions, we need to make sure we can match the image usage > flags as well. If the original format supports framebuffer > attachment usage, we need to make sure that the reinterpreted > format can support it as well. > > Bug: angleproject:5309 > Change-Id: I7e84d01004504f854a3e22227e99b1740ed1a2b2 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2549156 > Commit-Queue: Mohan Maiya <m.maiya@samsung.com> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> > Reviewed-by: Jamie Madill <jmadill@chromium.org> TBR=syoussefi@chromium.org,jmadill@chromium.org,m.maiya@samsung.com Change-Id: I211802eb17deff3399ec680eeae4c4ff33e52d9d No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: angleproject:5309 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2557567 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Mohan Maiya abcabb47 2020-11-20T13:05:49 Vulkan: Fix incorrect exposure of sRGB extensions When we check to see what formats we can reinterpret for sRGB extensions, we need to make sure we can match the image usage flags as well. If the original format supports framebuffer attachment usage, we need to make sure that the reinterpreted format can support it as well. Bug: angleproject:5309 Change-Id: I7e84d01004504f854a3e22227e99b1740ed1a2b2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2549156 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 4e5a50b6 2020-11-13T22:56:59 Vulkan: Drop dependency to VK_EXT_shader_atomic_float This VK extension exposes features that are not necessary for GL_OES_shader_image_atomic. Instead, support for necessary features for VK_FORMAT_R32_SFLOAT is used to determine support for this GL extension. Bug: angleproject:5342 Change-Id: Ia504cba69ffe51cfd7da69df28f58563cb1f0744 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2536908 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Mohan Maiya <m.maiya@samsung.com>
Mohan Maiya 8a401051 2020-11-19T07:58:05 Vulkan: Support OES_sample_variables extension Enable OES_sample_variables extension on Vulkan backend. Add support for built-in variables, uniform state and constants - gl_SampleId, gl_SamplePosition, gl_SampleMask, gl_SampleMaskIn - gl_NumSamples - gl_MaxSamples Bug: angleproject:3588 Tests: dEQP-GLES31.functional.shaders.sample_variables.* KHR-GLES31.core.sample_variables.* Change-Id: Idf37c7b4ccb0331dbda7acd6389ff4e1022ba959 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2477907 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 2ffff6d0 2020-11-12T10:56:06 Vulkan: Support image buffers This change does not support reinterpreted formats yet. Additionally, despite lack of support for RGB32 formats, EXT_texture_buffer is exposed by this extension. Those formats don't support the STORAGE_TEXEL_BUFFER feature on any known hardware. Bug: angleproject:3573 Change-Id: I85f45eb23f6a0aa533488bb98d9f226d59af4d76 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2534395 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Mohan Maiya f197ebac 2020-11-16T15:16:56 Vulkan: Add EXT_external_buffer support Addition of buffer support for external memory Also adds new end2end tests for these usecases * SubData update * map/unmap buffer * dispatch compute with external buffer Bug: angleproject:5073 Test: ExternalBufferTestES31.*Vulkan Change-Id: Ib3cccaca77b76830effe49d3731782552e7424ec Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2525105 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya ed87c16a 2020-11-15T11:30:47 Vulkan: Add GL_EXT_separate_shader_objects support All the functionality needed for this extension has already been implemented as part of core GLES31. Hook into that along with changes to validation layer to allow non-GLES31 contexts to call into these APIs as long as the extension is exposed. Bug: angleproject:3570 Test: ProgramPipelineTest.GenerateProgramPipelineObjectEXT* Change-Id: I92a61a47517c5cb9573874b2add6a744c9edb755 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2539121 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Shahbaz Youssefi 86d7e4d8 2020-11-10T15:55:34 Vulkan: Support texture buffers Texture buffers are placed in the same descriptor set with the rest of the textures. However, the different code paths that handle textures have special cases for texture buffers as they create a different descriptor type (texel buffer instead of combined image sampler). Image view serials are used to track the buffer view serials as well so the texture descriptor cache can handle texture buffers as well. This CL is missing storage texel buffer support. Bug: angleproject:3573 Change-Id: Iff80ca22ff9b9957a0c9a3c7aaada1fa54b24ec8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2532653 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Shahbaz Youssefi e5a5567d 2020-11-12T23:29:53 Vulkan: Expose OES_shader_image_atomic without VS/FS atomics If vertexPipelineStoresAndAtomics is not available, the vertex stage limit for images is set to 0, so there won't be any images in that stage. Similarly for fragmentStoresAndAtomics. The extension can still be exposed for use with compute shaders. Bug: angleproject:3578 Change-Id: I86133415bc14c219067827758e727ce7ab079973 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2536252 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Tim Van Patten <timvp@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya aead51e3 2020-11-12T09:08:19 Vulkan: Disable OES_shader_multisample_interpolation The spec for OES_shader_multisample_interpolation requires support for OES_sample_variables. Disable support until the changes related to OES_sample_variables land. Bug: angleproject:3589 Bug: angleproject:3588 Change-Id: I94408a4f4fd74c19922c011242a515cc457910cf Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2535075 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Brandon Schade 1e494cae 2020-10-07T19:26:01 Vulkan: Add support for EXT_copy_image Add support for GL_EXT_copy_image which allows image data transfer between image objects. This is implemented by using the vkCmdCopyImage API call. Bug: angleproject:3593 Test: dEQP-GLES31.functional.copy_image.* Change-Id: I30a34a8711b5d2e5834064d7453e03d6ec0df478 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2393955 Commit-Queue: Brandon Schade <b.schade@samsung.com> Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya bf1a4627 2020-11-04T12:48:47 Vulkan: Enable GL_EXT_buffer_storage extension This change 7bbe497 accidentally disabled support for GL_EXT_buffer_storage extension for the Vulkan backend, enable it again. Bug: angleproject:5056 Tests: angle_end2end_tests --gtest_filter=BufferStorageTestES3*Vulkan Change-Id: If4da2fe2c3e8b098875c89643d366f15fd0ea8b2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2519875 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Amy Liu f34ba646 2020-10-30T14:40:22 Fix maxShaderAtomicCounters value. Set maxShaderAtomicCounters to zero when atomic operation is not supported. Some cts tests will only check maxShaderAtomicCounters instead of vertexPipelineStoresAndAtomics before run. Test: dEQP-GLES31.functional.shaders.opaque_type_indexing.atomic_counter.*vertex Bug: angleproject:5272 Change-Id: Iceb4fc13eb26548ccbfaa430501d88f5ba3dfcc3 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2507280 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya e895ced6 2020-10-29T09:06:00 Vulkan: Add OES_shader_image_atomic support Add support for shader builtins and enable the extension. Bug: angleproject:3578 Tests: dEQP-GLES31.functional.*image_atomic* Change-Id: Idd45b2ee62efe1474c6c5947c77da64ff2221bf6 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2505540 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya 5cbf54da 2020-10-18T10:42:07 Vulkan: Fix exposure requirements for EXT_texture_format_sRGB_override Previously we were not checking for the correct format support to expose this extension. This change fixes that, and disables the extension if we do not support the formats we need for our implementation to function. This also adds an end2end test to check each possible format that can be used with this extension. Update GLES major version to 3 for TextureSampling perf benchmark Bug: angleproject:4561 Change-Id: Ic81bb28f02f9f36e1bc83a8eea376169de9e7735 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2359482 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Mohan Maiya 5d0458fa 2020-10-23T12:52:34 Vulkan: Add OES_shader_multisample_interpolation support Support OES_shader_multisample_interpolation extension if maxInterpolationOffset >= 0.5 Bug: angleproject:3589 Tests: dEQP-GLES31.functional.shaders.multisample_interpolation.* dEQP-GLES31.functional.state_query.multisample_interpolation.* Change-Id: I42997f10be82e3be8b63c56833cbbf791bf4be9b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2477905 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 2072ce50 2020-10-18T16:44:09 Rename "NonLinear" to "SRGB". In OpenGL parlance there are really only two color spaces: Linear and SRGB. Vulkan is much more complicated with linear and nonlinear SRGB, and multiple non-SRGB linear color spaces. Keep things simple by working with OpenGL nomenclature. Bug: angleproject:5176 Change-Id: Ia730a9a666a2b3325194b86dc588e7fd226c4183 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2483466 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Mohan Maiya 7bbe497a 2020-10-16T14:46:45 Vulkan: Implement EXT_texture_sRGB_decode Implement EXT_texture_sRGB_decode. This builds on the existing functionality from EXT_texture_sRGB_override, with 2 major edge cases: 1. sRGB_decode allows the texture state to be overridden by sampler state, which is implemented by forcing a a texture state sync during updateActiveTextures if a texture is bound to the same unit as a sampler with that state 2. texelFetch calls require us to reenable decoding, regardless of decode state. We add a new compiler pass (FlagSamplersWithTexelFetch) to mark samplers that are used with texelFetch in order to support this. This change also re-enables EXT_texture_sRGB_R8, which was disabled due to a dEQP bug that this change will bypass. Bug: angleproject:3609 Bug: angleproject:4503 Test: dEQP.GLES31/functional_srgb_texture_decode_skip_decode_* Test: GLES31/functional_state_query_texture_*_srgb_decode_* Test: GLES31/functional_state_query_sampler_*_srgb_decode_* Test: GLES31/functional_debug_negative_coverage_*_srgb_decode_* Test: GLES31/functional_android_extension_pack_extensions_ext_texture_srgb_decode Test: angle_end2end_tests --gtest_filter=SRGBTextureTest.*Vulkan* Change-Id: I4a67e487dc82e2f57c8c87d4bcd8ef442b6fe220 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2359481 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Hyunchang Kim d9a88d63 2020-09-28T17:58:31 Vulkan: Support OES_texture_cube_map_array extension Add support for GL_OES_texture_cube_map_array to the Vulkan backend if the underlying ICD supports creation of of cube array ImageViews Bug: angleproject:3584 Test: dEQP-GLES31.functional.fbo.color.texcubearray.* Change-Id: I636cbf347d718abfc1600119b312578370b8e02e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2437989 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Alexey Knyazev d5fa6ea9 2020-04-29T04:13:54 Vulkan: Implement OES_draw_buffers_indexed Bug: angleproject:4394 Change-Id: I7db9c695c233b2daf740acc654b1b2e546a8b681 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2172739 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Mohan Maiya 9f5eb0b8 2020-10-05T08:18:05 Vulkan: Add OES_sample_shading extension support Support OES_sample_shading extension if the underlying Vulkan ICD supports sampleRateShading. Bug: angleproject:3587 Tests: dEQP-GLES31.functional.sample_shading.* Change-Id: I1b324c1ad3ea3b2157d3cbe0abcdf7085aa4231b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2444213 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Trevor David Black e815afbf 2020-09-07T22:09:22 First pass at increasing inclusivity Link to the inclusivity rules https://source.android.com/setup/contribute/respectful-code Bug: b/162834212 Bug: chromium:1097198 Change-Id: Ied5a9e3879d72bff3f77ea6fcda9b82f30c32c2f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2396737 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Trevor Black <vantablack@google.com>
Mohan Maiya a2d8bbb5 2020-09-18T18:18:34 Vulkan: Add GL_EXT_buffer_storage extension support Addition of support for immutable storage to buffer objects. Also adds new end2end tests for these usecases * Basic BufferStorage * SubData update * map/unmap buffer Bug: angleproject:5056 Tests: angle_end2end_tests --gtest_filter=BufferStorageTestES3*Vulkan Change-Id: Iba74b372ad033711927b63c6a04cec0eeb4db699 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2419952 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Geoff Lang f0b02054 2020-08-06T20:55:05 Add a Vulkan feature to compress float32 vertex formats. Use the vertex conversion pipeline in VertexArrayVk to detect static vertex data and convert float32 vertices to float16. This feature is useful for determining if an allication is vertex bandwidth bound and seeing what gains could be had by using smaller attributes. This feature could be implemented in ANGLE's frontend but new infrastructure for converting and storing the converted attributes would need to be added to gl::VertexArray. Our backends already have the functionality needed to handle unsupported attribute formats and this can be repurposed for compressing vertex formats. Bug: b/167404532 Bug: b/161716126 Change-Id: I9a09656a72e8499faa4124adf876d7261c8341c9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2342285 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya 9e2953c2 2020-09-23T07:57:22 Vulkan: Enable OES_texture_storage_multisample_2d_array The implementation for OES_texture_storage_multisample_2d_array already exists. This patch just enables the appropriate capability flag only if the underlying Vulkan ICD supports standardSampleLocations Bug: angleproject:3583 Tests: angle_end2end_tests --gtest_filter="*TextureMultisampleArrayWebGLTest*Vulkan" dEQP-GLES31.functional.state_query.internal_format.texture_2d_multisample_array.* dEQP-GLES31.functional.state_query.texture_level.texture_2d_multisample_array.* Change-Id: I2ea89041d9aa8c7d94c9ba732f12528c809807ac Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2416979 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
Shahbaz Youssefi 84bd9dad 2020-08-26T22:01:44 Vulkan: Allow pbuffer usage if no window support Vulkan allows rendering to non-swapchain images, so pbuffers can always be supported on every config. With this change, if the window system does not support a configuration, EGL_WINDOW_BIT is removed from the config instead of dropping the config entirely. Bug: chromium:1034840 Change-Id: Ib972ed8ddf7660c327123fa83ae0674456cf2a35 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2378921 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: back sept 10 - Jamie Madill <jmadill@chromium.org>
Geoff Lang 7e815c77 2020-07-08T13:43:40 Implement EXT_shadow_samplers Bug: angleproject:4863,b/161716126 Change-Id: I6beb45d91f59a851787c9f40b40266fb985198d5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2288330 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Reviewed-by: back sept 10 - Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 1dcb3eb2 2020-08-06T15:02:34 Vulkan: Don't expose MSRTT on Mac/SwiftShader Frequently causes failures as such: [...:ERROR:drawing_buffer.cc(854)] Initialization failed to allocate backbuffer. [...:INFO:CONSOLE(197)] "Unable to initialize webgl context.", source: (197) Bug: chromium:1112986 Bug: angleproject:4937 Change-Id: I5058f78434c0ac49345fe1167043f2dca759b1b9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2341350 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi fc4bd898 2020-08-03T16:29:06 Vulkan: Support ANGLE_external_objects_flags With this extension, it is possible to import Vulkan images into ANGLE (similar to EXT_external_objects) while specifying the Vulkan create and usage flags used to create that image. This can be used by the application to drop usage flags it does not need to improve performance, or add create flags as it requires. Bug: angleproject:4912 Bug: fuchsia:52759 Change-Id: Ia568973b19670999dd0e69f6ac5548e8ef0c3eec Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2335020 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Michael Spang <spang@chromium.org>
Shahbaz Youssefi f776eb9c 2020-08-01T23:45:24 Vulkan: EXT_multisampled_render_to_texture2 support The previous change that implemented EXT_multisampled_render_to_texture already provisioned this extension in the Vulkan backend. This change implements the front-end for this extension and enables it in the Vulkan backend. Bug: angleproject:4836 Change-Id: I7080260972e61727c5716051c236f635668cb67b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2330510 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com>
Shahbaz Youssefi dcc56215 2020-07-19T01:12:09 Vulkan: Implement GL_EXT_multisampled_render_to_texture This change allows the use of resolve attachments in the Vulkan backend. GL_EXT_multisampled_render_to_texture is implemented using this feature. The infrastructure for specifying resolve attachments is designed with eventual support for GL_EXT_multisampled_render_to_texture2 in mind as well as optimizations to glBlitFramebuffer() and multisampled backbuffers. Proper support for glRenderbufferStorageMultisampledEXT is still missing from this change. All tests use this for the depth/stencil attachment and don't read back the data. Currently, the depth/stencil attachment is created as a normal multisampled image. Bug: angleproject:4836 Change-Id: I110a7f63312ae61a657b6094adf7d97c92bd5843 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2304170 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com>
Shahbaz Youssefi 3f851efa 2020-07-24T14:54:37 Vulkan: Fix overflow in maxCombinedUniformComponents The value is capped to INT_MAX to avoid overflow when queried with glGetIntegerv(). Bug: angleproject:4554 Bug: angleproject:4788 Change-Id: I36d52fc608ef5adc2bc0b73e379db66cbfd9bb54 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2318046 Reviewed-by: Mohan Maiya <m.maiya@samsung.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Geoff Lang 16856027 2020-07-08T13:47:33 Support EXT_shader_texture_lod on Vulkan. Bug: angleproject:2899,b/161716126 Change-Id: Ia850cbda948c8f6da9ced0bf46fd7f8371125032 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2288333 Reviewed-by: Tim Van Patten <timvp@google.com> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Xinyi He 92ffd40e 2020-07-08T18:25:55 Vulkan: Disable GL_EXT_robustness extension on Mali Vulkan doesn't have a mapping extension to GL_EXT_robustness, so we need to disable it. Bug: angleproject:4823 Change-Id: If7b66c0eb7ba14b9349925af64ec2efcec9985a4 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2287092 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Mohan Maiya 5474304a 2020-06-24T11:29:58 Vulkan: Handle overflow in maxCombinedUniformComponents computation Certain vendors support large number of uniform buffer components. The calculation of maxCombinedUniformComponents overflows when captured in a 32bit lvalue. Update it to a 64bit variable. Bug: angleproject:4788 Tests: dEQP-GLES3.functional.state_query.integers64.max_combined* Change-Id: I355910218c56347c98a5dfa7359b00be7b40871a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2264849 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi e7ae237e 2020-06-12T23:52:09 Vulkan: ANGLE_copy_texture_3d support Bug: angleproject:4748 Test: CopyTexImage*Vulkan:Texture3DCopy*Vulkan:Texture2DArrayCopy*Vulkan Test: dEQP.KHR_GLES3/copy_tex_image_conversions_required_cubemap*cubemap* Change-Id: Ifdc3d455ca8c9e732d0adf4afa9e2809d780ae18 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2246320 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Tim Van Patten <timvp@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Shahbaz Youssefi 340da145 2020-06-16T10:58:47 Vulkan: Disable 1xMSAA on integer formats too This was pending swiftshader support for 4xMSAA support for integer formats, which is long done. Bug: angleproject:4197 Change-Id: I843a9674e20a48b5387bd67b8c0efc8617841382 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2248198 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Ian Elliott <ianelliott@google.com>
Antonio Maiorano 4f343f3e 2020-05-13T14:11:51 Reland "Add support for GL_CHROMIUM_texture_filtering" This is a reland of 38780ae3921d2570316119a881adfb9520e7e296 modulo the changes to disable VK_VALIDATION_FEATURE_DISABLE_UNIQUE_HANDLES_EXT, as this was causing problems. With this landed, the extension will not work on SwiftShader until we find a way to allow this extension through the validation layers. Bug: b/146423360 Bug: b/154620295 Change-Id: Ie09fc507c01a47be3bb227bc78771660170ba5d3 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2199639 Commit-Queue: Antonio Maiorano <amaiorano@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Brandon Schade 8f6d1af9 2020-03-19T14:35:48 Vulkan: Implement EXT_texture_format_sRGB_override Implemented support for EXT_texture_format_sRGB_override This is done by creating new imageviews for textures with sRGB overridden that reinterpret the format to its sRGB counterpart. As preparation for this, textures that use this feature are reallocated with VK_IMAGE_CREATE_MUTABLE_FORMAT_BIT. This will have a performance cost for textures that use this feature, but should have no performance cost for regular textures, since they will not have this bit set. Bug: angleproject:4561 Test: angle_end2end_tests --gtest_filter=SRGBTextureTest.*Vulkan* Change-Id: Iba25f1f2b0a7227959c1cb4ba6e3ca8311c20d06 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2152145 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Tim Van Patten <timvp@google.com>
Tim Van Patten 3b82fdcf 2020-05-12T23:44:07 Revert "Add support for GL_CHROMIUM_texture_filtering" This reverts commit 38780ae3921d2570316119a881adfb9520e7e296. Reason for revert: Breaks SWANGLE-VK: 05-12 23:42:28.612 22836 22861 D libEGL : dlopen_ext from APK (libEGL_angle.so) success at 0x79f4485a10 05-12 23:42:28.617 22836 22861 D libEGL : dlopen_ext from APK (libGLESv1_CM_angle.so) success at 0x79f4485eb0 05-12 23:42:28.619 22836 22861 D libEGL : dlopen_ext from APK (libGLESv2_angle.so) success at 0x79f4485c60 05-12 23:42:28.624 14223 14223 D StatusBar: disable<e i a s b h r c s > disable2<q i n > 05-12 23:42:28.633 14014 14057 V DisplayPowerController: Brightness [0.19986142] reason changing to: 'automatic', previous reason: 'automatic [ dim ]'. 05-12 23:42:28.635 22836 22861 D vulkan : searching for layers in '/data/app/~~0AfWfBsFEO78tqKlnanevg==/org.khronos.gl_cts-NOs3SGclHqlbcqe-08gHrw==/lib/arm64' 05-12 23:42:28.635 22836 22861 D vulkan : searching for layers in '/data/app/~~0AfWfBsFEO78tqKlnanevg==/org.khronos.gl_cts-NOs3SGclHqlbcqe-08gHrw==/base.apk!/lib/arm64-v8a' 05-12 23:42:28.632 22836 22836 W .khronos.gl_cts: type=1400 audit(0.0:218): avc: denied { ptrace } for scontext=u:r:zygote:s0 tcontext=u:r:untrusted_app_25:s0:c512,c768 tclass=process permissive=0 b/77925912 app=org.khronos.gl_cts 05-12 23:42:28.636 14014 14034 I EventSequenceValidator: Transition from ACTIVITY_LAUNCHED to ACTIVITY_FINISHED 05-12 23:42:28.637 22836 22861 F SwiftShader: external/swiftshader/src/Vulkan/libVulkan.cpp:425 vkCreateInstance TRACE_ASSERT: pCreateInfo->pNext sType = 1000247000 --------- beginning of crash 05-12 23:42:28.637 22836 22861 F libc : Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 22861 (.khronos.gl_cts), pid 22836 (.khronos.gl_cts) Original change's description: > Add support for GL_CHROMIUM_texture_filtering > > Chromium enables a custom extension, GL_CHROMIUM_texture_filtering, when > using SwiftShaderGL, to enable high precision filtering. This change > makes it so ANGLE also handles this same extension when using the > SwiftShaderVK backend, by enabling the new > VK_GOOGLE_sampler_filtering_precision custom extension. > > Bug: b/146423360 > Bug: b/154620295 > Change-Id: I69cafc1ccf5970a3d220ac7e13ec3c8fdd4a9643 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2185822 > Commit-Queue: Antonio Maiorano <amaiorano@google.com> > Commit-Queue: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Jamie Madill <jmadill@chromium.org> TBR=geofflang@chromium.org,jmadill@chromium.org,amaiorano@google.com # Not skipping CQ checks because original CL landed > 1 day ago. Bug: b/146423360, b/154620295 Change-Id: I803d7a7baac81cf178b59c4bf2789346ec1d3f87 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2197168 Reviewed-by: Tim Van Patten <timvp@google.com> Commit-Queue: Tim Van Patten <timvp@google.com>
Xinyi He e7b9118b 2020-05-11T17:49:30 Vulkan: Set maxShaderImageUniforms zero on some Mali GPUs Some Mali GPUs don't support vertexPipelineStoresAndAtomics feature, so the maxShaderImageUniforms should be set zero. Bug: angleproject:4629 Change-Id: I754506dd27c75b3dfd5ab695e24a680f683ca78a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2195424 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Antonio Maiorano 38780ae3 2020-05-06T16:05:02 Add support for GL_CHROMIUM_texture_filtering Chromium enables a custom extension, GL_CHROMIUM_texture_filtering, when using SwiftShaderGL, to enable high precision filtering. This change makes it so ANGLE also handles this same extension when using the SwiftShaderVK backend, by enabling the new VK_GOOGLE_sampler_filtering_precision custom extension. Bug: b/146423360 Bug: b/154620295 Change-Id: I69cafc1ccf5970a3d220ac7e13ec3c8fdd4a9643 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2185822 Commit-Queue: Antonio Maiorano <amaiorano@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Mohan Maiya daed369c 2020-05-05T14:24:26 EGL: Add support for GL_EXT_EGL_image_array extension Add support for creating 2D array EGLImages. 2D array textures are core in GLES3.0. Enable the eglImageArray bool that controls exposure of the extension for all contexts >= GLES3.0 Bug: angleproject:4604 Tests: angle_end2end_tests --gtest_filter=ImageTest.*2DArray* Change-Id: Iebc1ad184fe7209ca89d620290337438ac251c56 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2176109 Commit-Queue: Mohan Maiya <m.maiya@samsung.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Xiaoxuan Liu 4262ea04 2020-01-31T22:59:13 Vulkan: Add gles1 conformance support. For Khnoros CTS1 support, ANGLE needs to add conformant and rendererType for OpenGL ES1 version. Bug: angleproject:4457 Change-Id: I58ac4672352d3d42e4b8403b80f86154b6a76edc Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2160515 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Brandon Schade 5578fc84 2020-04-22T09:34:30 Vulkan: Disable EXT_texture_sRGB_R8 Due to a dEQP bug, EXT_texture_sRGB_R8 cannot be exposed before EXT_texture_sRGB_decode is available. This change disables EXT_texture_sRGB_R8 on the vulkan backend. Bug: angleproject:3609 Test: dEQP-GLES31.functional.srgb_texture_decode.skip_decode.sr8.* Change-Id: I261c80986484e489f6903eb54ac6865433050bfa Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2161985 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>