Commit graph

110 commits

Author SHA1 Message Date
WPT Sync Bot
9c112bc2a2 Update web-platform-tests to revision 2bed10ac31899a4812f7e1d32ac69ade0bbe7f4f 2019-02-16 22:48:42 -05:00
Anthony Ramine
7fc8899e44 Clean up some expectations for WebGL tests in WPT 2018-09-12 23:45:49 +02:00
Alan Jeffrey
74c1e00d81 Upgraded to SM 60 2018-08-20 18:22:29 -04:00
WPT Sync Bot
2f89d25484 Update web-platform-tests to revision af43e2eb32555059316b67fba4a1d7df6ea3148d 2018-08-15 22:56:42 -04:00
WPT Sync Bot
8423a90871 Update web-platform-tests to revision 848ceffad26e92d47ffe790ed8b650906b2c2343 2018-08-10 14:45:43 -04:00
Imanol Fernandez
052971a71a Move WebGL tests and metadata to tests/wpt/mozilla/tests/ 2017-10-31 16:00:12 +01:00
Josh Matthews
1f531f66ea Update web-platform-tests to revision 8a2ceb5f18911302b7a5c1cd2791f4ab50ad4326 2017-10-12 12:36:21 -04:00
Josh Matthews
3347094373 Update WPT results. 2017-10-05 09:23:30 +02:00
Imanol Fernandez
1dd3899c37 Implement WebGL OES_standard_derivatives extension. 2017-08-22 15:01:26 +02:00
Imanol Fernandez
a3e6db115d Update offscreen_gl_context to 0.8.9 2017-05-26 20:56:13 +02:00
Imanol Fernandez
32e23c4db4 Implement WebGL extensions. 2017-05-18 18:44:07 +02:00
bors-servo
3b516af783 Auto merge of #16590 - MortimerGoro:texture_rgb, r=emilio
Fix WebGL premultiplied alpha. Fix texImage2D calls with RGB images.

Fix WebGL premultiplied alpha testcases.

Fix broken textures in some WebGL demos (e.g. Three.js). This was caused by WebGL::texImage2D calls with RGB formats. Alpha must be removed from the rgba8 pixel vector before submitting the data to the GPU.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [x] `./mach build -d` does not report any errors
- [x] `./mach test-tidy` does not report any errors
- [ ] These changes fix #__ (github issue number if applicable).

<!-- Either: -->
- [x] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Also, please make sure that "Allow edits from maintainers" checkbox is checked, so that we can help you if you get stuck somewhere along the way.-->

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16590)
<!-- Reviewable:end -->
2017-04-28 07:12:05 -05:00
Imanol Fernandez
e6d17f80a4 Fix WebGL premultiplied alpha. Fix texImage2D calls with RGB images. 2017-04-28 11:49:48 +02:00
Simon Sapin
11cef135e7 Update to cssparser 0.13 2017-04-25 01:45:33 +02:00
Josh Matthews
665817d2a6 Update web-platform-tests to revision 58eb04cecbbec2e18531ab440225e38944a9c444 2017-04-22 14:17:10 +02:00
Imanol Fernandez
6b0c898e1a Fix highp precision in shaders & Implement WebGL::GetShaderPrecisionFormat 2017-04-21 20:23:55 +02:00
Josh Matthews
0acff8ad46 Adjust test expectations for release builds. 2017-04-01 00:27:52 -04:00
Josh Matthews
11b2dce18a Enable webgl extensions tests. 2017-03-31 19:01:02 -04:00
Josh Matthews
6a1fecdb0f Enable webgl ogles functions tests. 2017-03-31 18:49:38 -04:00
Josh Matthews
069d5591b3 Enable the glsl webgl tests. 2017-03-31 18:46:26 -04:00
Josh Matthews
937855c3fd Enable the context and canvas webgl tests. 2017-03-31 18:42:44 -04:00
Josh Matthews
5af2603ec4 Allow async webgl conformance tests to complete. 2017-02-22 19:17:38 -05:00
Ms2ger
4fadf9b0b6 Update web-platform-tests to revision 7a767a52741f628430ffbbed46e7f3df68ba3534
Fixes #15648.
2017-02-20 13:52:41 +01:00
Eric Anholt
fcef92f5ba webgl: Fix handling of UNPACK_ALIGNMENT.
We were setting it to whatever value from {1,2,4,8} the user requested
and otherwise ignoring it.  There were two problems there:

1) Validation ignored it, so GL could read outside of the user's array
   in TexImage() or TexSubImage() if the aligment was greater than
   cpp.

2) TexImage()/TexSubImage() from image/canvas sources wasn't packing
   its data according to the unpack alignment.

To fix this, start tracking the user-requested alignment in the DOM
side of the context.  Set the GL's alignment to 1 for image/canvas
sources or the user's value for array sources, and pass the user's
alignment in to validation so that it can figure out the correct size
of image that the GL will ready.
2017-01-28 19:27:09 -08:00
Eric Anholt
dfc4de0d84 webgl: Add support for premultiplying alpha.
Now the affected testcase only fails due to unpack alignment.
2017-01-28 14:21:21 -08:00
Eric Anholt
57ba1646bc webgl: Convert non-raw TexImage sources to the requested format.
The code was returning RGBA8 data from the non-raw sources (HTML
canvas elements, JS ImageData, etc.), but we then validated and passed
that rgba8 data as if it was whatever format/datatype was specified in
TexImage2D/TexSubImage2D, so the pixels would come out as garbage.

It would seem like we could just rewrite the passed in format/datatype
for the TexImage call to be RGBA/UNSIGNED_BYTE, but that would leave
incorrect levels of precision if the internalformat didn't match the
format/datatype (and older desktop implementations often ignore the
internalformat in choosing their internal format, anyway).
2017-01-28 14:21:21 -08:00
Eric Anholt
2e6eb547a8 webgl: Implement FLIP_Y_AXIS unpacking flag for TexImage, TexSubImage.
This fixes a couple of tests doing RGBA/ubyte image uploads with
flipping.  Other tests with flipping get their expectations changed,
because some other feature is missing (premultiplication or
ImageData/canvas format conversion)
2017-01-28 14:21:20 -08:00
Aneesh Agrawal
7595a90221 Revert "Remove -w flag now that WebRender is always used"
This reverts commit b94b58f7ae.
The wptrunner changes are not quite right and causes Python exceptions
inside the test haness.
2017-01-23 15:01:55 -08:00
Aneesh Agrawal
b94b58f7ae Remove -w flag now that WebRender is always used
Also remove the obsolete `--cpu` and `--gpu` renderer flags,
which also are no longer used.

Update tests and wptrunner to not pass these flags.
wptrunner changes have been upstreamed in:
  - w3c/wptrunner#224
  - w3c/wptrunner#226
2017-01-20 02:05:50 -05:00
ioctaptceb
f3d65505e9 Add a check to BlendFunc for invalid constant
combinations
2017-01-11 20:59:03 +01:00
Eric Anholt
d020638ae4 webgl: Update expecteds for webgl-specific.html
This one is a combination of the new stencil* function support, and
the depthRange() validation I had added.
2017-01-05 18:15:15 -08:00
Eric Anholt
b5fa219f5a webgl: Drop expecteds for more calls to now-implemented functions. 2017-01-05 18:15:13 -08:00
Eric Anholt
1b84e633ff webgl: Drop more expected parsing failures from missing FBO support.
At least, it looks to me like that's what these were from -- they're
in about the right places to be from us previously missing
checkFramebufferStatus().
2017-01-05 18:14:27 -08:00
Eric Anholt
190e56c7c7 webgl: Drop some expected parsing failures.
I believe these were fixed with the getParameter(GL_FRAMEBUFFER_BINDING)
support.
2017-01-05 18:12:20 -08:00
Eric Anholt
9a8784c04d webgl: Remove some expected-fails for gl-vertex-attrib-zero-issues.html.
These expecteds were added in a07d6b37cc
with the addition of disableVertexAttribArray(), but they haven't been
happening in my test runs.
2017-01-05 18:12:18 -08:00
Eric Anholt
4c656f1f61 webgl: Add missing overload of bufferData().
I was writing this to fix the error in gl-enum-tests.html test (it now
gets farther along before it fails due to us missing
getTexParameter()), but it turned out that a lot of the conformance
tests were failing due to it.
2017-01-04 18:02:32 -08:00
Eric Anholt
c6f73a612a webgl: Allow enable/disable of STENCIL_TEST 2017-01-04 09:57:38 -08:00
bors-servo
220e6e4014 Auto merge of #14836 - jdm:enable-webgl-test, r=cbrewster
Enable uniformMatrixNfv.html

Fixes #10478, since #8462 was fixed a while ago.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14836)
<!-- Reviewable:end -->
2017-01-03 18:03:33 -08:00
Josh Matthews
a92cce4dfb Enable uniformMatrixNfv.html 2017-01-03 20:06:44 -05:00
Eric Anholt
daa64bf84f webgl: Validate enums for blendEquation.
Improves a conformance test that tried passing in desktop GL enums for
blending.
2016-12-31 11:37:38 -08:00
Ms2ger
d6ba94ca28 Update web-platform-tests to revision 3137d1d2d7757366a69f8a449b458b5057e0e81e 2016-12-28 11:34:21 +01:00
Glenn Watson
f517d03364 Update WR (typed units, glyph cache, various features). 2016-12-15 12:11:51 +10:00
bors-servo
2601d8eb8b Auto merge of #14081 - anholt:webgl-readpix-negative-width, r=emilio
webgl: out-of-bounds readPixels() fixes

<!-- Please describe your changes on the following line: -->
Fix crashes in two WebGL readPixels() tests by adding framebuffer size validation.

---
<!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: -->
- [X] `./mach build -d` does not report any errors
- [X] `./mach test-tidy` does not report any errors
- [X] These changes fix #13901

<!-- Either: -->
- [X] There are tests for these changes OR
- [ ] These changes do not require tests because _____

<!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. -->

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14081)
<!-- Reviewable:end -->
2016-11-09 10:03:42 -06:00
Josh Matthews
6589f6107e Enable cors and redirect fetch tests. 2016-11-08 08:17:25 -05:00
Eric Anholt
5e5eb18b0b webgl: Fix out-of-bounds readpixels handling.
This fixes the crash in read-pixels-pack-alignment (which was trying
to read out of bounds).

Fixes #13901
2016-11-05 11:49:30 -07:00
Eric Anholt
5e7ed33a9b webgl: Remove some expected-fails from subtests that have been fixed.
These tests all used to fail overall, and have notes about which
subtests were failing so that an overall failure could still show up
as no regressions.  Since then, all of the subtests have been fixed,
and their overall statuses updated, but we can also garbage collect
the subtests at this point.

This was produced by doing ./mach update --ignore-existing from a
webgl conformance run, and pulling out everything that completely
removed a file that didn't have expected overall failure.
2016-10-30 16:38:16 -07:00
Eric Anholt
dba7d5eb51 webgl: Detach RBs and textures from the bound FBO on deletion.
This is part of general GL behavior: when an object is deleted, look
through the currently bound objects and detach the deleted object from
them.  Detaching an object from an FBO causes it to need to be
re-checked for its status.
2016-10-25 22:19:26 -07:00
Eric Anholt
6c10d5ca75 webgl: Add support for FBO attachments.
This allows many FBO tests to start running as their framebuffers
start coming back as framebuffer complete.
2016-10-25 22:18:29 -07:00
Eric Anholt
989c936e67 webgl: Add support for renderbufferStorage().
This is not a complete implementation yet: It doesn't clear the
contents of the renderbuffer on creation.  However, Gecko's plan to
only clear renderbuffers when the first FBO using them is the
simplest.
2016-10-25 22:18:28 -07:00
Eric Anholt
8a0ca2efba webgl: Add support for checkFramebufferStatus().
For now it's returning the default UNSUPPORTED on user FBOs.

object-deletion-behaviour.html starts running a bunch more subtets.
2016-10-25 22:18:27 -07:00