src/tests/gl_tests/TextureMultisampleTest.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>
Igor Nazarov d5babf99 2025-06-23T12:46:51 Vulkan: Fix unhandled deferred clears after glGetMultisamplefv Issue was introduced in the commit that implemented deferred clears. The `glGetMultisamplefv()` synchronizes draw framebuffer which defers possibly staged clears. Since API is not handling deferred clears they are left untouched, causing the ASSERT. This change fixes the issue by not deferring clears for the `glGetMultisamplefv()` command during flushing staged updates of dirty framebuffer attachments. Changes: - Add `gl::Command::GetMultisample` enumeration for clarity. - Add `gl::CommandBlitBuffer::CommandBlitBufferDepthStencil` enumeration to improve code readability. - Add `command` parameter into `gl::State::syncDirtyObject()` method to use actual command enum instead of `Other`. - Remove `previousDeferredClears` local variable and update ASSERT in the `FramebufferVk::syncState()` method. New assert ensures empty `mDeferredClears` instead of just checking dirty attachments, since it is easy to make all attachments dirty making old and new assertions act the same. - Replace logic in `FramebufferVk::syncState()` that decides whether need to defer attachments or not with switch-case. This makes the logic more clear regarding handling individual commands and simplify updating this handling in the future. Except of the bug fix with `GetMultisample` command, handling of other command is uncached. - Remove `flushDeferredClears()` from `FramebufferVk::readPixels()` because `mDeferredClears` are not expected (now it's more clear after the refactoring). And even if there are `mDeferredClears` (in case of a bug or after API failure), `flushDeferredClears()` only flushes clears for the draw framebuffer, while checking `mDeferredClears` of the read framebuffer. This is a problem in case if read and draw framebuffers are not the same. Bug: angleproject:40644727 Test: angle_end2end_tests --gtest_filter=TextureMultisampleTest.GetMultisamplefvAfterClear/* Test: angle_end2end_tests --gtest_filter=EGLSurfaceTest.GetMultisamplefvAfterClear/* Change-Id: I376a62de52de5e17dbc63cc7ddb0506741a69266 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6661958 Commit-Queue: Igor Nazarov <i.nazarov@samsung.com> Reviewed-by: Charlie Lao <cclao@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Alexey Knyazev e82a2eab 2024-11-28T00:00:00 Support multisample 2D array textures on ES 3.0 contexts Supported via OES_texture_storage_multisample_2d_array enabled together with ANGLE_texture_multisample. Drive-by: Fixed exposure conditions in the OpenGL backend to match the implementation. Fixed: angleproject:382298321 Change-Id: I21b037aac7bebc35df267e9dd468088ebce35e71 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6075241 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Amirali Abdolrashidi <abdolrashidi@google.com> Commit-Queue: Amirali Abdolrashidi <abdolrashidi@google.com>
Alexey Knyazev 26414249 2024-11-28T00:00:00 Remove GetTexLevelParameter* from ANGLE_texture_multisample These functions are always provided by the GL_ANGLE_get_tex_level_parameter frontend extension. Fixed: angleproject:382291448 Change-Id: I59b4ccc56478f2e0931d1f5bd665cfdd5a34391e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6072222 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
Alexey Knyazev 0bb109aa 2024-11-28T00:00:00 Fix validation for 2D multisample array textures * Fixes: * TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY query must be rejected if the functionality is not enabled. * GetInternalFormativ must accept TEXTURE_2D_MULTISAMPLE_ARRAY on unextended OpenGL ES 3.2 contexts. * Added validation to the OpenGL ES 3.2 TexStorage3DMultisample entry point. * Cleanups: * Removed OES suffix from the enum conversion. * Incorrect extension name in the error message. * Do not create a 2D multisample array zero texture object if the backend does not support the functionality. * Replaced redundant FramebufferTexture validation with an assertion. * Do not allocate texture binding vectors for 2D multisample array textures if the backend does not support the functionality. * Aligned the 2D multisample array texture target assert in RecordBindTextureTypeError with the actual error condition. Fixed: angleproject:381270278 Change-Id: Idbbc86e2efe1bbc25d9570d515b67c1a32255d99 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6063068 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
Alexey Knyazev 239ef680 2024-11-21T00:00:00 Metal: Support ANGLE_texture_multisample * Added explicit multisample texture creation support * Added support for SAMPLE_MASK frontend state * Adjusted Metal backend caps Fixed: angleproject:380475003 Change-Id: I90250e14da52869cb954b5a61d9c670e958a526c Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6048958 Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
Alexey Knyazev b94d7853 2024-11-14T00:00:00 Fix TextureMultisampleTest.CheckSamplePositions end2end test The test should query positions only for the supported sample counts. Added capture support for GetMultisamplefv and GetMultisamplefvANGLE functions. Fixed: angleproject:380216733 Change-Id: I97456055ac60ada94dd75e10d7427e4448aee5e8 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6042141 Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Cody Northrop <cnorthrop@google.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Alexey Knyazev 9c202275 2024-11-14T00:00:00 Fix SAMPLE_MASK_VALUE indexed query validation The SAMPLE_MASK_VALUE enum must be accepted when ANGLE_texture_multisample is enabled. Fixed: angleproject:380291919 Change-Id: Ieb834ca4c78982fbf1a121c0a70db7413574679a Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6038524 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com>
Alexey Knyazev a3452c24 2024-11-14T00:00:00 Fix SAMPLE_MASK toggle validation The SAMPLE_MASK enum must be accepted when ANGLE_texture_multisample is enabled. Bug: angleproject:380291919 Change-Id: I6aeb11dfbb65e6c05e493d1053679c7547c009c9 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6039158 Commit-Queue: Alexey Knyazev <lexa.knyazev@gmail.com> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Alexey Knyazev 8f07cdde 2024-11-14T00:00:00 Fix NegativeTextureMultisampleTest The test checks that unextended ES 3.0 contexts reject commands related to multisample textures but it did not create an unextended context and therefore was skipped on most backends because they expose the extension. Fixed: angleproject:380088822 Change-Id: I2aab2876539fb48954e5c0055f510ca4db429245 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6038826 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Shahbaz Youssefi 93eee5d2 2023-05-18T16:33:25 Vulkan: Add the Sample decoration when sample shading The Vulkan spec was clarified that per-sample interpolation is not necessarily done when sample shading is enabled in the API. In this change, a SPIR-V transformation is added to add the Sample decoration to whatever varying is missing it when sample shading is enabled in the API. Bug: b/283017896 Change-Id: I121c740add6fc015c9140e6a04d37ea5300c8e57 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4544591 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org> Reviewed-by: Charlie Lao <cclao@google.com>
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>
Gert Wollny ccca0c25 2022-05-22T00:18:41 libANGLE: Fix evaluating the sample count OpenGL deals with the maximum number of samples, but Vulkan provides a mask of supported sample counts, so extract and limit the maximum sample count accordingly. Bug: angleproject:7328 Change-Id: If4867b2a5104062ec863eb6eb1e0c8e78e7a9c00 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3652422 Commit-Queue: Gert Wollny <gert.wollny@collabora.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org>
Yuly Novikov a6b16d29 2021-03-02T19:04:57 Suppress UNINSTANTIATED_PARAMETERIZED_TEST failures on Ozone We only support ES2 on Ozone, so tests that depend on ES3 or ES31 support are not instantiated there. Bug: chromium:1183147 Change-Id: Id58bcd9b44a5b9a70b5ae8115e27c44f5dc81226 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2726550 Reviewed-by: Jonah Ryan-Davis <jonahr@google.com> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Yuly Novikov 59aa1ef1 2020-11-27T15:08:26 Suppress TextureSampleShadingTest.Basic on Vulkan AMD Fails on Windows and Linux. Bug: angleproject:5412 Change-Id: I0a8a0d194c63a92ede0f10cd89eb3db703b93ea2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2562756 Reviewed-by: Yuly Novikov <ynovikov@chromium.org> Commit-Queue: Yuly Novikov <ynovikov@chromium.org>
Shahbaz Youssefi 113b7e63 2020-11-24T17:16:25 Add a sample shading test to verify FS invocation per sample A test is added that uses the RedGreenGradient shader, which doesn't include gl_SampleID, gl_SamplePosition or the sample qualifier, but uses GL_SAMPLE_SHADING to perform per-sample shading. The samples from the resulting image are copied to a buffer in compute and verified. Bug: angleproject:5395 Change-Id: I3567329e4d567d149e4548eb12222b8dd5255bba Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2559266 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Mohan Maiya <m.maiya@samsung.com>
Shahbaz Youssefi 95bfb3e5 2020-07-08T23:07:48 Vulkan: Fix resolve draw path If the draw path is taken for resolve, the internal shader previously calculated (1+sum(sample.a))/sampleCount instead of sum(sample.a)/sampleCount. Additionally, due to a typo, the result was rounded. This change also fixes a number of off-by-one errors when calculating src/dst offsets in blit/resolve path. Tests are added to resolve from default to FBO and vice versa to exercise the draw path which was otherwise never invoked for color buffers. Bug: angleproject:4746 BUg: angleproject:4092 Change-Id: I4b9c181339b89af44b27d61d27a6b3d88cde2eea Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2288224 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Ian Elliott <ianelliott@google.com>
Shahbaz Youssefi 340da145 2020-06-16T10:58:47 Vulkan: Disable 1xMSAA on integer formats too This was pending swiftshader support for 4xMSAA support for integer formats, which is long done. Bug: angleproject:4197 Change-Id: I843a9674e20a48b5387bd67b8c0efc8617841382 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2248198 Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Ian Elliott <ianelliott@google.com>
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>
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 c09ae15c 2019-02-01T14:16:32 Enable -Wextra-semi and -Wextra-semi-stmt. This will prevent users from accidentally making semicolon errors in the future. Bug: chromium:926235 Change-Id: I79a6fa376fb1ad8f0fcf1b65b1f572a035d1f4e9 Reviewed-on: https://chromium-review.googlesource.com/c/1446493 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Nico Weber <thakis@chromium.org> Reviewed-by: Shahbaz Youssefi <syoussefi@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>
Yizhou Jiang 7310da33 2018-11-05T14:40:01 Implement GetMultismaplefvANGLE and SampleMaskiANGLE of texture multisample extension This patch adds GetMultismaplefvANGLE and SampleMaskiANGLE api. TEST=TextureMultisampleTest.CheckSamplePositions* TEST=NegativeTextureMultisampleTest.Negtive* BUG=angleproject:2275 Change-Id: Ib1e8b856059229bbe88328a28cf2a892f4673214 Reviewed-on: https://chromium-review.googlesource.com/c/1319252 Commit-Queue: Yizhou Jiang <yizhou.jiang@intel.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Yizhou Jiang 2fa2147f 2018-11-06T15:52:33 Enable texture multisample extension on ES3 D3D Update maxIntegerSamples, maxDepthTextureSamples and maxColorTextureSamples if the extension is enabled on ES 3.0. TEST=TextureMultisampleTest.* TEST=NegativeTextureMultisampleTest.Negtive* BUG=angleproject:2275 Change-Id: I8c215f990ff5d93611b1bc89de9a43f3d392e8d4 Reviewed-on: https://chromium-review.googlesource.com/c/1319251 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jiajia Qin <jiajia.qin@intel.com> Commit-Queue: Yizhou Jiang <yizhou.jiang@intel.com>
Yizhou Jiang c0b6c639 2018-09-06T15:02:04 Implement GetTexLevelParameter api of texture multisample extension This patch adds GetTexLevelParameterivANGLE and GetTexLevelParameterfvANGLE. TEST=TextureMultisampleTest.GetTexLevelParameter* TEST=NegativeTextureMultisampleTest.Negtive* BUG=angleproject:2275 Change-Id: Id702ba31df36ab65f46b697d480b5bf01b87e360 Reviewed-on: https://chromium-review.googlesource.com/c/1295830 Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Yizhou Jiang <yizhou.jiang@intel.com>
Yizhou Jiang 7818a85c 2018-09-06T15:02:04 Implement GL_ANGLE_texture_multisample API part Support GL_ANGLE_texture_multisample extension. This patch adds enums of multisampled texture and texStorage2DMultisampleANGLE API. TEST=angle_end2end_tests.exe --gtest_filter=TextureMultisampleTest* TEST=angle_end2end_tests.exe --gtest_filter=NegativeTextureMultisampleTest.Negtive* BUG=angleproject:2275 Change-Id: I2cab997edc33aa2d0be6082381545335423f64e0 Reviewed-on: https://chromium-review.googlesource.com/c/804613 Commit-Queue: Yizhou Jiang <yizhou.jiang@intel.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Olli Etuaho dff32a0d 2018-08-28T14:35:50 Support multisample arrays in shader programs The added tests check that using textureSize() and texelFetch() on textures with a fixed point format return expected results. texelFetch is also covered for integer format textures. dEQP GLES 3.1 tests also cover a variety of multisampled array texture formats. BUG=angleproject:2775 TEST=angle_end2end_tests, angle_deqp_gles31_tests Change-Id: I99b422e24b39e3563ed72f0fb85c9c1907df807d Reviewed-on: https://chromium-review.googlesource.com/1196521 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Olli Etuaho 064458a8 2018-08-30T14:02:02 Remove separate ANGLE_texture_multisample_array We can just expose OES_texture_storage_multisample_2d_array instead. The compiler was already changed to accept OES_texture_storage_multisample_2d_array, and now the change is made also at the API level. Out-of-bounds access guarantees provided by ANGLE were the only big difference between the ANGLE spec and the OES spec, so it's simpler to just expose the native extension. Safe out-of-bounds accesses can be guaranteed without having them in the extension spec. This also adds missing texStorage3DMultisample entry point to the proc table, which will enable running dEQP tests. BUG=angleproject:2775 TEST=angle_end2end_tests Change-Id: Idf376ee877a3374a33de177df023f0531ec8f01d Reviewed-on: https://chromium-review.googlesource.com/1196722 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho fd162107 2018-08-27T16:14:57 Support multisample arrays as framebuffer attachments This contains tests for framebuffer completeness when layers of multisample array textures are attached. Simple clearing of a layer of a multisample color texture array and blitting the result to a non-multisampled texture is also covered. BUG=angleproject:2775 TEST=angle_end2end_tests Change-Id: Idf383cab69587dbd8157ab9a2b7c47e5a90b3cf7 Reviewed-on: https://chromium-review.googlesource.com/1190184 Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho 0c5a9e22 2018-08-27T14:36:23 Implement TexStorage3DMultisample on the GL backend BUG=angleproject:2775 TEST=angle_end2end_tests Change-Id: Ic980d86cd787bcf29f622e68b0c38b0eb6ca5688 Reviewed-on: https://chromium-review.googlesource.com/1190182 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org> Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
Olli Etuaho d310a434 2018-08-24T15:40:23 Add validation and negative tests for multisample arrays This adds errors for binding and allocating multisample array textures. New tests in TextureMultisampleTest.cpp check that the errors are generated as specified. Tests for querying supported sample counts are also improved and extended for multisample array textures. BUG=angleproject:2775 TEST=angle_end2end_tests Change-Id: I6a0fe7ae04bb3d0072f6cbe09026b05e2bc47325 Reviewed-on: https://chromium-review.googlesource.com/1188576 Commit-Queue: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org>
Jiang 0e1224c8 2017-12-26T14:11:15 fix bug for querying sample positions on D3D BUG=angleproject:2290 TEST=dEQP-GLES31.functional.texture.multisample.samples_*.sample_position TEST=TextureMultisampleTestES31.CheckSamplePositions* Change-Id: If8b74c16d5c104215456e35b8922279be972cee3 Reviewed-on: https://chromium-review.googlesource.com/844062 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
Shao 5116d687 2017-08-02T12:39:44 ES31: Add missing initialization of MAX_*_SAMPLES on D3D This patch intends to add missing initialization of MAX_INTEGER_SAMPLES, MAX_DEPTH_TEXTURE_SAMPLES and MAX_COLOR_TEXTURE_SAMPLES required for multisampled textures on D3D backends. Since MAX_*_SAMPLES cannot be queried directly from D3D APIs, these values are initially assigned a large value in renderer11.cpp and re-calculated in context::updateCaps(). This patch also adds tests to ensure these values are greater than 1 as required in OpenGL ES3.1 spec. BUG=angleproject:1592 TEST=angle_end2end_tests Change-Id: Iba586e311d40d2da4569816902f96e40bbd6935b Reviewed-on: https://chromium-review.googlesource.com/597411 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org> Reviewed-by: Corentin Wallez <cwallez@chromium.org>
JiangYizhou 34bc315d 2017-03-29T14:56:01 ES31: Implement multisampled Textures for D3D part. Implement TexStorage2DMultisample api for d3d part. BUG=angleproject:1590 TEST=angle_end2end_tests --gtest_filter=TextureMultisampleTest* TEST=angle_deqp_gles31_tests --deqp-case=dEQP-GLES31.functional.texture.multisample.negative.fbo_* Change-Id: Icbfba45b9c2965af02b54dd4060b7b49970cb74b Reviewed-on: https://chromium-review.googlesource.com/457161 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: Jamie Madill <jmadill@chromium.org>
JiangYizhou 461d9a30 2017-01-04T16:37:26 ES31:Check framebuffer status for multisample and default params This patch implements FRAMEBUFFER_INCOMPLETE_MULTISAMPLE checking for checkFramebufferStatus, and also modify conditions of FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENTS when setting default parameters to fbo. BUG=angleproject:1594 TEST=angle_end2end_tests --gtest_filter=FramebufferTest_ES31* TEST=dEQP-GLES31.functional.texture.multisample.negative.fbo_attach_different_fixed_state_tex* Change-Id: I86954056d3a5d89dca517b267bd16e17b70e5652 Reviewed-on: https://chromium-review.googlesource.com/437991 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
JiangYizhou bddc46b4 2016-12-09T09:50:51 ES31: Implement multisampled Textures. Implement TexStorage2DMultisample and getMultisamplefv entry point. Also modify sample state for Textures and Framebuffers. BUG=angleproject:1590 TEST=angle_unittests TEST=angle_end2end_tests TEST=dEQP-GLES31.functional.texture.multisample.samples_*.sample_position TEST=dEQP-GLES31.functional.texture.multisample.samples_*.use_texture_color_2d TEST=dEQP-GLES31.functional.texture.multisample.samples_*.use_texture_depth_2d TEST=dEQP-GLES31.functional.texture.multisample.negative.fbo_attach_different_sample_count_tex_tex TEST=dEQP-GLES31.functional.texture.multisample.negative.fbo_attach_different_sample_count_tex_rbo TEST=dEQP-GLES31.functional.texture.multisample.negative.fbo_attach_non_zero_level TEST=dEQP-GLES31.functional.texture.multisample.negative.texture_high_sample_count TEST=dEQP-GLES31.functional.texture.multisample.negative.texture_zero_sample_count TEST=dEQP-GLES31.functional.shaders.builtin_functions.texture_size.samples_1_texture_2d TEST=dEQP-GLES31.functional.shaders.builtin_functions.texture_size.samples_4_texture_2d Change-Id: I8fa7bd4e73b95745858a3e16b1b92004b4a18712 Reviewed-on: https://chromium-review.googlesource.com/414309 Commit-Queue: Geoff Lang <geofflang@chromium.org> Reviewed-by: Yunchao He <yunchao.he@intel.com> Reviewed-by: Geoff Lang <geofflang@chromium.org>