Commit Graph

113 Commits

Author SHA1 Message Date
Kelsey Gilbert
21eefb3902 Bug 1725074 - Allow attribs with the same names as uniforms. r=gfx-reviewers,lsalzman
(and vice-versa)

Differential Revision: https://phabricator.services.mozilla.com/D133673
2021-12-13 20:42:30 +00:00
Jeff Gilbert
5884aa76c2 Bug 1738125 - Include failed compile log in LinkProgram failure warning. r=gfx-reviewers,bradwerth
Differential Revision: https://phabricator.services.mozilla.com/D129723
2021-10-27 22:44:58 +00:00
Jeff Gilbert
9ad028e86b Bug 1726265 - Prototype webgl draft ext OES_draw_buffers_indexed. r=lsalzman,emilio,webidl
Differential Revision: https://phabricator.services.mozilla.com/D122916
2021-08-27 01:47:14 +00:00
Butkovits Atila
31ec7dc564 Backed out changeset a4a346ecefd7 (bug 1726265) for causing failures at test_2_conformance2__extensions__oes-draw-buffers-indexed.html. CLOSED TREE 2021-08-21 01:46:52 +03:00
Jeff Gilbert
7c2c091f23 Bug 1726265 - Prototype webgl draft ext OES_draw_buffers_indexed. r=lsalzman,emilio
Differential Revision: https://phabricator.services.mozilla.com/D122916
2021-08-20 20:59:54 +00:00
Cosmin Sabou
8af18a2680 Backed out changeset 24e0d3aa4ada (bug 1726265) for causing non-unified build bustage. CLOSED TREE 2021-08-20 04:29:04 +03:00
Jeff Gilbert
b77fc4847f Bug 1726265 - Prototype webgl draft ext OES_draw_buffers_indexed. r=lsalzman,emilio
Differential Revision: https://phabricator.services.mozilla.com/D122916
2021-08-20 00:05:06 +00:00
Jeff Gilbert
e102805cc8 Bug 1679693 - Update WebGL 2 to allow drawArraysInstanced with no non-instanced active attribs. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D98112
2020-11-30 18:19:40 +00:00
Narcis Beleuzu
bd1847d522 Backed out changeset 7137d009d979 (bug 1679693) for webgl2 failure on test_2_conformance2__rendering__instanced-arrays.html. CLOSED TREE 2020-11-29 21:17:11 +02:00
Jeff Gilbert
971daa542c Bug 1679693 - Update WebGL 2 to allow drawArraysInstanced with no non-instanced active attribs. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D98112
2020-11-29 17:51:10 +00:00
Simon Giesecke
46908cfb51 Bug 1660470 - Add missing include directives/forward declarations. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D87865
2020-11-23 16:21:38 +00:00
Jeff Gilbert
4d5da1cfaf Bug 1617785 - Optimize GetDrawFetchLimits and vertexAttribPointer. r=lsalzman
Our goal here is to just be fast enough that we don't need to cache.

Differential Revision: https://phabricator.services.mozilla.com/D64215
2020-02-26 00:44:26 +00:00
Jeff Gilbert
b3fba26311 Bug 1616457 - Fix failures in conformance/extensions/webgl-draw-buffers. r=lsalzman
We must not check frag output type agreement if colorMask(0,0,0,0).
We must allow drawing with no frag outputs, leaving color values
unchanged. (evidently this is used enough that we spec'd it this way?)

Differential Revision: https://phabricator.services.mozilla.com/D63287
2020-02-19 20:47:30 +00:00
Simon Giesecke
e138819a70 Bug 1613985 - Use default for equivalent-to-default constructors/destructors in dom/canvas. r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D63142
2020-02-18 21:08:00 +00:00
Jeff Gilbert
9734752778 Bug 1615487 - Don't cache thrashing VAOs to mDrawFetchCache. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D63013
2020-02-16 15:38:25 +00:00
Jeff Gilbert
236fde773d Bug 1615487 - Make CachedDrawFetchLimits move-only, remove copy. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D63012
2020-02-16 15:37:35 +00:00
Emilio Cobos Álvarez
2da5bd4af6 Bug 1608729 - Initialize some variables in WebGLProgram. r=jgilbert
Otherwise GCC warns about the variable being possibly uninitialized, and it's
right if you could ever have a shader with a wrong type.

Depends on D59647

Differential Revision: https://phabricator.services.mozilla.com/D59648
2020-01-13 19:59:47 +00:00
Jeff Gilbert
a62f7410a2 Bug 1477756 - Fix all webgl regression tests according to CI. r=handyman
(This is a combination of 31 commits)

* Fix Linux compilation.

* Fix mac compilation.

* CI compile fixes.

* printf's size_t is %zu. %tu would be unsigned ptrdiff_t.

* No non-ref Maybe args.

* MOZ_CRASH for noreturn

* Handle implied texture sizes, rewrite comment stripping.

* Replace e.g. WebGLProgramInner with simpler webgl::ProgramKeepAlive.

* Bounce ValidateProgram call off driver.

* Uniform name length limit, cubemap fb-attach, non-array uniforms, undersized texImage views.

* alignas for uint8_t[sizeof(float)*N] pun buffers.

* CC fixes?

* Fill attrib0Active.

* Repair max-warnings limit.

* This is basically required in order for CI's logging to not explode.

* Don't cache WebGLMemoryTracker.

* Deleted prog/shader error, no texSubImage(null), client-side fingerprint resist for exts.

* Fix GetUniformIndices and MakeRangeFromView.

* CC Traverse base class from within derived class to fix leaking the world. :(

* PauseTransformFeedback
* TexImage video fastpath
* GetFragLocation for arrays
* Forbid BindBufferRange during TF

* Mark tests and fix RBAB query and test.

* Change(!) query deletion behavior to match spec.
* Mark conformance2/query/query.html failing for now.

* Implicitly EndQuery on DeleteQuery while spec is in flux.

* Fix error code for test.

* RAII LruPosition for WebGL context limit.

* Include std::list.

* Mark CompileResult and LinkResult.pending as false when retrieved.

* Hold strong-ref to NotLostData during Run<> to prevent LoseContext=>UAF.

* Don't assume GetUniformLocation(foo+'[0]') means foo is an array.
* Don't assume !mCanvasElement means !!mOffscreenCanvas.

* Handle composition while context-lost.

* All non-value-init members must be const or have inline init.

* Mark passing tests on Linux.

Depends on D54019

Differential Revision: https://phabricator.services.mozilla.com/D55739
2020-01-08 22:19:23 +00:00
Jeff Gilbert
d04fb7be7c Bug 1477756 - Client-side bindings mirror for precise CC, and merge similar codepaths. r=handyman
* Context loss using RAII
* Move Program reflection Client-side

Depends on D54018

Differential Revision: https://phabricator.services.mozilla.com/D54019
2020-01-08 22:19:16 +00:00
David Parks
8b7b0903cc Bug 1477756 - Initial out-of-process WebGL implementation. r=mccr8,handyman
Splits WebGLContext into ClientWebGLContext and HostWebGLContext.  The Client enables the JS-control of a WebGL context in a content procecss while the Host executes the WebGL graphics operations (via a WebGLContext that maintains much of the existing code) in the compositor process.  At this point, the cross-process behavior is disabled -- this series of patches is an incremental step toward that final goal.

Differential Revision: https://phabricator.services.mozilla.com/D54018
2020-01-08 22:19:14 +00:00
Emilio Cobos Álvarez
fd43f17fc3 Bug 1603843 - Remove work-around for 7+-year-old Mesa bug. r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D57166
2019-12-13 22:12:25 +00:00
Jeff Gilbert
7921c6339b Bug 1569094 - Optimize cache-miss path in GetDrawFetchLimits. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D39456
2019-07-26 04:04:08 +00:00
Jeff Gilbert
074a894940 Bug 1541396 - Refactor (non-)transform-feedback binding/use checks. r=lsalzman
* Remove WebGLBuffer::SetSlot
* Make most bindBuffer calls lazy.
* Replace nsTArray with std::vector in WebGLVertexArray.

Differential Revision: https://phabricator.services.mozilla.com/D36274
2019-06-30 01:29:42 +00:00
Jeff Gilbert
d44054dbbd Bug 1319426 - Don't keep ANGLE shader compilers around. r=lsalzman
This will also make it easier if we want to reuse compilers/validators.

Differential Revision: https://phabricator.services.mozilla.com/D35398
2019-06-21 16:52:50 +00:00
Jeff Gilbert
491630cdf4 Bug 1536672 - Implement WebGL OVR_multiview2 behind draft flag. r=lsalzman,qdot
Also disable clang-format for gfx/gl/GLConsts.h.

Differential Revision: https://phabricator.services.mozilla.com/D28168
2019-05-23 20:48:21 +00:00
Mihai Alexandru Michis
75702fce81 Backed out changeset a649f69f29df (bug 1536672) for failing crashtest at WebGLContextValidate.cpp. CLOSED TREE 2019-05-23 10:57:29 +03:00
Jeff Gilbert
b59c336639 Bug 1536672 - Implement WebGL OVR_multiview2 behind draft flag. r=lsalzman,qdot
Also disable clang-format for gfx/gl/GLConsts.h.

Differential Revision: https://phabricator.services.mozilla.com/D28168
2019-05-23 02:43:11 +00:00
Jeff Gilbert
034e874261 Bug 1526027 - Remove webgl.bypass-shader-validation. r=lsalzman
Also remove extra plumbing from WebGLShaderValidator, moved directly
into WebGLShader.

Differential Revision: https://phabricator.services.mozilla.com/D31567
2019-05-17 02:36:57 +00:00
Ryan Hunt
ad7b7dbb30 Bug 1523969 part 6 - Move method definition inline comments to new line in 'dom/'. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D21106
2019-02-25 16:05:29 -06:00
Jeff Gilbert
520bd7f064 Bug 1525857 - Add release asserts for pre-crash cases. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D21145
2019-02-26 02:54:08 +00:00
Jeff Gilbert
0085b21bfb Bug 1290774 - Validate frag shader output types match draw buffer types. r=lsalzman
MozReview-Commit-ID: FXQaUzJ0fDy

Differential Revision: https://phabricator.services.mozilla.com/D18611
2019-02-04 14:34:59 -08:00
Cosmin Sabou
375e5bc061 Backed out changeset 58fe5a3d3c40 (bug 1290774) for causing build bustages on WebGLContextDraw. CLOSED TREE 2019-02-01 05:58:38 +02:00
Jeff Gilbert
0c553a4aa3 Bug 1290774 - Validate frag shader output types match draw buffer types. r=lsalzman
MozReview-Commit-ID: HhGKDVWXR1A

Differential Revision: https://phabricator.services.mozilla.com/D18302
2019-02-01 03:33:02 +00:00
Jeff Gilbert
729d693e99 Bug 1301803 - Handle context loss during QueryProgramInfo. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D17998
2019-01-30 03:24:04 +00:00
Tooru Fujisawa
5ef6d9cc06 Bug 1511393 - Use c-basic-offset: 2 in Emacs mode line for C/C++ code. r=nbp 2018-12-01 04:52:05 +09:00
Sylvestre Ledru
e5a134f73a Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset
2018-11-30 11:46:48 +01:00
Alex Gaynor
dc5d306c07 Bug 1506179 - rename webgl::AttribBaseType::Bool to Boolean; r=jgilbert
X11.h defines a macro named "Bool", which can cause surprising compile errors due to include order.

Differential Revision: https://phabricator.services.mozilla.com/D11494
2018-11-09 21:38:31 +00:00
Jeff Gilbert
a8ce1aa6f1 Bug 1498070 - Simplify and cache framebuffer and texture completeness. - r=kvark
Net-removes 700LOC, too!

Differential Revision: https://phabricator.services.mozilla.com/D8325
2018-10-17 04:18:15 +00:00
Jamie Nicol
4a782f5bde Bug 1495857 - Ensure correct vertex attrib array index is output in error message r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D7868
2018-10-05 19:03:46 +00:00
Jeff Gilbert
8b724921f4 Bug 1478909 - Make funcName implicit for WebGL calls. - r=kvark
MozReview-Commit-ID: Gv77SnHZcGb
2018-08-09 14:35:01 -07:00
Dorel Luca
68edc212ae Backed out changeset e8023a02b6c2 (bug 1478909) on dev's request 2018-08-09 04:58:04 +03:00
Jeff Gilbert
c164f419ac Bug 1478909 - Make funcName implicit for WebGL calls. - r=kvark
MozReview-Commit-ID: Gv77SnHZcGb
2018-08-08 16:15:12 -07:00
Jeff Gilbert
70a22b2878 Bug 1470325 - s/FooBinding/Foo_Binding/g - r=qdot
MozReview-Commit-ID: JtTcLL5OPF0
2018-06-26 17:05:01 -07:00
Emilio Cobos Álvarez
4b8b5e1717 Bug 1465585: Switch from mozilla::Move to std::move. r=froydnj
This was done automatically replacing:

  s/mozilla::Move/std::move/
  s/ Move(/ std::move(/
  s/(Move(/(std::move(/

Removing the 'using mozilla::Move;' lines.

And then with a few manual fixups, see the bug for the split series..

MozReview-Commit-ID: Jxze3adipUh
2018-06-01 10:45:27 +02:00
Jeff Gilbert
acda6087b5 Bug 1426280 - Remove explicit MakeCurrents from WebGL now that we use implicit MakeCurrent. - r=lenzak
MozReview-Commit-ID: HxWWPmD1Yzu
2017-12-19 22:28:49 -08:00
Jeff Gilbert
8bc4b69aad Bug 1404196 - Simplify and repair vertex fetch. - r=daoshengmu
MozReview-Commit-ID: FL7uibuv4VY
2017-11-01 15:18:27 -07:00
Chung-Sheng Fu
47e83a94ee Bug 1217290 - Remove WebGLContext impl members r=daoshengmu,jgilbert
MozReview-Commit-ID: DPrjaf9QHfP
2017-07-27 15:48:58 +08:00
Sylvestre Ledru
6686478407 Bug 1387002 - Replace .size() by .empty() when applicable in domv/canvas/WebGL* r=kvark
MozReview-Commit-ID: 3lebYmRI8TS
2017-08-03 12:01:38 +02:00
Kartikaya Gupta
14424677af Bug 1384233 - Remove SizePrintfMacros.h. r=froydnj
We have a minimum requirement of VS 2015 for Windows builds, which supports
the z length modifier for format specifiers. So we don't need SizePrintfMacros.h
any more, and can just use %zu and friends directly everywhere.

MozReview-Commit-ID: 6s78RvPFMzv
2017-07-26 16:03:57 -04:00
Tom Tromey
3b7c8c14e5 Bug 1060419 - make WebGLContextUtils.cpp use VsprintfLiteral, r=froydnj
MozReview-Commit-ID: JhwopeIpUMo
2016-12-09 13:48:22 -10:00