src/tests/gl_tests/D3DTextureTest.cpp


Log

Author Commit Date CI Message
Tom Sepez 25390156 2025-08-21T00:13:19 Suppress unsafe buffers on a file-by-file basis in src/ [1 of N] In this CL, we suppress many files but stop short of actually enabling the warning by not removing the line from the unsafe_buffers_paths.txt file. That will happen in a follow-on CL, along with resolving any stragglers missed here. This is mostly a manual change so as to familiarize myself with the kinds of issues faced by the Angle codebase when applying buffer safety warnings. -- Re-generate affected hashes. -- Clang-format applied to all changed files. -- Add a few missing .reserve() calls to vectors as noticed. -- Fix some mismatches between file names and header comments. -- Be more consistent with header comment format (blank lines and trailing //-only lines when a filename comment adjoins license boilerplate). Bug: b/436880895 Change-Id: I3bde5cc2059acbe8345057289214f1a26f1c34aa Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6869022 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Alexey Knyazev 640e3716 2024-07-04T00:00:00 Do not rely on 16-bit color read conversions in tests These conversions are not specified. D3DTextureClearTest should assert that all bits are cleared. Texture2DNorm16TestES3.TextureNorm16*TextureTest should not use 16-bit framebuffer attachments as they are tested separately. Bug: angleproject:40096653 Bug: angleproject:351644552 Change-Id: Ib22e9fcc3b643725f25f6ed880569888107928ad Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5683107 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
Alexey Knyazev 58dc069c 2024-07-04T00:00:00 Rename 16-bit EXPECT_PIXEL test helpers Do not use UI suffix as the format is normalized. Bug: None Change-Id: Ib635397f2cdec02806c2c31484820b9b6964a066 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5680605 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
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>
Saifuddin Hitawala 275e6f4f 2024-02-02T16:46:14 D3D: Add multiplanar support to d3d11 glTexSubImage2D Add multiplanar format support to Angle's D3D11 glTexSubImage2D. This is needed with multiplanar shared images, where we write all planes of a d3d shared image through WritePixelsYUV in raster decoder and need to do this via an intermediate texture for d3d11. This change checks for multiplanar format supported by Image11 and then goes through TextureD3D::commitRegion and performs copyTexture and then copySubResource. Added necessary test that tests for full texture copy and a subregion copy and reads back and verifies. Bug: chromium:40262482 Change-Id: I74c9978e62339375f6623f7f0a609bcb16c4b970 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5263039 Reviewed-by: Vasiliy Telezhnikov <vasilyt@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Saifuddin Hitawala <hitawala@chromium.org>
Saifuddin Hitawala a64537f9 2023-07-14T17:06:37 Angle: Copy multiplanar d3d11 texture for readPixels This change performs a copy to an intermediate texture for multiplanar d3d11 textures before reading from the source texture. This is needed as we cannot read a plane directly from a multiplanar d3d11 texture. It also passes the correct format for the plane for multiplanar formats when initializing the texture instead of getting the format using the internal format. We also add a unittest performing glReadPixels for NV12/P010/P016 formats. Bug: angleproject:7998, chromium:1463924 Change-Id: I9a1708f5a846ace28ac3b6593ea80f1863348333 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4688118 Commit-Queue: Vasiliy Telezhnikov <vasilyt@chromium.org> Auto-Submit: Saifuddin Hitawala <hitawala@chromium.org> Reviewed-by: Vasiliy Telezhnikov <vasilyt@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Sunny Sachanandani 32072905 2022-08-25T15:17:13 d3d11: Support rendering to GL_TEXTURE_2D target for YUV images YUV D3D11 texture plane EGLImages can be bound to TEXTURE_EXTERNAL_OES, but don't support rendering because ExternalImageSibling11::IsYUV() returns true. While it might appear that IsYUV() should return true for YUV D3D11 textures, the EGLImage siblings are actually for individual planes which are R/RG 8/16 and they can indeed be bound as render targets if we just return false for IsYUV(). This CL makes IsYUV() return false and adds a test for rendering to YUV EGLImages. Bug: angleproject:7610 Change-Id: I6c95a9521448e83a53153c1efaca70bd73e49818 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3856660 Auto-Submit: Sunny Sachanandani <sunnyps@chromium.org> Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Eddie Hatfield 89e38b57 2022-06-22T15:04:08 Refactor to use ANGLETest vs ANGLETestWithParam Bug: angleproject:6747 Change-Id: I72ad52d0268eae0e1a401f12f3e94cc5efa402f2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3719002 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Cody Northrop <cnorthrop@google.com>
Sunny Sachanandani c76fb2d8 2022-05-18T15:29:19 Enable EXT_texture_norm16 on ES2/D3D11 Windows HDR regressed recently due to format checks added in Skia: crbug.com/1324371 Skia thinks R16/RG16 texturing is not supported, which it bases on GL_EXT_texture_norm16 not being reported on its ES2 context. Migrating to ES3 for the compositor context is a large project, and reverting the format checks in Skia is also not desirable because it helps catch bugs in ANGLE-Metal. Enable texture_norm16 on ES2 for R16/RG16 texturing since Chromium needs it for HDR video playback for P010 textures. This used to work before even though the extension wasn't advertised. Also, enable the P010 test on ES2/D3D11 which was previously ES3/D3D11 only. Bug: angleproject:7322, chromium:1324371 Change-Id: I4c2527996e37ba5365bb94b5764413e5a9fdda7b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3645892 Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org> Auto-Submit: Sunny Sachanandani <sunnyps@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Kenneth Russell <kbr@chromium.org>
Jamie Madill 23b16743 2021-09-14T10:29:14 Fix compilation when disabling D3D back-ends. Common code areas weren't compiling when disabling combinations of the D3D9 and D3D11 back-ends. With manual testing this fixes various combinations of angle_enable_d3d9/d3d11/gl. Bug: angleproject:5925 Change-Id: Ie14f2b4c6169cf96c662e7ae6999751007d9adb0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3162836 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Sunny Sachanandani 46555145 2021-09-02T14:55:02 d3d11: Allow binding R/RG texture to EGLImage Also allows GL_RED/RG/R16/RG16_EXT as well as GL_RGB10_A2_EXT which was left out previously by accidently to match Chromium behavior. Adapts the existing ClearTextureImage test to parameterize over a number of texture formats. Bug: angleproject:6369 Change-Id: I91110a06b08379a3067a2161e345258415cd5e16 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3140744 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org>
Sunny Sachanandani 923f6a6f 2021-04-06T15:30:26 Ignore internal format attribute for YUV D3D11 EGLImages Internal format doesn't play any role in this case, and causes confusion due to mixing sized and unsized formats resulting in more complicated code in Chromium. Bug: angleproject:5538, chromium:1116101 Change-Id: Ie200026f014850053108aa0416e1da15bcda7b84 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2808855 Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Austin Sullivan f18b92ad 2021-02-17T19:40:53 testing: Mark uninstantiated GL & EGL test suites googletest CL 315255779 causes test binaries to fail when they include test suites / parametrized tests that are not instantiated, and when they include empty test suites. This CL uses the GTEST_ALLOW_UNINSTANTIATED_PARAMETERIZED_TEST() macro to annotate the suites / tests that are causing test failures. This is necessary to get googletest rolled past CL 315255779. Bug: chromium:1163396 Change-Id: I05c0619186ffc265b8e32e8b69d6680a6acdbb48 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2701292 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Sunny Sachanandani 137271ff 2021-01-13T14:34:12 Support specifying array slice for D3D11 texture EGLImage Client can specify array slice for creating the SRV/RTV with EGL_D3D11_TEXTURE_ARRAY_SLICE_ANGLE. Test: D3DTextureTest.TextureArrayImage* Bug: angleproject:5538, chromium:1116101 Change-Id: I81cb2823df2145f1d05ad1526b0e36d6a0724d5e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2628609 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org>
Sunny Sachanandani 198dc345 2020-08-06T16:32:03 Support importing NV12/P010/P016 D3D textures as EGLImage Allow importing individual planes of NV12/P010/P016 D3D textures with supported SRV/RTV formats. Restrict these to GL_TEXTURE_EXTERNAL_OES to limit to using as shader inputs or render targets and prevent unsupported operations like ReadPixels. Test: D3DTextureYUVTest* Bug: angleproject:5538, chromium:1116101 Change-Id: If5bf54f4f75bb2c703890ce3f5fbd67e4461c98f Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2338827 Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Jamie Madill 56663dbf 2020-11-19T21:21:19 EGL: Expose device query as a client extension. This matches the extension spec. Previously we were exposing the ext as a normal display extension. The extension should work without needing a display. Because the extension requires a non-null device for every display we also add a MockDevice class to handle back-ends which don't implement any attribute query extensions. By default the device query ext does not expose any way to use devices so this works fine. Bug: angleproject:5372 Change-Id: I474310a86aff6a83bd6f9a6b21c8a07c649f306d Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2551543 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Tobin Ehlis 1a01b4b3 2019-11-11T16:41:07 Refactor end2end test macros This is a foundational CL to enabling the end2end tests on swiftshader. Refactored infrastructure with new ANGLE_INSTANTIATE_TEST_ES* macros that will run tests over all various combinations of all platforms for different ES versions. Just skipping failing tests initially to get the refactor landed. Bug: angleproject:4081 Bug: angleproject:4092 Change-Id: I017f6c3267179e49b6ae08cc7488096b423dcdb5 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1904635 Commit-Queue: Tobin Ehlis <tobine@google.com> Reviewed-by: Courtney Goeltzenleuchter <courtneygo@google.com>
Sunny Sachanandani c1af9abf 2019-08-28T14:35:32 Add support for overriding internal format for D3D11 texture EGLImages Add an optional EGL_D3D11_TEXTURE_FORMAT_ANGLE attribute that is the GL internal format to use for EGLImage being created. This will be used for RGB emulation of swap chain texture backed WebGL contexts in Chrome when they have alpha:false set. Without RGB emulation it is possible to observe side-effects of the underlying swap chain being RGBA such as reading/writing the alpha channel, BlitFramebuffer working/not working when expected, etc. Also document creating EGLImages from D3D11 textures in the existing EGL_ANGLE_d3d_texture_client_buffer extension along with RGB emulation. Bug: chromium:699566, chromium:939657 Change-Id: I4931cb7bdc46e9bc6debd56b79ecc10ea27bd78b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1777099 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org>
Yuly Novikov bd4ff479 2019-07-19T22:08:17 Revert "Reland "Temporarily disable creating D3D debug device."" This reverts commit 6064e6ab6bc7355b410543301a578d22d2f6e477. Reason for revert: flakiness should be fixed by https://chromium-review.googlesource.com/c/angle/angle/+/1709726 Original change's description: > Reland "Temporarily disable creating D3D debug device." > > This reverts commit 28394c2295335929c17bbfe0ab74f923cd234ff2. > > Reason for revert: may be the cause of flakiness on Win10 Debug (NVIDIA) per http://crbug.com/972914 . > > Original change's description: > > Revert "Temporarily disable creating D3D debug device." > > > > This reverts commit 3d544fffe7ff9284b21e3a15f638297c827bbc21. > > > > Reason for revert: Seems like flakiness is not related. > > > > Suppress D3D11 test failures uncovered by re-enabling D3D debug device: > > ComputeShaderTest.DispatchCompute > > Texture2DTestES3.TextureImplPropogatesDirtyBits > > D3DTextureTestMS.* > > > > Also a small fix to ANGLETestBase::checkD3D11SDKLayersMessages > > to clear reported messages, otherwise the failures are also reported > > for tests following the one with the actual failure. > > > > Original change's description: > > > Temporarily disable creating D3D debug device. > > > > > > To diagnose whether Windows Intel end2end tests flakiness > > > is related to creating debug device and new version of Windows SDK. > > > > > > Bug: angleproject:3153 > > > Change-Id: Ica7eae3fe875e22203b6dfd98b83604d66a97737 > > > Reviewed-on: https://chromium-review.googlesource.com/c/1476954 > > > Reviewed-by: Geoff Lang <geofflang@chromium.org> > > > Commit-Queue: Yuly Novikov <ynovikov@chromium.org> > > > > Bug: angleproject:3153, angleproject:3493 > > Bug: angleproject:3501, angleproject:3512, angleproject:3513 > > > > Change-Id: I232da72aa09c2b9230cf179dd54e1731f8365f8e > > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1480854 > > Reviewed-by: Yuly Novikov <ynovikov@chromium.org> > > Reviewed-by: Jamie Madill <jmadill@chromium.org> > > Commit-Queue: Yuly Novikov <ynovikov@chromium.org> > > TBR=ynovikov@chromium.org,geofflang@chromium.org,jmadill@chromium.org > > Change-Id: I38a5cc9bb6ebcd50e97e40cc972a82679e73732a > No-Presubmit: true > No-Tree-Checks: true > No-Try: true > Bug: angleproject:3153, angleproject:3493, angleproject:3501, angleproject:3512, angleproject:3513 > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1652784 > Reviewed-by: Kenneth Russell <kbr@chromium.org> > Commit-Queue: Kenneth Russell <kbr@chromium.org> TBR=ynovikov@chromium.org,geofflang@chromium.org,kbr@chromium.org,jmadill@chromium.org Bug: angleproject:3153, angleproject:3493, angleproject:3501, angleproject:3513 Change-Id: I16eff79172dcfa2dd6d4f6445a74c9c65c1bd27c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1710861 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Sunny Sachanandani f9686af0 2019-06-04T17:49:43 Add support for D3D11 texture backed EGLImages Implement EGL_ANGLE_image_d3d11_texture extension. Images created with this extension might not be renderable based on bind flags and resource usage of the client provided texture in which case attaching them to a framebuffer won't succeed. The intended use case is to bind the front and back buffers of a swap chain to GL textures that can be used for rendering in the case of the back buffer and as a shader input for the front buffer. Bug: chromium:939655 Change-Id: Ic3328e831880292217b88be84740740df6031fa6 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1646732 Commit-Queue: Sunny Sachanandani <sunnyps@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Kenneth Russell 6064e6ab 2019-06-11T04:01:12 Reland "Temporarily disable creating D3D debug device." This reverts commit 28394c2295335929c17bbfe0ab74f923cd234ff2. Reason for revert: may be the cause of flakiness on Win10 Debug (NVIDIA) per http://crbug.com/972914 . Original change's description: > Revert "Temporarily disable creating D3D debug device." > > This reverts commit 3d544fffe7ff9284b21e3a15f638297c827bbc21. > > Reason for revert: Seems like flakiness is not related. > > Suppress D3D11 test failures uncovered by re-enabling D3D debug device: > ComputeShaderTest.DispatchCompute > Texture2DTestES3.TextureImplPropogatesDirtyBits > D3DTextureTestMS.* > > Also a small fix to ANGLETestBase::checkD3D11SDKLayersMessages > to clear reported messages, otherwise the failures are also reported > for tests following the one with the actual failure. > > Original change's description: > > Temporarily disable creating D3D debug device. > > > > To diagnose whether Windows Intel end2end tests flakiness > > is related to creating debug device and new version of Windows SDK. > > > > Bug: angleproject:3153 > > Change-Id: Ica7eae3fe875e22203b6dfd98b83604d66a97737 > > Reviewed-on: https://chromium-review.googlesource.com/c/1476954 > > Reviewed-by: Geoff Lang <geofflang@chromium.org> > > Commit-Queue: Yuly Novikov <ynovikov@chromium.org> > > Bug: angleproject:3153, angleproject:3493 > Bug: angleproject:3501, angleproject:3512, angleproject:3513 > > Change-Id: I232da72aa09c2b9230cf179dd54e1731f8365f8e > Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1480854 > Reviewed-by: Yuly Novikov <ynovikov@chromium.org> > Reviewed-by: Jamie Madill <jmadill@chromium.org> > Commit-Queue: Yuly Novikov <ynovikov@chromium.org> TBR=ynovikov@chromium.org,geofflang@chromium.org,jmadill@chromium.org Change-Id: I38a5cc9bb6ebcd50e97e40cc972a82679e73732a No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: angleproject:3153, angleproject:3493, angleproject:3501, angleproject:3512, angleproject:3513 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1652784 Reviewed-by: Kenneth Russell <kbr@chromium.org> Commit-Queue: Kenneth Russell <kbr@chromium.org>
Yuly Novikov 28394c22 2019-02-21T03:24:58 Revert "Temporarily disable creating D3D debug device." This reverts commit 3d544fffe7ff9284b21e3a15f638297c827bbc21. Reason for revert: Seems like flakiness is not related. Suppress D3D11 test failures uncovered by re-enabling D3D debug device: ComputeShaderTest.DispatchCompute Texture2DTestES3.TextureImplPropogatesDirtyBits D3DTextureTestMS.* Also a small fix to ANGLETestBase::checkD3D11SDKLayersMessages to clear reported messages, otherwise the failures are also reported for tests following the one with the actual failure. Original change's description: > Temporarily disable creating D3D debug device. > > To diagnose whether Windows Intel end2end tests flakiness > is related to creating debug device and new version of Windows SDK. > > Bug: angleproject:3153 > Change-Id: Ica7eae3fe875e22203b6dfd98b83604d66a97737 > Reviewed-on: https://chromium-review.googlesource.com/c/1476954 > Reviewed-by: Geoff Lang <geofflang@chromium.org> > Commit-Queue: Yuly Novikov <ynovikov@chromium.org> Bug: angleproject:3153, angleproject:3493 Bug: angleproject:3501, angleproject:3512, angleproject:3513 Change-Id: I232da72aa09c2b9230cf179dd54e1731f8365f8e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1480854 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill 5cbaa3f8 2019-05-07T15:49:22 Don't inherit ANGLETest SetUp and TearDown. Instead of inheriting from testing::Test's SetUp and TearDown we add new methods 'testSetUp' and 'testTearDown'. This helps prevent a common error of forgetting to call the base class method. Also add a check in the ANGLETest destructor that SetUp and TearDown have been called. Bug: angleproject:3393 Change-Id: Iab211305cc06ffea9ca649e864ddc9b180f2cba0 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1593960 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill b8149075 2019-04-30T16:14:44 Clean up ANGLE test extension functions. None of these functions needed to be member functions. Also make the naming more consistent. Bug: angleproject:3393 Change-Id: I7aafe2269a48af703a87bd9a8cf4cfab9e177dd3 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1574673 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill ba319ba3 2018-12-29T10:29:33 Re-land "Load entry points dynamically in tests and samples." Fixes the Android/ChromeOS/Fuchsia builds by using consistent EGL headers. This CL adds a dynamic loader generator based on XML files. It also refactors the entry point generation script to move the XML parsing into a helper class. Additionally this includes a new GLES 1.0 base header. The new header allows for function pointer types and hiding prototypes. All tests and samples now load ANGLE dynamically. In the future this will be extended to load entry points from the driver directly when possible. This will allow us to perform more accurate A/B testing. The new build configuration leads to some tests having more warnings applied. The CL includes fixes for the new warnings. Bug: angleproject:2995 Change-Id: I5a8772f41a0f89570b3736b785f44b7de1539b57 Reviewed-on: https://chromium-review.googlesource.com/c/1392382 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Yuly Novikov 9f088621 2018-12-29T20:46:15 Revert "Load entry points dynamically in tests and samples." This reverts commit 03923558a7103827ffec6a4d2a1453ed91f01c6f. Reason for revert: fails compilation on Android, ChromeOS and Fuchsia during roll https://chromium-review.googlesource.com/c/chromium/src/+/1392624 Original change's description: > Load entry points dynamically in tests and samples. > > This CL adds a dynamic loader generator based on XML files. It also > refactors the entry point generation script to move the XML parsing > into a helper class. > > Additionally this includes a new GLES 1.0 base header. The new > header allows for function pointer types and hiding prototypes. > > All tests and samples now load ANGLE dynamically. In the future this > will be extended to load entry points from the driver directly when > possible. This will allow us to perform more accurate A/B testing. > > The new build configuration leads to some tests having more warnings > applied. The CL includes fixes for the new warnings. > > Bug: angleproject:2995 > Change-Id: I6726d4163f7a6e54d2482f094c0a952f59702a05 > Reviewed-on: https://chromium-review.googlesource.com/c/1359516 > Commit-Queue: Jamie Madill <jmadill@chromium.org> > Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> TBR=ynovikov@chromium.org,jmadill@chromium.org,syoussefi@chromium.org Change-Id: I902bec2d733c2b879be29c02ab52a0b7d4eaa077 No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: angleproject:2995 Reviewed-on: https://chromium-review.googlesource.com/c/1392381 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Jamie Madill 03923558 2018-12-29T10:29:33 Load entry points dynamically in tests and samples. This CL adds a dynamic loader generator based on XML files. It also refactors the entry point generation script to move the XML parsing into a helper class. Additionally this includes a new GLES 1.0 base header. The new header allows for function pointer types and hiding prototypes. All tests and samples now load ANGLE dynamically. In the future this will be extended to load entry points from the driver directly when possible. This will allow us to perform more accurate A/B testing. The new build configuration leads to some tests having more warnings applied. The CL includes fixes for the new warnings. Bug: angleproject:2995 Change-Id: I6726d4163f7a6e54d2482f094c0a952f59702a05 Reviewed-on: https://chromium-review.googlesource.com/c/1359516 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Jamie Madill 35cd7332 2018-12-02T12:03:33 Refactor test shader style. This change enforces a lot more consistency. We pass const char * to the Compile functions instead of std::string. Also fixes the indentation of C++11 block comments to be more consistent. Bug: angleproject:2995 Change-Id: Id6e5ea94055d8cbd420df4ea2e81b2d96cb5ce78 Reviewed-on: https://chromium-review.googlesource.com/c/1357103 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: 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>
Shahbaz Youssefi 0864a7ac 2018-11-07T15:50:15 Vulkan: Enable end2end tests for ES2_VULKAN everywhere Used a script to find test files that have more ES2_OPENGL() invocations than ES2_VULKAN(), and added ES2_VULKAN() to those. There may be false negatives. Bug: angleproject:1578 Change-Id: I938eb3571c909879e9276b355a9f1d324880f99a Reviewed-on: https://chromium-review.googlesource.com/c/1324350 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
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>
Yunchao He 9550c603 2018-02-13T14:47:05 Code refactoring for end2end tests. This change: 1) uses the new style ANGLE_SKIP_TEST_IF to skip tests. 2) replaces compile-time definition for OSX to skip tests by run-time function IsOSX() to skip tests, in order to align with ANGLE_SKIP_TEST_IF. 3) fixes a couple of typos. BUG=angleproject:2005 Change-Id: I5af77d82257536b9eb79e26afa502f5b91ff6d31 Reviewed-on: https://chromium-review.googlesource.com/915861 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Brandon Jones f0d3b901 2018-02-08T08:57:14 Enable Multisample Sources in copyImageInternal For D3D11 This enables the copyTexImage2D and copyTexSubImage2D to handle multisampled source through through the blit path. We attempt to use a cached texture as an intermediate to resolve to, or create a new texture if there's a mismatch. The resolved texture is sent through blit11::copyTexture as normal. BUG:angleproject:2316 Change-Id: Ie3490b45b1a368300ee13fe5a0b35dc3920364ff Reviewed-on: https://chromium-review.googlesource.com/911889 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Olli Etuaho d66e1939 2018-01-17T11:36:24 Allow creating EGL pbuffers from typeless D3D textures A new extension EGL_ANGLE_d3d_typeless_texture_client_buffer is added that allows creating EGL pbuffers from typeless D3D textures. The extension increases the flexibility of the API compared to plain EGL_ANGLE_D3D_texture_client_buffer. The colorspace for the created EGL pbuffer can be set by using the EGL_GL_COLORSPACE attribute. Internally this sets the ANGLE format of the buffer. There are new ANGLE formats that are used specifically for typeless textures, separate ones for SRGB and linear views into the D3D textures. The extension is only supported on the D3D11 backend of ANGLE. BUG=angleproject:2300 TEST=angle_white_box_tests Change-Id: I6a6cb873d2cc0dca0b7f18a0f2cd35e7bafcb7d8 Reviewed-on: https://chromium-review.googlesource.com/873917 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho ceffd20c 2018-01-08T16:39:45 Set colorspace of D3D pbuffers according to DXGI format When a EGL pbuffer is created based on a D3D SRGB texture using EGL_ANGLE_d3d_texture_client_buffer, SRGB conversions are performed as if it was an SRGB surface. The value of EGL_GL_COLORSPACE now reflects that correctly. If the pbuffer is bound to a texture and used as a framebuffer attachment, querying GL_FRAMEBUFFER_COLOR_ATTACHMENT also reflects that correctly. The behavior is the same on both the D3D backend, where there is no native interop involved, and on the GL backend using WGL_NV_DX_interop(2). There are a few limitations on the GL backend that relies on native interop: 1. SRGB conversion for textures created this way can't be disabled using the GL_FRAMEBUFFER_SRGB_EXT toggle that's exposed in ANGLE through EXT_sRGB_write_control. This is now documented in the EGL_ANGLE_d3d_texture_client_buffer spec. On the D3D backend this is not a problem since EXT_sRGB_write_control is not supported either way. 2. Creating a pbuffer out of a D3D11 texture with the format DXGI_FORMAT_B8G8R8A8_UNORM_SRGB does not work, even though it was listed as one of the supported formats in the EGL_ANGLE_d3d_texture_client_buffer spec. It's now mentioned that support for this format is optional. BUG=angleproject:2300 TEST=angle_white_box_tests Change-Id: I70ee0646680805e4469291a5b2ce59e92fda009e Reviewed-on: https://chromium-review.googlesource.com/866743 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Corentin Wallez 3acfc625 2017-12-12T13:25:40 Add test for Chromium's EGL_D3D_TEXTURE pbuffer creation When creating the pbuffer, Chromium specifies EGL_WIDTH and EGL_HEIGHT attributes that are unnecessary because they are extracted from the D3D11 texture passed as <buffer> to eglCreatePbufferFromClientBuffer. This is a regression test for crbug.com/794086 where a change to ValidateCreatePbufferFromClientBuffer made EGL_WIDTH and EGL_HEIGHT invalid for <buftype> EGL_D3D_TEXTURE and caused Chromium to fail creating the pbuffer, causing all black rendering. BUG=chromium:794086 Change-Id: I262fd0991e0f46f255aeac25528ddb4a62fa1309 Reviewed-on: https://chromium-review.googlesource.com/822296 Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Corentin Wallez <cwallez@chromium.org>
Sami Väisänen 935cb7c5 2017-11-08T15:53:41 Support B8G8R8A8_UNORM_SRGB as D3D11 texture format Support B8G8R8A8_UNORM_SRGB as D3D11 texture format. BUG=angleproject:2172 Change-Id: I2f15a55123601735d7fc6caa40bb056243a91b44 Reviewed-on: https://chromium-review.googlesource.com/758600 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Olli Etuaho a20af6d7 2017-09-18T13:32:29 Use C++11 raw string literals instead of SHADER_SOURCE macro This is better in many ways: 1. It doesn't confuse clang format 2. \n doesn't need to be included after preprocessor directives like the version directive. 3. It's using built-in functionality instead of something custom. Raw string literals should be the preferred way to include shader source in C++ files going forward. BUG=angleproject:2157 TEST=angle_end2end_tests Change-Id: I8b236a6e2d5c25d920297e5bc5b5b143eddeba1f Reviewed-on: https://chromium-review.googlesource.com/671046 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Jamie Madill 3ed60424 2017-09-07T11:32:52 Test using the same texture with multiple samplers. This covers a regression introduced with texture dirty bits. BUG=angleproject:1387 Change-Id: Ic8112718c185298ef54ec5a6f6ed2cd519e010d6 Reviewed-on: https://chromium-review.googlesource.com/653586 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Jamie Madill a42a4e5e 2017-08-28T14:02:12 D3D11: Copy external offscreen texture when required. In some cases ANGLE gets an external back buffer texture for our SwapChain11 class, and in some of these cases we get an offscreen texture that can't be used as a shader resource. The becomes a problem for some copy operations that use a shader to convert texture formats. Work around this problem by making a shadow copy of the texture that has sampling enabled - it is possible to use CopyResource to copy between them. BUG=chromium:752917 Change-Id: Ib757949d3d06295a118b055bf37311f820f7149c Reviewed-on: https://chromium-review.googlesource.com/638551 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Jamie Madill <jmadill@chromium.org>
Bryan Bernhart (Intel Americas Inc) caf20889 2017-07-05T15:26:44 Fix incorrect quality level with depth-stencil buffer and MSAA configs. Using a depth buffer format requires that the DSV and RTV have equal quality levels; otherwise, the bound render target will discard writes. BUG=angleproject:1917 Change-Id: Ife25b0a8958fa2b31b43a0d877d27e440916a9bf Reviewed-on: https://chromium-review.googlesource.com/560716 Reviewed-by: Bryan Bernhart <bryan.bernhart@intel.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Jamie Madill fe54834f 2017-06-19T11:13:24 Proliferate gl::Context. This enables a few small things: it will enable making the platform a property of the Display rather than a global. The same goes for the global logging annotator. Also it ensures all back-end implementations have access to the GL / EGL state when available. Also introduces a smart pointer helper class to angleutils for objects that prefer to be destroyed with a context (gl::Context/egl::Display) parameter. We were using std::unique_ptr in a few places that would not work well with these objects. BUG=angleproject:1156 Change-Id: I59e288a3d6f766ff8a0f4b48ff3a1fbf7489daba Reviewed-on: https://chromium-review.googlesource.com/529706 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Bryan Bernhart (Intel Americas Inc) 151d5de6 2017-04-13T09:52:23 Enable MSAA for texture client buffers Enhancement to the EGL_ANGLE_d3d_texture_client_buffer extension to allow use of a shared D3D texture that can be multi-sampled. BUG=angleproject:1917 Change-Id: Iaf59bbd575a5dfb29345f55b549bc4017bf2d7d0 Reviewed-on: https://chromium-review.googlesource.com/446907 Reviewed-by: Bryan Bernhart <bryan.bernhart@intel.com> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Geoff Lang <geofflang@chromium.org>
Geoff Lang 067cdb4a 2017-04-05T13:42:49 Create depth stencils for D3D texture EGL surfaces. BUG=angleproject:1144 Change-Id: I42d80293c06e40197fe100bcac31a5c6bd414edf Reviewed-on: https://chromium-review.googlesource.com/469106 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Jamie Madill 14154827 2017-02-14T13:53:26 Fix D3DTextureTest. This test was not releasing resource in the correct order. BUG=chromium:691136 Change-Id: Ie95c4d595eac49da2707afde033eff744131fcbe Reviewed-on: https://chromium-review.googlesource.com/442684 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Yuly Novikov 77c13aaf 2016-10-27T22:06:51 Disable D3DTextureTest on Windows Intel OpenGL BUG=angleproject:1585 Change-Id: I550750e0e94bd15c0b076f911d05f8dd92e4a202 Reviewed-on: https://chromium-review.googlesource.com/404499 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Geoff Lang 2018c0ba 2015-12-08T11:48:51 Add a EGL_ANGLE_d3d_texture_client_buffer extension. Allows creation of pbuffers from D3D texture objects. BUG=540829 BUG=angleproject:1144 Change-Id: If8ea717ef011608cd01357c217837133d726d3ea Reviewed-on: https://chromium-review.googlesource.com/316804 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>