Граф коммитов

185 Коммитов

Автор SHA1 Сообщение Дата
Lee Salzman 58cc63bda7 Bug 1754130 - Implement SourceSurfaceWebgl for faster snapshots of DrawTargetWebgl. r=aosmond
Now that each DrawTargetWebgl shares the same WebGL context, we can efficiently draw snapshots
of one DrawTargetWebgl to another without requiring any readback or error-prone driver-provided
shared context/resource mechanism. We just need to simply pass the WebGL texture from one target
to the other, and use it like any other texture.

This provides SourceSurfaceWebgl to store and pass along that WebGL texture. It is largely
modeled off of SourceSurfaceSkia in terms of its copy-on-write behavior. There are three
noteworthy state changes that it must track from DrawTargetWebgl - when the framebuffer
contents is changing, when the framebuffer is being destroyed, and when any cached texture
handle separate from a framebuffer is also being destroyed. It will copy, orphan, or read
back data as appropriate to handle each case.

If it needs to be mapped, it just forces a read back of the data into a CPU surface that
can be mapped as requested.

Differential Revision: https://phabricator.services.mozilla.com/D138118
2022-02-11 19:49:55 +00:00
Marian-Vasile Laza 610558649b Backed out 3 changesets (bug 1754130) for causing mochitest failures. CLOSED TREE
Backed out changeset 7fea32057b92 (bug 1754130)
Backed out changeset 1ac8f10e0025 (bug 1754130)
Backed out changeset 3d56b847ddf9 (bug 1754130)
2022-02-11 18:30:11 +02:00
Lee Salzman 8a34e8c65e Bug 1754130 - Implement SourceSurfaceWebgl for faster snapshots of DrawTargetWebgl. r=aosmond
Now that each DrawTargetWebgl shares the same WebGL context, we can efficiently draw snapshots
of one DrawTargetWebgl to another without requiring any readback or error-prone driver-provided
shared context/resource mechanism. We just need to simply pass the WebGL texture from one target
to the other, and use it like any other texture.

This provides SourceSurfaceWebgl to store and pass along that WebGL texture. It is largely
modeled off of SourceSurfaceSkia in terms of its copy-on-write behavior. There are three
noteworthy state changes that it must track from DrawTargetWebgl - when the framebuffer
contents is changing, when the framebuffer is being destroyed, and when any cached texture
handle separate from a framebuffer is also being destroyed. It will copy, orphan, or read
back data as appropriate to handle each case.

If it needs to be mapped, it just forces a read back of the data into a CPU surface that
can be mapped as requested.

Differential Revision: https://phabricator.services.mozilla.com/D138118
2022-02-11 15:36:30 +00:00
Andrew Osmond 193a13db35 Bug 1746750 - Part 3. Implement partial OffscreenCanvasRenderingContext2D. r=lsalzman,webidl,smaug
This patch adds a partial OffscreenCanvasRenderingContext2D
implementation. It is missing anything text and UI related, including
CanvasFilters, CanvasUserInterface, CanvasText, CanvasTextDrawingStyles,
and CanvasHitRegions.

Differential Revision: https://phabricator.services.mozilla.com/D135354
2022-02-03 20:00:25 +00:00
Iulian Moraru 39e3ddd037 Backed out 4 changesets (bug 1746750) as per request. CLOSED TREE
Backed out changeset bf79a6b72d87 (bug 1746750)
Backed out changeset 87dde3962558 (bug 1746750)
Backed out changeset 08e0ff1804f6 (bug 1746750)
Backed out changeset 4a3da2db3bc0 (bug 1746750)
2022-02-03 03:24:42 +02:00
Andrew Osmond 1c3016c525 Bug 1746750 - Part 3. Implement partial OffscreenCanvasRenderingContext2D. r=lsalzman,webidl,smaug
This patch adds a partial OffscreenCanvasRenderingContext2D
implementation. It is missing anything text and UI related, including
CanvasFilters, CanvasUserInterface, CanvasText, CanvasTextDrawingStyles,
and CanvasHitRegions.

Differential Revision: https://phabricator.services.mozilla.com/D135354
2022-02-02 23:25:51 +00:00
Iulian Moraru 30f1186aa5 Backed out 4 changesets (bug 1746750) for causing mochitest webgl failures on test_2_conformance2__offscreencanvas__offscreencanvas-sync.html. CLOSED TREE
Backed out changeset 011f75653bfb (bug 1746750)
Backed out changeset 9c2aca08a507 (bug 1746750)
Backed out changeset cccf6afc3ce9 (bug 1746750)
Backed out changeset 36fedb339908 (bug 1746750)
2022-02-02 23:28:30 +02:00
Andrew Osmond 48f822060f Bug 1746750 - Part 3. Implement partial OffscreenCanvasRenderingContext2D. r=lsalzman,webidl,smaug
This patch adds a partial OffscreenCanvasRenderingContext2D
implementation. It is missing anything text and UI related, including
CanvasFilters, CanvasUserInterface, CanvasText, CanvasTextDrawingStyles,
and CanvasHitRegions.

Differential Revision: https://phabricator.services.mozilla.com/D135354
2022-02-02 16:41:26 +00:00
Mike Hommey fce6eb7d83 Bug 1747165 - Replace TK_FLAGS/TK_LIBS with MOZ_GTK3_FLAGS/MOZ_GTK3_LIBS. r=firefox-build-system-reviewers,andi
Differential Revision: https://phabricator.services.mozilla.com/D134464
2021-12-23 20:29:07 +00:00
Cristian Tuns e1e31e01f2 Backed out 2 changesets (bug 1747165) for causing nightly blockers(bustages) a=backout
Backed out changeset 4b1ab0915c94 (bug 1747165)
Backed out changeset 96043d814772 (bug 1747165)
2021-12-23 08:00:54 -05:00
Mike Hommey b55194a16f Bug 1747165 - Replace TK_FLAGS/TK_LIBS with MOZ_GTK3_FLAGS/MOZ_GTK3_LIBS. r=firefox-build-system-reviewers,andi
Differential Revision: https://phabricator.services.mozilla.com/D134464
2021-12-22 23:56:24 +00:00
Andrew Osmond e198bb861f Bug 1745384 - Temporarily fix crash during clang mingw cross compile builds. r=gfx-reviewers,lsalzman
It appears that dom/canvas/nsICanvasRenderingContextInternal.cpp must be
part of a greater unified build file. Adding new files has pushed it
into its own unified file causing clang to crash when cross compiling
using mingw. For now, let's just put the new file a previous patch added
into SOURCES instead of UNIFIED_SOURCES to avoid breaking this delicate
balance.

A follow up bug will need to be created to investigate on the clang
side.

Differential Revision: https://phabricator.services.mozilla.com/D133487
2021-12-10 14:35:28 +00:00
Cristian Tuns 6ca90e7a81 Backed out changeset 3ed167027315 (bug 1745384) for causing lint failures. CLOSED TREE 2021-12-10 09:12:33 -05:00
Andrew Osmond c39ff2b073 Bug 1745384 - Temporarily fix crash during clang mingw cross compile builds. r=gfx-reviewers,lsalzman
It appears that dom/canvas/nsICanvasRenderingContextInternal.cpp must be
part of a greater unified build file. Adding new files has pushed it
into its own unified file causing clang to crash when cross compiling
using mingw. For now, let's just put the new file a previous patch added
into SOURCES instead of UNIFIED_SOURCES to avoid breaking this delicate
balance.

A follow up bug will need to be created to investigate on the clang
side.

Differential Revision: https://phabricator.services.mozilla.com/D133487
2021-12-10 13:56:27 +00:00
Andrew Osmond a4d1ae1188 Bug 1736177 - Part 10. Add OffscreenCanvasDisplayHelper implementation. r=jgilbert
This helper class manages the necessary state to facilitate the display
pipeline for an OffscreenCanvas created through HTMLCanvasElement's
transferControlToOffscreen.

Differential Revision: https://phabricator.services.mozilla.com/D130786
2021-12-10 02:57:55 +00:00
Csoregi Natalia 1c7cae16d7 Backed out 17 changesets (bug 1738971, bug 1736177) for bp-hybrid failures and others. CLOSED TREE
Backed out changeset 828633114de2 (bug 1736177)
Backed out changeset 5be8557c4721 (bug 1736177)
Backed out changeset 49f8b4205a46 (bug 1736177)
Backed out changeset 2610d4464ad5 (bug 1736177)
Backed out changeset 6d6c78c31c28 (bug 1736177)
Backed out changeset d55f1ee88bb9 (bug 1736177)
Backed out changeset bf588f8ffcf1 (bug 1736177)
Backed out changeset 86f6f6d86c6c (bug 1736177)
Backed out changeset f400c75c5829 (bug 1736177)
Backed out changeset 4a34124d5f4e (bug 1736177)
Backed out changeset 70aff7fcd001 (bug 1736177)
Backed out changeset db2347ee8147 (bug 1736177)
Backed out changeset 3dde5ddb65e5 (bug 1738971)
Backed out changeset 894ba6b7b68f (bug 1738971)
Backed out changeset dc4503052cf1 (bug 1738971)
Backed out changeset d9aef3e9797e (bug 1738971)
Backed out changeset 562a1e8e5ac3 (bug 1738971)
2021-12-10 01:13:23 +02:00
Andrew Osmond 54b53f8b76 Bug 1736177 - Part 10. Add OffscreenCanvasDisplayHelper implementation. r=jgilbert
This helper class manages the necessary state to facilitate the display
pipeline for an OffscreenCanvas created through HTMLCanvasElement's
transferControlToOffscreen.

Differential Revision: https://phabricator.services.mozilla.com/D130786
2021-12-09 19:25:28 +00:00
Christian Holler 3782331a06 Bug 1590068 - Add fuzzing target for StructuredCloneData. r=baku,sfink
Differential Revision: https://phabricator.services.mozilla.com/D128513
2021-12-08 18:59:02 +00:00
Chris Peterson f6fdbf028a Bug 1738401 - Remove -Wno-shadow warning suppressions. r=firefox-build-system-reviewers,glandium
-Wshadow warnings are not enabled globally, so these -Wno-shadow suppressions have no effect. I had intended to enable -Wshadow globally along with these suppressions in some directories (in bug 1272513), but that was blocked by other issues.

There are too many -Wshadow warnings (now over 2000) to realistically fix them all. We should remove all these unnecessary -Wno-shadow flags cluttering many moz.build files.

Differential Revision: https://phabricator.services.mozilla.com/D132289
2021-12-01 06:40:04 +00:00
Lee Salzman 3c994f8afd Bug 1739448 - Implement a prototype WebGL-backed Canvas2D. r=gfx-reviewers,nical,jrmuizel
This mainly provides DrawTargetWebgl, which implements the subset of the DrawTarget
API necessary for integration with CanvasRenderingContext2D. It translates them to
suitable commands for its internal ClientWebGLContext, which then manages remoting
WebGL requests to the parent/GPU process.

Currently two shaders are used for drawing Canvas2D primitives, but can be expanded
in the future. These are an image shader and a solid color shader.

The core of this implementation revolves around TexturePacker and TextureHandle,
which cope with the necessity of frequently uploading SourceSurfaces for use with
WebGL. TexturePacker implements a bin-packing algorithm for packing these uploads
into texture pages, which can either be SharedTextures if they are reasonably small,
or StandaloneTextures if they are too big to pack in a SharedTexture. Each upload
is assigned a TextureHandle which is used to manage it in a move-to-front cache,
so that we can easily eject TextureHandles from the back of the cache if we have
too many. These TextureHandles are associated with the SourceSurface that spawned
them to more easily manage their lifetimes.

There are further dependent caches for dealing with blurred shadows and with text.
Shadows are cached in an uploaded texture bound to the SourceSurface that generated
them. Text is handled by caching entire runs in the GlyphCache (keyed by both their
rendering parameters and their glyphs). The text is first rasterized to a surface
and then uploaded to a texture in the GlyphCache which can be reused should the
text be encountered again.

To deal with commands we can't accelerate, a separate internal DrawTargetSkia is
also maintained. The content of the WebGL framebuffer is copied into it so that
drawing can then proceed in software from there. It remains in this fallover state
until the next frame, when it resets back to using the WebGL framebuffer again.

This acceleration is disabled by default. To enable it, you must toggle the pref
"gfx.canvas.accelerated" to true. This should be suitably different from the naming
of the previous SkiaGL prefs to not alias with them. There are a few dependent prefs
that follow from the previous SkiaGL prefs for setting the size limitations for
acceleration and also limitations for the internal texture cache.

Differential Revision: https://phabricator.services.mozilla.com/D130388
2021-11-11 07:16:58 +00:00
Marian-Vasile Laza 748933bf4b Backed out 2 changesets (bug 1739448) for causing geckoview failures on 1246775-1.html. CLOSED TREE
Backed out changeset 7b82837e2f56 (bug 1739448)
Backed out changeset feac99f1dae3 (bug 1739448)
2021-11-11 07:39:10 +02:00
Lee Salzman c3d10f0f9e Bug 1739448 - Implement a prototype WebGL-backed Canvas2D. r=gfx-reviewers,nical,jrmuizel
This mainly provides DrawTargetWebgl, which implements the subset of the DrawTarget
API necessary for integration with CanvasRenderingContext2D. It translates them to
suitable commands for its internal ClientWebGLContext, which then manages remoting
WebGL requests to the parent/GPU process.

Currently two shaders are used for drawing Canvas2D primitives, but can be expanded
in the future. These are an image shader and a solid color shader.

The core of this implementation revolves around TexturePacker and TextureHandle,
which cope with the necessity of frequently uploading SourceSurfaces for use with
WebGL. TexturePacker implements a bin-packing algorithm for packing these uploads
into texture pages, which can either be SharedTextures if they are reasonably small,
or StandaloneTextures if they are too big to pack in a SharedTexture. Each upload
is assigned a TextureHandle which is used to manage it in a move-to-front cache,
so that we can easily eject TextureHandles from the back of the cache if we have
too many. These TextureHandles are associated with the SourceSurface that spawned
them to more easily manage their lifetimes.

There are further dependent caches for dealing with blurred shadows and with text.
Shadows are cached in an uploaded texture bound to the SourceSurface that generated
them. Text is handled by caching entire runs in the GlyphCache (keyed by both their
rendering parameters and their glyphs). The text is first rasterized to a surface
and then uploaded to a texture in the GlyphCache which can be reused should the
text be encountered again.

To deal with commands we can't accelerate, a separate internal DrawTargetSkia is
also maintained. The content of the WebGL framebuffer is copied into it so that
drawing can then proceed in software from there. It remains in this fallover state
until the next frame, when it resets back to using the WebGL framebuffer again.

This acceleration is disabled by default. To enable it, you must toggle the pref
"gfx.canvas.accelerated" to true. This should be suitably different from the naming
of the previous SkiaGL prefs to not alias with them. There are a few dependent prefs
that follow from the previous SkiaGL prefs for setting the size limitations for
acceleration and also limitations for the internal texture cache.

Differential Revision: https://phabricator.services.mozilla.com/D130388
2021-11-11 04:33:50 +00:00
Jeff Gilbert 4e78544fb2 Bug 1735431 - Merge WebGLExtension* into WebGLExtensions.cpp. r=gfx-reviewers,nical
Differential Revision: https://phabricator.services.mozilla.com/D128314
2021-10-19 23:07:00 +00:00
Jeff Gilbert 67e6fce4dd Bug 1730282 - Cleanup IPC WebGL code. r=gfx-reviewers,lsalzman
* Replace QueueStatus with bool
* Remove unused structs and code
* Add some MOZ_LIKELY to (de)serialization branches

Differential Revision: https://phabricator.services.mozilla.com/D125295
2021-09-11 02:11:11 +00:00
Mike Hommey 03223f9ea4 Bug 1722653 - Remove MOZ_CAIRO_CFLAGS. r=firefox-build-system-reviewers,jgilbert,andi
Differential Revision: https://phabricator.services.mozilla.com/D121066
2021-07-29 23:38:31 +00:00
Jeff Gilbert 4121499edb Bug 1715690 - Generalize WebGL RENDERER into large buckets. r=lsalzman
+ Minor reduction in unused flexibility of limits.

Differential Revision: https://phabricator.services.mozilla.com/D117385
2021-06-14 21:27:08 +00:00
Butkovits Atila c5dac06788 Backed out changeset 45887183c584 (bug 1715690) for causing failures at SanitizeRenderer. CLOSED TREE 2021-06-12 04:12:18 +03:00
Jeff Gilbert de085c82e3 Bug 1715690 - Generalize WebGL RENDERER into large buckets. r=lsalzman
+ Minor reduction in unused flexibility of limits.

Differential Revision: https://phabricator.services.mozilla.com/D117385
2021-06-11 23:54:39 +00:00
Iulian Moraru 6dd0299bc3 Backed out changeset 67b696ec70a9 (bug 1715690) for causing build bustages on SanitizeRenderer.cpp. CLOSED TREE 2021-06-11 02:46:23 +03:00
Jeff Gilbert 22fa9e93cf Bug 1715690 - Generalize WebGL RENDERER into large buckets. r=lsalzman
+ Minor reduction in unused flexibility of limits.

Differential Revision: https://phabricator.services.mozilla.com/D117385
2021-06-10 22:55:50 +00:00
Henri Sivonen 4f51a00c2e Bug 1693534 - Avoid leaking the kernel version to the Web with amdgpu. r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D105636
2021-02-22 09:18:19 +00:00
Jeff Gilbert 09bc72760a Bug 1691606 - Clean up dead code following WebGL out-of-process stabilization. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D104495
2021-02-09 07:57:03 +00:00
Jeff Gilbert a8926ffa47 Bug 1640607 - Send SurfaceDescriptors for GPU blitting for video-to-webgl. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D101061
2021-01-14 01:23:06 +00:00
Ricky Stewart 02a7b4ebdf Bug 1654103: Standardize on Black for Python code in `mozilla-central`.
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-26 18:34:53 +00:00
Bogdan Tara da1098d4aa Backed out 10 changesets (bug 1654103, bug 1672023, bug 1518999) for PanZoomControllerTest.touchEventForResult gv-junit failures CLOSED TREE
Backed out changeset ff3fb0b4a512 (bug 1672023)
Backed out changeset e7834b600201 (bug 1654103)
Backed out changeset 807893ca8069 (bug 1518999)
Backed out changeset 13e6b92440e9 (bug 1518999)
Backed out changeset 8b2ac5a6c98a (bug 1518999)
Backed out changeset 575748295752 (bug 1518999)
Backed out changeset 65f07ce7b39b (bug 1518999)
Backed out changeset 4bb80556158d (bug 1518999)
Backed out changeset 8ac8461d7bd7 (bug 1518999)
Backed out changeset e8ba13ee17f5 (bug 1518999)
2020-10-24 03:36:18 +03:00
Ricky Stewart c0cea3b0fa Bug 1654103: Standardize on Black for Python code in `mozilla-central`. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-23 20:40:42 +00:00
Mike Hommey 91d99a2d66 Bug 1671376 - Disable -Wmissing-braces on clang < 6. r=firefox-build-system-reviewers,dmajor
The warning is broken in older versions of clang. It also turns out we
were disabling it locally for some directories because of this very
problem.

A few local disable rules stay under accessible/ because they do hide
actual warnings from code generated by MIDL.

Differential Revision: https://phabricator.services.mozilla.com/D94262
2020-10-22 01:31:19 +00:00
Dorel Luca 1ff59cb7a3 Backed out changeset 7558c8821a07 (bug 1654103) for multiple failures. CLOSED TREE 2020-10-22 03:51:06 +03:00
Ricky Stewart 50762dacab Bug 1654103: Standardize on Black for Python code in `mozilla-central`. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-21 21:27:27 +00:00
Simon Giesecke 1e6ec7ec86 Bug 1656117 - Reduce include dependencies on nsRefreshDriver.h. r=mstange
The abstract observer base classes are moved to a separate header file
nsRefreshObservers.h and the includes are adjusted accordingly.

Some method implementations are moved to the corresponding implementation files
to avoid the need to include the nsRefreshDriver.h file in the header.

Differential Revision: https://phabricator.services.mozilla.com/D85764
2020-08-04 21:17:50 +00:00
Simon Giesecke 754c06d4eb Bug 1653193 - Remove public includes for CanvasRenderingContext2D.h. r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D83752
2020-07-21 08:39:53 +00:00
sanketh d66dab82a7 Bug 1621433 - In RFP mode, turn canvas image extraction into a random 'poison pill' for fingerprinters r=tjr,jrmuizel
In RFP mode, canvas image extraction leads to an all-white image, replace that
with a random (sample 32 bytes of randomness and fill the buffer with that)
'poison pill'. This helps defeat naive fingerprinters by producing a random
image on every try. This feature is toggled using a new, default on, pref
`privacy.resistFingerprinting.randomDataOnCanvasExtract`.

Updated `browser_canvas_fingerprinting_resistance.js` to test this new feature
as well.

Updates and replaces D66308.

Differential Revision: https://phabricator.services.mozilla.com/D72716
2020-05-14 13:56:55 +00:00
Csoregi Natalia 4bb1a50963 Backed out changeset 8a48a3a488ab (bug 1621433) for hazard failures on CanvasRenderingContext2D.cpp CLOSED TREE 2020-05-08 09:39:25 +03:00
sanketh 44762b8054 Bug 1621433 - In RFP mode, turn canvas image extraction into a random 'poison pill' for fingerprinters r=tjr,jrmuizel
In RFP mode, canvas image extraction leads to an all-white image, replace that
with a random (sample 32 bytes of randomness and fill the buffer with that)
'poison pill'. This helps defeat naive fingerprinters by producing a random
image on every try. This feature is toggled using a new, default on, pref
`privacy.resistFingerprinting.randomDataOnCanvasExtract`.

Updated `browser_canvas_fingerprinting_resistance.js` to test this new feature
as well.

Updates and replaces D66308.

Differential Revision: https://phabricator.services.mozilla.com/D72716
2020-05-07 22:45:27 +00:00
David Parks 180f310d81 Bug 1621762: Part 6 - Add and define IpdlQueue for WebGL IPC r=jgilbert
The IpdlQueue (de)serializes types into arrays that are then passed to another process via IPDL messages.  This means much less bloat than generating IPDL routines for each of the commands we send with WebGL.  This IPDL queue is fairly basic -- it simply sends "async" commands through an async IPDL message and sync commands through a sync message.  Future extensions, such as a facility for buffering async messages to be sent in bulk, are planned.
The IpdlQueue uses an existing actor to send messages.  That actor should derive from one of the provided base classes and implement any needed IPDL message.  For example, if the actor is used as the comsumer for sync messages then it should subclass SyncConsumerActor and should Recv (via IPDL) the ExchangeIpdlQueueData message -- the handler method for which is defined in the SyncProducerActor base class.

Differential Revision: https://phabricator.services.mozilla.com/D68263
2020-04-30 22:24:00 +00:00
David Parks 7ac7bc9be6 Bug 1621762: Part 4 - Move some code from ProducerConsumerQueue.h to QueueParamTraits.h r=jgilbert
Move QueueParamTraits, which are common between PCQ and IpdlQueue, to a file they both include.  This also changes the namespace of a handful of the classes, like the Marshaller.

Differential Revision: https://phabricator.services.mozilla.com/D68260
2020-04-30 22:23:10 +00:00
Daniel Varga 452acadb3b Backed out 7 changesets (bug 1621762) for causing build bustages at builds/worker/workspace/obj-build/dist/include/mozilla/dom/ProducerConsumerQueue.h
CLOSED TREE

Backed out changeset 03903e8f368e (bug 1621762)
Backed out changeset 21ef72486643 (bug 1621762)
Backed out changeset 70d103786c83 (bug 1621762)
Backed out changeset a3e1332998c3 (bug 1621762)
Backed out changeset 010f653b87d2 (bug 1621762)
Backed out changeset 0496adcb4582 (bug 1621762)
Backed out changeset 8d85420fd2e6 (bug 1621762)
2020-04-30 06:06:33 +03:00
David Parks d83a9ffcc2 Bug 1621762: Part 6 - Add and define IpdlQueue for WebGL IPC r=jgilbert
The IpdlQueue (de)serializes types into arrays that are then passed to another process via IPDL messages.  This means much less bloat than generating IPDL routines for each of the commands we send with WebGL.  This IPDL queue is fairly basic -- it simply sends "async" commands through an async IPDL message and sync commands through a sync message.  Future extensions, such as a facility for buffering async messages to be sent in bulk, are planned.
The IpdlQueue uses an existing actor to send messages.  That actor should derive from one of the provided base classes and implement any needed IPDL message.  For example, if the actor is used as the comsumer for sync messages then it should subclass SyncConsumerActor and should Recv (via IPDL) the ExchangeIpdlQueueData message -- the handler method for which is defined in the SyncProducerActor base class.

Differential Revision: https://phabricator.services.mozilla.com/D68263
2020-04-30 01:03:51 +00:00
David Parks 7b22a25f49 Bug 1621762: Part 4 - Move some code from ProducerConsumerQueue.h to QueueParamTraits.h r=jgilbert
Move QueueParamTraits, which are common between PCQ and IpdlQueue, to a file they both include.  This also changes the namespace of a handful of the classes, like the Marshaller.

Differential Revision: https://phabricator.services.mozilla.com/D68260
2020-04-30 01:02:58 +00:00
Kearwood Gilbert 9136ce65cf Bug 1614496 - Implement WebXR Core Module DOM Interfaces r=jgilbert,daoshengmu,webidl,smaug,baku,imanol
Implement DOM interfaces for the WebXR Core Module. Additional work to implement the WebXR Core Module are marked with TODO (Bug #) comments within the patch and must be landed before enabling the dom.vr.webxr.enabled flag.

Differential Revision: https://phabricator.services.mozilla.com/D62369

--HG--
extra : moz-landing-system : lando
2020-04-06 19:33:32 +00:00