src/libANGLE/renderer/gl/formatutilsgl.cpp


Log

Author Commit Date CI Message
Shahbaz Youssefi d193d51b 2024-06-17T22:46:08 Replace issue ids post migration to new issue tracker This change replaces anglebug.com/NNNN links. Bug: None Change-Id: I8ac3aec8d2a8a844b3d7b99fc0a6b2be8da31761 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5637912 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Roman Lavrov 21f16cb1 2023-06-09T17:30:38 Disable clang-format on ANGLE features autogen outputs Updates the script to produce reasonably formatted code without clang-format. Autogen files moved to autogen/ sub-directories because clang-format does not support per-file settings ;( This allows to run this codegen very quickly (~50ms on my machine) Bug: angleproject:8193 Change-Id: Ie84282090d574ebb4debe3edcfd82f983f27a5ff Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4604578 Commit-Queue: Roman Lavrov <romanl@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Alexey Knyazev b26b01a2 2023-03-09T00:00:00 Implement EXT_render_snorm Bug: angleproject:8048 Change-Id: Id01beaea9565f8ab374c732fef70ec0ac0d8743e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4334303 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
Alexey Knyazev e2cf65ed 2023-02-22T00:00:00 Implement QCOM_render_shared_exponent Fixed: angleproject:8043 Change-Id: Ia76b8e4b60a640180bae77cba523142749051398 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4289140 Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Alexey Knyazev 11608a8b 2023-01-23T00:00:00 Adjust STENCIL_INDEX8 caps * Fixed a typo in GetSizedFormatInternal * Required texturing for OES_texture_stencil8 * Marked all depth/stencil formats as not blendable * Fixed frontend and GL texture caps for GL_STENCIL_INDEX8 Bug: angleproject:3231 Change-Id: Ie91e4bb4e8ab56d39dc1270487380b0bfce25b08 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4194169 Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Alexey Knyazev a4e00c64 2022-06-30T00:00:00 Expose EXT_compressed_ETC1_RGB8_sub_texture on Metal and GL Updated the test to ensure that this extension is exposed on Apple GPUs when using Metal. Updated emulatedEtc1 limitation to hide this extension when the main ETC1 extension is hidden. Real WebGL apps cannot enable this extension because it is not exposed in WebIDL. Removed bogus entry from IsETC1Format and use the helper consistently in all validation functions. Simplified GetNativeCompressedFormat. Bug: angleproject:7471 Change-Id: I61321fadad7d962358d0fefecd08aaddaedd2ec2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3737762 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 400d9fe4 2022-04-23T01:08:19 Rename feature files to *_autogen.h To clarify further that they are not to be edited by hand. Bug: angleproject:6435 Change-Id: Iaf79706d2b688a43b3ebb65700cfbdd71a49a742 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3603842 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi fcec6904 2022-04-13T14:18:06 Generate feature variable names from display names The json file now only contains the feature display name. The variable name is automaticaly derived. For consistence with Chromium and other Chromium-based projects, the display name is now always snake_case, and that's what's specified in the json files. This also makes camelCase variable name generation trivial (as opposed to the other way around). Feature overrides now accept both snake_case and camelCase names to ensure compatibility with existing scripts. This is done by removing _ and comparing override names with feature names in lower case. Bug: angleproject:6435 Change-Id: I0b6ed2bbf5c312bc4f4be7b3c7d55dbaca2a9886 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3584630 Reviewed-by: Amirali Abdolrashidi <abdolrashidi@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Geoff Lang be53aea8 2022-03-10T11:04:22 Reland: Emulate RGB10 (no alpha) on desktop OpenGL. The OpenGL ES extension GL_EXT_texture_type_2_10_10_10_REV requires RGB and RGBA formats to be supported but Desktop OpenGL does not support RGB. Emulate it with the existing emulatedAlphaChannel path in TextureGL. Bug: chromium:1300575 Change-Id: I5efea52d3da628cf82b43fece23894e6f47df650 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3533141 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Geoff Lang 44e84661 2022-03-17T15:02:21 Revert "Emulate RGB10 (no alpha) on desktop OpenGL." This reverts commit 6404be2defd3ded3ff2f0437bb87fe515e10f2a7. Reason for revert: Extension was not fully enabled due to test bug. Original change's description: > Emulate RGB10 (no alpha) on desktop OpenGL. > > The OpenGL ES extension GL_EXT_texture_type_2_10_10_10_REV > requires RGB and RGBA formats to be supported but Desktop OpenGL > does not support RGB. Emulate it with the existing > emulatedAlphaChannel path in TextureGL. > > Bug: chromium:1300575 > Change-Id: I0e6d1044afbc55cf6d4f987cc98b357ff11ff006 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3517346 > Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Commit-Queue: Geoff Lang <geofflang@chromium.org> Bug: chromium:1300575 Change-Id: Ib3810a18888544f1700a1f648a5094c19973d86d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3533139 Reviewed-by: Geoff Lang <geofflang@chromium.org> Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Geoff Lang 6404be2d 2022-03-10T11:04:22 Emulate RGB10 (no alpha) on desktop OpenGL. The OpenGL ES extension GL_EXT_texture_type_2_10_10_10_REV requires RGB and RGBA formats to be supported but Desktop OpenGL does not support RGB. Emulate it with the existing emulatedAlphaChannel path in TextureGL. Bug: chromium:1300575 Change-Id: I0e6d1044afbc55cf6d4f987cc98b357ff11ff006 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3517346 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Alexey Knyazev 47279c72 2021-08-15T23:20:32 Adjust compressed texture validation; add test - Format check happens before target check to accommodate for unknown / disabled format enums. - PVRTC1 and ETC1 enums are not allowed for 2D Array and 3D targets. - PVRTC1 sRGB formats require enabling two extensions. - New noCompressedTexture3D limitation for older Metal versions. The test checks that only the appropriate entry points are affected after enabling compressed texture extensions. Bug: angleproject:5731, angleproject:6280 Change-Id: I4943cd3a82f60f9348215caa8639e0bc3e8b45db Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3094018 Reviewed-by: Alexey Knyazev <lexa.knyazev@gmail.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
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>
Alexey Knyazev ad55bdbe 2021-04-02T22:59:07 GL: Align emulated ETC1 handling with other backends Use emulatedEtc1 limitation to hide it from WebGL. Bug: chromium:1048244 Change-Id: Id2fd6b5d934f3caeb455e8f0fc198445e8c00084 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2803136 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
Peng Huang 4efe33e3 2021-03-04T07:45:20 Fix two GL_OES_texture_half_float related problems with GLES2 * Fix incorrect ASSERT in formatutilsgl.cpp * CheckInternalFormatRenderbufferRenderability() and CheckSizedInternalFormatTextureRenderability() may cause GL errors, we should clear them. Bug: chromium:1174074 Change-Id: Ieef5e79b68f317833b459da34cc2e5362f813304 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2735374 Commit-Queue: Peng Huang <penghuang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Gert Wollny fb7a2445 2021-02-12T09:29:11 libANGLE: Declare copy operator if copy constructor is defined If the copy constructor is defined then the copy assignment must also be defined, but we can use the default here. v2: Don't inline because the chromium-style errors out on this Bug: angleproject:4486 Change-Id: Iec0f63342244249da32b455b49a0b89b6558cab9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2690953 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis 5af5808b 2021-02-10T13:06:36 GL: Do not support ETC1 textures on Desktop GL As pointed out in WebGL issue 3014, ANGLE has been exposing ETC1 texture support on desktop GL when GL_ARB_ES3_compatibility or GL 4.3+ is available. However, it is very likely that none of these platforms actually have hardware support for this format, and are only supporting it for compatiblity with ES3. We shouldn't expose this so that desktop clients can use a better format instead. Bug: chromium:1048244 Change-Id: I53837a05719d0ca3ff390b5b45b61a1f9c72a535 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2687466 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
Alexey Knyazev ebdd8abb 2021-01-13T23:42:44 OpenGL: Remove avoidDXT1sRGBTextureFormat workaround Bug: angleproject:5543 Change-Id: I2a7e2d563aa60e6e53dd6b6c32fbc449368e4e06 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2627425 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
Kenneth Russell 011e0ad1 2020-12-16T17:34:50 Promote RGBA4444 and RGB565 to RGB[A]8 on macOS with AMD GPUs. There are bugs in Apple's OpenGL driver when uploading to textures of these formats via pixel buffer objects. Because automatic graphics switching might activate the AMD GPU at any time, use this workaround on dual-GPU MacBook Pros even if the Intel GPU is active. Fixes the following WebGL 2.0 conformance tests: deqp/functional/gles3/texturespecification/ teximage2d_pbo_2d_00.html teximage2d_pbo_2d_01.html texsubimage2d_pbo_2d_00.html texsubimage2d_pbo_2d_01.html texsubimage2d_pbo_cube_01.html Bug: angleproject:5469 Change-Id: I7d65dc5f664159b4b59d46400a8d9c492f67040b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2595245 Commit-Queue: Kenneth Russell <kbr@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
James Darpinian 59d28532 2020-08-27T17:04:32 Fix GL_EXT_texture_compression_s3tc_srgb on macOS GL_EXT_texture_compression_s3tc_srgb wasn't being exposed on macOS because formatutilsgl.cpp was looking for GL_EXT_texture_sRGB, but it was moved to core in 2.1 and the macOS driver doesn't report it anymore. Bug: angleproject:4997 Change-Id: Iae736fac6d315f567ff5d834a043134f91625e59 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2380516 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: James Darpinian <jdarpinian@chromium.org>
Kenneth Russell c8bfefac 2020-05-22T14:54:47 Emulate unsized depth/stencil textures on ES 3.0 without OES_depth_texture. Use sized internal formats for unsized depth/stencil textures on ES 3.0 devices that don't advertise the GL_OES_depth_texture extension. This CL makes the webgl-depth-texture.html conformance test pass on WebKit's ANGLE backend on iOS. Bug: angleproject:4591 Change-Id: Ifc45e74258ecf2e6433662bb10b081f1f94bded9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2213678 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Kenneth Russell 05f11a3b 2020-05-21T14:33:42 Remove requirement of OES_texture_half_float for EXT_color_buffer_half_float. Some OpenGL ES 3.0 devices don't advertise OES_texture_half_float, but do advertise EXT_color_buffer_half_float. For this reason, stop requiring OES_texture_half_float when determining renderability of GL_RGBA16F textures. Bug: angleproject:4649 Change-Id: I657011fcc3bb35909760a57e8ad53cfbbc61c67a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2212434 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Kenneth Russell <kbr@chromium.org>
Kenneth Russell 68f92942 2020-05-22T18:32:52 Emulate GL_EXT_sRGB on ES 3.0 devices without native support. Translate the extension's internal formats and formats to values valid in core ES 3.0. Bug: angleproject:4655 Change-Id: Ie47d01fb2ebca7bab5058812c9f4217523f784a0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2213262 Commit-Queue: Kenneth Russell <kbr@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Kenneth Russell 96a80283 2020-05-20T16:48:54 Advertise filtering support for FP16 luminance/alpha formats on ES 3.0. Now that these formats are emulated if necessary on ES 3.0 contexts, advertise filtering support as well. This enables OES_texture_half_float_linear on mobile devices which support ES 3.0 but don't advertise this extension. Bug: angleproject:4648 Change-Id: I09f00fbb1454b2cfa72295254fbc45c872f4919c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2210701 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Kenneth Russell <kbr@chromium.org>
Kenneth Russell 651378b2 2020-05-14T20:44:54 Support OES_texture_{half_}float on ES 3.0 without these extensions. Emulate the LUMINANCE, ALPHA and LUMINANCE_ALPHA formats with GL_RED/GL_RG textures on platforms that don't support the OES_texture_{half_}float extensions. Fix a preexisting bug in TextureGL's luminance/alpha emulation where it would use desktop GL functionality on GLES. This change makes WebKit on iOS pass WebGL's conformance/extensions/oes-texture-{half-}float tests per https://bugs.webkit.org/show_bug.cgi?id=210524 . Bug: angleproject:4636 Change-Id: I6c158058e4b170b16ece578a3930c230de16a9ca Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2203283 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Kenneth Russell <kbr@chromium.org>
Qin Jiajia a56537a3 2020-04-29T11:14:03 Enable GL_BGRA_EXT for es backend It's required on Chrome OS. Based on spec EXT_texture_format_BGRA8888, this format is renderable. Bug: angleproject:4594 Change-Id: Ibde0f0de18f4b8079a23f4b13123c6b5c8794a89 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2172638 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jiajia Qin <jiajia.qin@intel.com>
Jonah Ryan-Davis d6448538 2020-03-09T12:49:32 Relax GL_DEPTH_COMPONENT32_OES format support rules On iOS, GL_OES_depth_texture is supported, which includes the format GL_DEPTH_COMPONENT32_OES. However, GL_OES_depth32 is not always exposed. This is causing ANGLE to not expose GL_OES_depth_texture, and GL_ANGLE_depth_texture. Bug: angleproject:4451 Change-Id: If9cd782e851e040b1cf24a763dd93e063ebffbc7 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2095361 Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jonah Ryan-Davis <jonahr@google.com>
Alexey Knyazev a44d96dc 2020-02-05T14:20:59 Apply compressed format workarounds to texStorage entrypoints Bug: angleproject:4266 Change-Id: I70b3cdef35395b3a92bd460c9911b1ed963e0dcd Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2038573 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Alexey Knyazev 58fc8b11 2020-01-31T19:03:12 Implement RGTC (BC4, BC5) compressed texture formats gl.xml was modified as two enums were missing from their proper group. dxgi_support_data.json was fixed to not expect BC4 and BC5 on FL9_3 Bug: angleproject:3149 Change-Id: Ieb97a8cf8e92258c1b44e090e823fac227997174 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2033068 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Kenneth Russell <kbr@chromium.org>
Alexey Knyazev d8c4b5fb 2020-01-31T16:47:51 Expose ASTC 2D on OpenGL Bug: angleproject:4372 Change-Id: Ic1800ac10b12547ca9816f7ad9dfd62f83f227c0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2033066 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org>
Alexey Knyazev 9e774041 2020-01-31T15:09:01 Update S3TC GL extension strings Added avoid_dxt1_srgb_texture_format workaround Bug: angleproject:4266 Change-Id: I286a9c66f6ea1d2c9d3587f6ca85608336eb44a6 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2033065 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
shrekshao 81ee4d29 2019-12-04T17:05:11 Workaround EXT_texture_norm16 for OpenGL ES drivers Implement a workaround for widespread bugs calling glReadPixels with RGBA/UNSIGNED_SHORT against R16/RG16 color attachments. Read back the data using the GL_IMPLEMENTATION_COLOR_READ_FORMAT, and then rearrange the read back pixels to fit the RGBA layout. Also skip RGB16/RGB16_SNORM texture sample test on Nexus 5X/Nexus 6P due to a another driver bug. Bug: chromium:1000354, angleproject:4214, angleproject:4215, angleproject:4245 Change-Id: Iedea6f4136878cac5ad0dec3757c77b73502e1cd Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1952166 Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Shrek Shao <shrekshao@google.com>
shrekshao e33c1582 2019-11-06T16:55:29 Fix EXT_texture_norm16 * Add norm16 format info for OpenGL backend * Add validation for newly introduced norm16 formats * Fix some logic of texture tests Bug: chromium:1000354, angleproject:1365 Change-Id: Ie6d6e5e276da4df4b7c667be28d324d4976b35ec Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1902720 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shrek Shao <shrekshao@google.com> Commit-Queue: Shrek Shao <shrekshao@google.com>
Le Quyen 6e653981 2019-10-09T15:19:02 Added PVRTC compression extension needed for Metal on iOS. Bug: angleproject:2634 Change-Id: I413f754fe5551b1e248bc2b824b327b92d8c70f9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1849076 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Stuart Morgan 9d737966 2019-08-14T12:25:12 Standardize copyright notices to project style For all "ANGLE Project" copyrights, standardize to the format specified by the style guide. Changes: - "Copyright (c)" and "Copyright(c)" changed to just "Copyright". - Removed the second half of date ranges ("Y1Y1-Y2Y2"->"Y1Y1"). - Fixed a small number of files that had no copyright date using the initial commit year from the version control history. - Fixed one instance of copyright being "The ANGLE Project" rather than "The ANGLE Project Authors" These changes are applied both to the copyright of source file, and where applicable to copyright statements that are generated by templates. BUG=angleproject:3811 Change-Id: I973dd65e4ef9deeba232d5be74c768256a0eb2e5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1754397 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
James Darpinian 22ec7dc9 2019-08-06T10:10:52 Remove all global constructors and exit time destructors. WebKit compiles with -Wglobal-constructors, so they want this. I decided to do -Wexit-time-destructors at the same time. Bug: angleproject:3439 Bug: angleproject:1459 Change-Id: I4b44ae4f8e6f066e07dc7f9f6ced9a5d49dc8f8a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1738438 Commit-Queue: James Darpinian <jdarpinian@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang ec9ff8ce 2019-07-15T16:59:10 Fix checks for GL_ETC1_RGB8_OES, disable it on D3D11. The GL backend was checking the wrong extension for GL_ETC1_RGB8_OES. WebGL doesn't want to expose compressed formats that are emulated, disable this format in D3D11 where it is always emulated. BUG=98314 Change-Id: I1ba8418ad1578c070891828b87e49cf894dabc29 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1700574 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Geoff Lang d9c17107 2019-07-10T14:56:26 Add support for GL_OES_texture_compression_astc This extension adds 3D compressed texture formats, something ANGLE has not seen before. This requires tracking a compressed block depth for validation and image size computations. Update the ldr and hdr extension checks to be in line with the spec. HDR requires LDR and is not detectable by texture formats alone. Expose all of the ASTC extensions on the GL backend. BUG=angleproject:3675 Change-Id: Id04c7c8ef8541e9556579536cdba899b64303caf Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1695923 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jonah Ryan-Davis beb0eb2d 2019-06-14T15:10:33 Clean up workarounds/features to single location. Rename all workarounds structs to features, and move the lists to a shared location in include/platform (to help with documentation, see: https://cs.chromium.org/chromium/src/ui/gl/gl_switches.cc?sq=package:chromium&g=0&l=69) Bug: angleproject:1621 Change-Id: I4069f08131db5e886047a007efb5d7764dfee5f2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1660952 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jonah Ryan-Davis 776694cd 2019-05-08T10:28:55 Change all ANGLE workarounds to use struct definition with info. Change each workaround from a simple bool to a struct with info including name, workaround set, description, and bug IDs. This will help with future workaround integration with Chrome. Bug: angleproject:1621 Change-Id: Ia27c180abaf845e280060c803e5994cc3152a057 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1593917 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jamie Madill b980c563 2018-11-27T11:34:27 Reformat all cpp and h files. This applies git cl format --full to all ANGLE sources. Bug: angleproject:2986 Change-Id: Ib504e618c1589332a37e97696cdc3515d739308f Reviewed-on: https://chromium-review.googlesource.com/c/1351367 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Geoff Lang 4f2b94cb 2018-11-26T11:38:02 Expose EXT_color_buffer_half_float if RGBA16F is renderable. The EXT_color_buffer_half_float extension spec issue #2 states that none of the added color buffer formats are required to be renderable and the client must check for framebuffer completeness for using them. Chrome exposes the extension if at least RGBA16F is renderable for WebGL. Replicate Chrome's behaviour by loosening our requirements to only expose this extension if an explicit check for RGBA16F renderability succeeds. BUG=angleproject:2984 Change-Id: Id97f3043ebf3fd11b5e9e2d505e57b76baba9716 Reviewed-on: https://chromium-review.googlesource.com/c/1351350 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Geoff Lang 7198ebc4 2018-11-22T14:36:06 GL: Work around Qualcomm sRGB ReadPixels driver bug. When calling glReadPixels on unsized sRGB textures, the data returned is not linearized. Using sized sRGB formats works around this problem. Fix SRGBTextureTest assuming that unsized SRGB formats work in ES3. BUG=angleproject:2977 Change-Id: I413c888ca0c3564ecdc364f3ea693e75ed4f8d6d Reviewed-on: https://chromium-review.googlesource.com/c/1343138 Reviewed-by: Tobin Ehlis <tobine@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Olli Etuaho f2ed2995 2018-10-04T13:54:42 Add support for EXT_texture_compression_bptc After validation, the enums are simply forwarded to the native drivers. The BPTC formats are supported on both OpenGL and D3D. The included test coverage covers the API quite well, but only has basic coverage for correct decoding of texture data. More coverage for texture data could be added later. BUG=angleproject:2869 TEST=angle_end2end_tests Change-Id: I3de37972dcf13c6fa3fc1bc429a2627523a4a082 Reviewed-on: https://chromium-review.googlesource.com/c/1261675 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Yuly Novikov 450bf36f 2018-10-05T12:44:37 Workaround Adreno driver not supporting unsized EXT_texture_rg formats Bug: angleproject:2567 Change-Id: Ia7dfa54f7201866b9d7c0ce5d9cccae06c785542 Reviewed-on: https://chromium-review.googlesource.com/c/1265500 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@google.com> Commit-Queue: Yuly Novikov <ynovikov@google.com>
Yuly Novikov d082819c 2018-06-15T15:51:07 Fix format support conditions This fixes format support tables in formatutils.cpp and formatutilsgl.cpp to conform to the core and extension GLES specs, for a large portion of the formats. ExtsOnly SupportRequirement was enhanced to accept multiple sets of extensions. Format is supported if all the extensions in one of the sets are available. Also fixes determining support for extensions based on those formats. And some fixes to tests which fail due to more strict format support. Bug: angleproject:2567 Change-Id: I6050fff9c597f658fdcea2477bff59a603cdb7e8 Reviewed-on: https://chromium-review.googlesource.com/1105612 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@google.com>
Yuly Novikov f15f886c 2018-06-04T18:59:41 Differentiate texture and renderbuffer framebuffer attachment capabilities ANGLE used to describe the abitily to attach textures and renderbuffers of a specific format to a framebuffer using a single notion of "renderable". However, for some formats, only one can be supported, but not the other. Split TextureCaps::renderable into textureAttachment and renderbuffer. Also, split InternalFormat::renderSupport into textureAttachmentSupport and renderbufferSupport. The only functional change is in a few places which now explicitly check for texture or renderbuffer attachement support. Information in format support tables was duplicated for the two capabilities, so behavior should remain the same. It should be corrected in future CLs. Note: additional information in those tables may need to be added in order to properly support GenerateMipmap and TexStorage2DMultisample, this is beyond the scope of this CL. Bug: angleproject:2567 Change-Id: I18bce4100525be35709d8bbf4de08ec812aab502 Reviewed-on: https://chromium-review.googlesource.com/1086491 Commit-Queue: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Yuly Novikov b4a3f65f 2018-05-28T21:18:55 Fix nativegl::InsertFormatMapping Bug: angleproject:2567 Change-Id: I0f01499855213ef8d4bb772698ad4386e6317d2f Reviewed-on: https://chromium-review.googlesource.com/1075847 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Geoff Lang e88e4548 2018-05-03T15:05:57 Implement extensions exposing ETC2 compressed texture formats in ES2. BUG=angleproject:2527 Change-Id: I000f68366de4119375b6d3c79bc2eff3ebd5db9e Reviewed-on: https://chromium-review.googlesource.com/1042885 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill acf2f3ad 2017-11-21T19:22:44 Apply Chromium style fixes. This addresses several minor code quality issues that are validated in Chromium, but not yet applied to ANGLE: * constructors and destructors must be defined out-of-line * auto is not allowed for simple pointer types * use override everywhere instead of virtual * virtual functions must also be defined out-of-line Slightly reduces binary size for me (~2k on Win, 150k on Linux). Bug: angleproject:1569 Change-Id: I073ca3365188caf5f29fb28d9eb207903c1843e6 Reviewed-on: https://chromium-review.googlesource.com/779959 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 225bfa95 2017-11-10T10:53:57 Always update HALF_FLOAT_OES type to HALF_FLOAT on Desktop GL. TEST=webgl_conformance_gl_passthrough_tests on Linux/Windows BUG=angleproject:2231 Change-Id: I17c7d693e2b75726e2478925e0f22963de6ab819 Reviewed-on: https://chromium-review.googlesource.com/763987 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Jeff Gilbert 9e888a46 2017-11-06T21:34:22 Fix HALF_FLOAT/HALF_FLOAT_OES selection with the ES3 backend. Found via TextureUploadFormatTest. BUG=angleproject:2231 Change-Id: I8f214c4cfe3d8fead9226db20e57f6e6039b5b44 Reviewed-on: https://chromium-review.googlesource.com/756642 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang 3590555d 2017-11-01T10:27:09 Revert BGRA renderability change for ES drivers. While these should be supported on ES drivers, ANGLE's texture format caps generation does not correctly differentiate between renderbuffer and framebuffer attachment formats and leads to assertion failures. BUG=779346 BUG=angleproject:1523 Change-Id: I9a49abdf52ae8b1ef91f88a4434ff8c3f95b025b Reviewed-on: https://chromium-review.googlesource.com/748888 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Bryan Bernhart (Intel Americas Inc) 2a35741b 2017-09-05T10:42:47 WebGLCompatibility: Disable ES format extensions by default. Prevents format validation errors with WebGL context. BUG=angleproject:1523 Change-Id: Iddc525eeb467de0139e166dad0893f3bea3ef35f Reviewed-on: https://chromium-review.googlesource.com/650807 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho 50c562de 2017-06-06T14:43:30 Re-land: Don't expose non-conformant multisampling modes on GL Re-landing with a fallback for failed internal format queries to work around issue seen on Shield TV. Also fixed wrong handling of integer RG formats in isRequiredRenderbufferFormat. Some NVIDIA GL drivers expose non-conformant multisampling modes. The conformance of multisampling modes can be queried using the extension NV_internalformat_sample_query. Use it to filter out the non-conformant modes from the modes that are exposed by ANGLE. The MAX_SAMPLES value and other similar values stored in caps also need to be lowered to match the maximum number of samples exposed for required formats. There seems to be an NVIDIA driver bug related to querying STENCIL_INDEX8 multisample format. Work around this by querying DEPTH24_STENCIL8 instead. There's also some confusion around whether RGB9_E5 should be renderable. Once the floating point texture extensions got rolled into the core GL spec, it was eventually made clear that RGB9_E5 is intended not to be renderable. The extension specs that predate float textures in the core spec do suggest that it would be renderable, but in practice drivers that advertise the extension strings don't reliably implement RGB9_E5 as renderable. Solve this by disabling it as a renderable format and adding an explanatory comment. BUG=chromium:682815 TEST=angle_end2end_tests, dEQP-GLES31.functional.state_query.internal_format.renderbuffer.* Change-Id: I727f03045a1534d6764b571e6d839243705d25b3 Reviewed-on: https://chromium-review.googlesource.com/551957 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Yuly Novikov c8a8b843 2017-06-28T01:16:41 Revert "Don't expose non-conformant multisampling modes on GL" This reverts commit 3cd0dd370f08e7126fe19b761206280c64f80cd1. Reason for revert: crashes on NVIDIA Shield TV https://build.chromium.org/p/chromium.gpu.fyi/builders/Android%20Release%20%28NVIDIA%20Shield%20TV%29/builds/1816 Original change's description: > Don't expose non-conformant multisampling modes on GL > > Some NVIDIA GL drivers expose non-conformant multisampling modes. The > conformance of multisampling modes can be queried using the extension > NV_internalformat_sample_query. Use it to filter out the > non-conformant modes from the modes that are exposed by ANGLE. > > The MAX_SAMPLES value and other similar values stored in caps also > need to be lowered to match the maximum number of samples exposed > for required formats. > > There seems to be an NVIDIA driver bug related to querying > STENCIL_INDEX8 multisample format. Work around this by querying > DEPTH24_STENCIL8 instead. > > There's also some confusion around whether RGB9_E5 should be > renderable. Once the floating point texture extensions got rolled > into the core GL spec, it was eventually made clear that RGB9_E5 > is intended not to be renderable. The extension specs that predate > float textures in the core spec do suggest that it would be > renderable, but in practice drivers that advertise the extension > strings don't reliably implement RGB9_E5 as renderable. Solve this > by disabling it as a renderable format and adding an explanatory > comment. > > BUG=chromium:682815 > TEST=angle_end2end_tests, > dEQP-GLES31.functional.state_query.internal_format.renderbuffer.* > > Change-Id: I2218e3a23ea7b48a0615fea77a91897dc7d5fe9e > Reviewed-on: https://chromium-review.googlesource.com/525515 > Reviewed-by: Geoff Lang <geofflang@chromium.org> > Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> TBR=geofflang@chromium.org,jmadill@chromium.org,cwallez@chromium.org,oetuaho@nvidia.com # Not skipping CQ checks because original CL landed > 1 day ago. Bug: chromium:682815 Change-Id: I1ebdf52c3fab1526f5a561ac4c8555e305ef2243 Reviewed-on: https://chromium-review.googlesource.com/551164 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Olli Etuaho 3cd0dd37 2017-06-06T14:43:30 Don't expose non-conformant multisampling modes on GL Some NVIDIA GL drivers expose non-conformant multisampling modes. The conformance of multisampling modes can be queried using the extension NV_internalformat_sample_query. Use it to filter out the non-conformant modes from the modes that are exposed by ANGLE. The MAX_SAMPLES value and other similar values stored in caps also need to be lowered to match the maximum number of samples exposed for required formats. There seems to be an NVIDIA driver bug related to querying STENCIL_INDEX8 multisample format. Work around this by querying DEPTH24_STENCIL8 instead. There's also some confusion around whether RGB9_E5 should be renderable. Once the floating point texture extensions got rolled into the core GL spec, it was eventually made clear that RGB9_E5 is intended not to be renderable. The extension specs that predate float textures in the core spec do suggest that it would be renderable, but in practice drivers that advertise the extension strings don't reliably implement RGB9_E5 as renderable. Solve this by disabling it as a renderable format and adding an explanatory comment. BUG=chromium:682815 TEST=angle_end2end_tests, dEQP-GLES31.functional.state_query.internal_format.renderbuffer.* Change-Id: I2218e3a23ea7b48a0615fea77a91897dc7d5fe9e Reviewed-on: https://chromium-review.googlesource.com/525515 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Geoff Lang 677bb6ff 2017-04-05T12:40:40 Update checks for floating point renderability. * Expose GL_CHROMIUM_color_buffer_float_rgb and GL_CHROMIUM_color_buffer_float_rgba * Fix many texture formats that were incorrectly checking the wrong extension for support or renderability. * Make all floating point texture extensions dynamically enableable. BUG=angleproject:1958 BUG=angleproject:1715 Change-Id: Iefccc8b5ae5edd97623affa9de05b1d9af5c9598 Reviewed-on: https://chromium-review.googlesource.com/468450 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Geoff Lang 94ba36a7 2017-03-31T13:58:55 Only bind that native GL texture if it should be complete. If extensions such as OES_texture_float_linear are not exposed but the native drive still supports them, we don't want to bind the native texture and instead bind a texture that is known to sample like the incomplete texture. BUG=angleproject:1959 Change-Id: I610dbd93bb566c8eb2166488a7494b74da4aa327 Reviewed-on: https://chromium-review.googlesource.com/465090 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang ca27139e 2017-04-05T12:30:00 Key the format tables on internal format and type. Keying the format tables on internal format alone is not enough to fully validate the unsized formats which require additional type information. This CL has no functional changes, it just splits the tables and updates the calls to GetInternalFormat info to provide type information when the format is not sized. BUG=angleproject:1523 BUG=angleproject:1958 BUG=angleproject:1228 Change-Id: I37e5201e7f54fa8eca01b8a6e64b11a6b94484e7 Reviewed-on: https://chromium-review.googlesource.com/468449 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang f607c60a 2016-09-21T11:46:48 Fix validation of ReadPixels format and type. The validation for ReadPixels allows for two combations of format/type: 1. Based on the current framebuffer's component type. * GL_RGBA/GL_UNSIGNED_BYTE if the framebuffer is a normalized (signed or unsigned). * GL_RGBA_INTEGER/GL_INTEGER if the framebuffer is an integer format. * GL_RGBA_INTEGER/GL_UNSIGNED_INTEGER if the framebuffer is an unsigned integer format. * GL_RGBA/GL_FLOAT if the framebuffer is any type of float framebuffer (added in EXT_color_buffer_float). * These combations are detailed in the ES2 spec on pg 105 or ES3 on pg 193. 2. The implementation read format/type returned from glGetIntegerv. * These formats are added by specs, OES_texture_float, EXT_texture_rg, EXT_read_format_bgra, etc. Update the GL and D3D backends to perform the conversion from GL_HALF_FLOAT to GL_HALF_FLOAT_OES. Continue allowing reading as BGRA_EXT to support Skia. Should be removed in the future. BUG=607283 BUG=angleproject:1478 Change-Id: I0312cad4d5f138ab036f383d221f8ccd19a77f6d Reviewed-on: https://chromium-review.googlesource.com/346232 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill e2e406c3 2016-06-02T13:04:10 Add base::numerics for safe math and conversions. This replaces are "IsUnsignedXXXSafe" family of methods. Also add overflow checks to unpack block sizes. BUG=angleproject:1397 Change-Id: Ib47be149b0486c70f795b0d0f8899441faac9340 Reviewed-on: https://chromium-review.googlesource.com/348062 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Frank Henigman aa57aa4c 2016-01-27T00:02:13 Correct GLES depth 32 format. GL_OES_depth32 is required for DEPTH_COMPONENT32_OES render buffers. This stops Mesa from complaining when using GLES in the back end. BUG=angleproject:1301 Change-Id: I8c6ce6a5ce0cb5bf26157e3bb414f391a41d15c4 Reviewed-on: https://chromium-review.googlesource.com/331359 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Frank Henigman <fjhenigman@chromium.org>
Frank Henigman 9a7e8cab 2016-01-27T00:02:13 Disallow GLES BGRA render buffers. This stops Mesa from complaining when using GLES in the back end. BUG=angleproject:1301 Change-Id: I0b8cb78efea97c1ea0d21cd6b9f656e53b9b6cc2 Reviewed-on: https://chromium-review.googlesource.com/331395 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Commit-Queue: Frank Henigman <fjhenigman@chromium.org>
Frank Henigman 8322cb91 2016-01-27T00:02:13 Corrections to GLES sRGB formats. This stops Mesa from complaining when using GLES 3.0 in the back end. BUG=angleproject:1301 Change-Id: Ib9c0397586a11c407c6aa9ad1544e12b43dd08a7 Reviewed-on: https://chromium-review.googlesource.com/324031 Tryjob-Request: Frank Henigman <fjhenigman@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Geoff Lang a8e3494e 2016-01-20T10:51:40 Don't force using sized internal texture formats for OpenGL ES. * LUMA formats don't have sized versions without specific extensions. * This allows a more direct translation, the driver should do the right thing. BUG=angleproject:884 BUG=angleproject:1145 Change-Id: I2ad13db7216eb7c715621a237b13ae9e3035310a Reviewed-on: https://chromium-review.googlesource.com/322694 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 07651e24 2016-01-20T10:45:08 Fix OpenGL ES extension checks for floating point textures. BUG=angleproject:1145 BUG=angleproject:884 Change-Id: I1ab16a187155573989f0605dbdd06f73ad8c8c58 Reviewed-on: https://chromium-review.googlesource.com/322691 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 6ea6f942 2015-09-11T13:11:22 Support GL_ETC1_RGB8_OES. Passes all dEQP tests related to etc1. Reland: Updated to work with the D3D11 renderer and re-tested with chromium's gles2_conform_test. Change-Id: Id2ce1b0eb58129152f67016ce2dc3ab19208269c Reviewed-on: https://chromium-review.googlesource.com/299770 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez 1d91a7b1 2015-09-11T11:16:26 Formatutilsgl: Make floating point formats renderable on core GL 3.0 Previously they were listed as requiring ARB_color_buffer_float in all cases even if the extension has been merged in Desktop GL 3.0. Make it require Desktop GL 3.0 _or_ the extension. This fixes the PackUnpackTest and BlendMinMaxTest on Mac BUG=angleproject:891 Change-Id: I504d9ed3ed9f1d908964181a6c21b79f1faee9b1 Reviewed-on: https://chromium-review.googlesource.com/298862 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tryjob-Request: Corentin Wallez <cwallez@chromium.org> Tryjob-Request: Jamie Madill <jmadill@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Zhenyao Mo 1170e474 2015-09-11T21:48:20 Revert "Support GL_ETC1_RGB8_OES in the OpenGL renderer." This reverts commit 20bf7034533fbd9ff57296c5f9a5b1b9e06059db. Broke GL2ExtensionTests_compressed_etc1_rgb8_texture_input_run on win bots Change-Id: I2b48aac1512d916671d41e03f0409c404d6d7c88 Reviewed-on: https://chromium-review.googlesource.com/299429 Reviewed-by: Zhenyao Mo <zmo@chromium.org> Tested-by: Zhenyao Mo <zmo@chromium.org>
Geoff Lang 20bf7034 2015-09-11T13:11:22 Support GL_ETC1_RGB8_OES in the OpenGL renderer. Passes all dEQP tests related to etc1. Change-Id: I33f37c44396899d87e9ef19bd7a6e2b2482d232a Reviewed-on: https://chromium-review.googlesource.com/299342 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 1024f382 2015-09-11T19:42:02 Revert "Support GL_ETC1_RGB8_OES in the OpenGL renderer." Failing some ES2 dEQP tests. This reverts commit 4aba0b90ec3d2dcd550ed4111f5739191f022028. Change-Id: Ie39055872d25bce0f387e9e983ebab648c0493f0 Reviewed-on: https://chromium-review.googlesource.com/298972 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 4aba0b90 2015-09-11T13:11:22 Support GL_ETC1_RGB8_OES in the OpenGL renderer. Passes all dEQP tests related to etc1. Change-Id: I3ab2d51b7664cb2411fdc3247ff65a9e3258185a Reviewed-on: https://chromium-review.googlesource.com/299340 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 0d8b7247 2015-09-09T14:56:53 Support ETC2 texture formats with RendererGL. 400 tests in dEQP-GLES3.functional.texture go from unsupported to passing. BUG=angleproject:884 Change-Id: I51927dffbc5931c7d1b80e72f55c620197736724 Reviewed-on: https://chromium-review.googlesource.com/298484 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang df2572c3 2015-09-09T14:55:27 Add LUMA format entries into the tables in formatutilsgl. BUG=angleproject:884 Change-Id: Ie4f378bc18cda57a91c16832c33f0ddc81f9c105 Reviewed-on: https://chromium-review.googlesource.com/298483 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 9bbad18e 2015-09-04T11:07:29 Mark GL_RGB10_A2UI as a renderable format. dEQP-GLES3.functional.fbo.color.tex3d.rgb10_a2ui was already failing but because the framebuffer was marked as unsupported, dEQP considers the test to be passing. BUG=angleproject:1149 BUG=angleproject:1097 Change-Id: I82223e8e927d1fd6d66f75b5fdea7989c92d706d Reviewed-on: https://chromium-review.googlesource.com/298031 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 47f730fa 2015-09-08T14:29:37 Revert "Mark GL_RGB10_A2UI as a renderable format." Fails the dEQP test: dEQP-GLES3.functional.fbo.color.tex3d.rgb10_a2ui BUG=angleproject:1149 This reverts commit d0f9fdc772d0b286a50978f4a16c94e2af3dfee7. Change-Id: I5b76255be3fc1f0734395dac609e2949fc8c8185 Reviewed-on: https://chromium-review.googlesource.com/298010 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang d0f9fdc7 2015-09-04T11:07:29 Mark GL_RGB10_A2UI as a renderable format. BUG=angleproject:1149 Change-Id: Ia808c0d411133d135eef8e90485ba346086f012c Reviewed-on: https://chromium-review.googlesource.com/296964 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 53b8aec0 2015-08-24T10:33:25 Work around deprecated LUMA formats in the core profile. Use R and RG textures with swizzle states to emulate them. A manual blit is required when calling CopyTex[Sub]Image from a RGB[A] framebuffer to an emulated L[A] texture so that the alpha channel ends up in the correct channel of the destination texture. Fixes the following tests when using the core profile: * conformance/extensions/oes-texture-float.html * conformance/extensions/oes-texture-half-float.html * conformance/textures/misc/tex-sub-image-2d.html * conformance/textures/misc/texture-formats-test.html * conformance/textures/misc/texture-npot.html BUG=angleproject:1113 Change-Id: If5540e66d9017596bd83d95ec3ede043cbcfe0d2 Reviewed-on: https://chromium-review.googlesource.com/293905 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 70022972 2015-08-18T17:53:00 Revert "Work around deprecated LUMA formats in the core profile." Caused failures in the WebglConformance.conformance_textures_misc_copy_tex_image_2d_formats test on the ATI FYI waterfall bot. This reverts commit 61f51dc1b7d383bcb3632218cd2434f65cac4b7a. Change-Id: Iddea03d53ae2a9b639e36931f01c1e889e550af4 Reviewed-on: https://chromium-review.googlesource.com/294262 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 61f51dc1 2015-08-13T16:16:56 Work around deprecated LUMA formats in the core profile. Use R and RG textures with swizzle states to emulate them. Fixes the following tests when using the core profile: * conformance/extensions/oes-texture-float.html * conformance/extensions/oes-texture-half-float.html * conformance/textures/misc/tex-sub-image-2d.html * conformance/textures/misc/texture-formats-test.html * conformance/textures/misc/texture-npot.html * conformance/more/functions/copyTexImage2D.html * conformance/more/functions/copyTexSubImage2D.html BUG=angleproject:1113 Change-Id: Iaf4b7b2b0000052b1747f46d90ad45d4cb1f6b50 Reviewed-on: https://chromium-review.googlesource.com/293530 Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang aadf5117 2015-07-29T01:21:20 Fix incorrect extension check. BUG=angleproject:884 Change-Id: Ia201ac60e337fd45ef72cc254bcb36d333418613 Reviewed-on: https://chromium-review.googlesource.com/289333 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 23a2ae0c 2015-07-28T12:42:52 Centralize GL format workarounds. Instead of trying to encapsulate the GL texture format workarounds into tables, use functions that do manual checks for specific cases. Simplifies the logic. Fixes: * conformance/extensions/ext-sRGB.html * conformance/extensions/oes-texture-half-float.html * conformance/extensions/oes-texture-half-float-with-canvas.html * conformance/extensions/oes-texture-half-float-with-image.htm * conformance/extensions/oes-texture-half-float-with-video.html BUG=angleproject:884 Change-Id: Ifb719fff908680fddc7c53a544e2284a42a58356 Reviewed-on: https://chromium-review.googlesource.com/289082 Reviewed-by: Kenneth Russell <kbr@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 8442a612 2015-06-05T16:43:27 Fix texture formats that only require extensions failing requirements checks. Unset version requirements equate to UINT_MAX causing requirements checks for fail for formats that only need extensions such as DXT formats. Fixes tests that require compressed formats. Passes conformance/extensions/webgl-compressed-texture-s3tc.html BUG=angleproject:884 Change-Id: Id810c477a359bf9d35a886c60735a91b51d1e931 Reviewed-on: https://chromium-review.googlesource.com/275693 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang aef1663f 2015-06-05T16:09:55 Add missing GL_STENCIL_INDEX8 format to the formatutilsgl table. Fixes conformance/renderbuffers/framebuffer-object-attachment.html BUG=angleproject:884 Change-Id: I421b563fa8549eb2edc42a9ac1c798fc457256ee Reviewed-on: https://chromium-review.googlesource.com/275690 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Corentin Wallez 322653bf 2015-06-17T18:33:56 Fix Chromium build of angle_end2end_tests BUG=angleproject:892 Change-Id: I9922046fc9e4d82d7034405f5952263f982c6529 Reviewed-on: https://chromium-review.googlesource.com/278159 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Corentin Wallez <cwallez@chromium.org>
Geoff Lang fd216c41 2015-05-27T16:12:30 Support BGRA texture by remapping the internal format to RGBA. The format is still passed as BGRA to the driver so that the data can be properly unpacked. BUG=angleproject:884 Change-Id: I767626c818ce1a3c5a4739f07aa623bf8a9ae377 Reviewed-on: https://chromium-review.googlesource.com/273162 Reviewed-by: Brandon Jones <bajones@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 6683032d 2015-05-27T16:11:32 Add remaining unsized formats to the GL format tables. BUG=angleproject:884 Change-Id: I53e7ff9e35b820573691df0d23b41ef45e2a07d0 Reviewed-on: https://chromium-review.googlesource.com/273590 Tested-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org>
Geoff Lang 08dcfed6 2015-05-25T13:38:42 Encapsulate GL version and standard into a struct and enum. Change-Id: I9f51971c1bfd51424605b2687b5fd107d58c9a67 Reviewed-on: https://chromium-review.googlesource.com/273139 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/273572 Reviewed-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 51d4f044 2015-05-27T21:10:42 Revert "Encapsulate GL version and standard into a struct and enum." Linux didn't like compiling this. This reverts commit 03f589122ed796060f1345f9ccfc64455c547fef. Change-Id: Ifd0824caeb02791b4acc5e4bca330ecdc8164b11 Reviewed-on: https://chromium-review.googlesource.com/273583 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 03f58912 2015-05-25T13:38:42 Encapsulate GL version and standard into a struct and enum. Change-Id: Ib3c37627298976040d5a333f4c845a7b2620dd30 Reviewed-on: https://chromium-review.googlesource.com/273139 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang f34d1db9 2015-05-20T14:10:46 Add table entries for almost all the remaining GL texture formats. BUG=angleproject:884 BUG=angleproject:967 Change-Id: I113757dd9e1fae8fe0241a7286be979a90891b53 Reviewed-on: https://chromium-review.googlesource.com/270275 Reviewed-by: Brandon Jones <bajones@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/273135
Geoff Lang 859dcb88 2015-05-25T15:12:54 Revert "Add table entries for almost all the remaining GL texture formats." Missing include of <limits> for linux. This reverts commit aa3a5fadebb2bad0be07eb2963a9d23f901c4c49. Change-Id: Iafebfbc6154b4fe3a94e3f8b91b5ff496631c1f1 Reviewed-on: https://chromium-review.googlesource.com/273134 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang aa3a5fad 2015-05-20T14:10:46 Add table entries for almost all the remaining GL texture formats. BUG=angleproject:884 BUG=angleproject:967 Change-Id: I0b05841272f4410c33ee4e4c3654846f07b7c39b Reviewed-on: https://chromium-review.googlesource.com/270275 Reviewed-by: Brandon Jones <bajones@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang dab84368 2015-03-02T15:43:57 Add texture format utilities for GL and generate GL texture caps. BUG=angleproject:884 Change-Id: Ib1b13f59a6b21399c4b35695c704c369f572914e Reviewed-on: https://chromium-review.googlesource.com/264399 Tested-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Geoff Lang d16daa29 2015-04-07T19:27:57 Revert "Add texture format utilities for GL and generate GL texture caps." This reverts commit 69bde01adf1f9d94cb1ea91c2902267ef3340f02. Change-Id: If21c22e91cf5d72364839bbcc21cb83901a3f2cd Reviewed-on: https://chromium-review.googlesource.com/264418 Reviewed-by: Geoff Lang <geofflang@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>
Geoff Lang 69bde01a 2015-03-02T15:43:57 Add texture format utilities for GL and generate GL texture caps. BUG=angleproject:884 Change-Id: Iba0108b22e6a404842ec1013d22c00d206c865d3 Reviewed-on: https://chromium-review.googlesource.com/255512 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Brandon Jones <bajones@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>