Remote canvas only works with Direct2D (which has been removed) and has been superceded by Accelerated Canvas2D.
Thus, it is safe to remove remote canvas since it can no longer be enabled.
Differential Revision: https://phabricator.services.mozilla.com/D269928
This disables the legacy Direct2D backend in Windows Nightly in favor
of using Accelerated Canvas2D instead. The goal of this experiment
is to collect performance and other bug feedback on AC2D versus Direct2D.
In general, AC2D has been fairly stable on other platforms, so it would be
nice to gradually move towards using AC2D on Windows as well so that we
are using one consistent acceleration solution.
This experiment is the first step towards that end.
Differential Revision: https://phabricator.services.mozilla.com/D217851
This disables the legacy Direct2D backend in Windows Nightly in favor
of using Accelerated Canvas2D instead. The goal of this experiment
is to collect performance and other bug feedback on AC2D versus Direct2D.
In general, AC2D has been fairly stable on other platforms, so it would be
nice to gradually move towards using AC2D on Windows as well so that we
are using one consistent acceleration solution.
This experiment is the first step towards that end.
Differential Revision: https://phabricator.services.mozilla.com/D217851
This shares a global SharedContextWebgl among all instances of CanvasTranslator.
The goal is that regardless of how many windows are open, we only have to pay the
startup costs and shader compilation times for SharedContextWebgl once. In the
event that all CanvasTranslators are gone, the SharedContextWebgl is kept around
while its internal caches and textures are discarded to avoid significant memory
usage when no canvases are in use, while at the same time saving on startup
costs the next time a first live CanvasTranslator is created.
Differential Revision: https://phabricator.services.mozilla.com/D205977
This patch makes it so that we always shutdown gracefully by making
us flush the event queue for CanvasRenderThread, after blocking on the
task queues draining. This allows our dependencies like RemoteTextureMap
to shutdown successfully.
It also fixes a bug where CanvasTranslator::CanSend would still return
true on Windows, while blocked on in CanvasTranslator::ActorDestroy
waiting for the task queue to shutdown. The CanSend status is only
updated after ActorDestroy is called from IProtocol::DestroySubtree.
Differential Revision: https://phabricator.services.mozilla.com/D199186
This patch makes it so that we always shutdown gracefully by making
accelerated canvas also use a TaskQueue, albeit one that just uses the
CanvasRenderThread directly. This allows us to block shutdown on the
task queues draining before advancing to shutting down other
dependencies like RemoteTextureMap.
It also fixes a bug where CanvasTranslator::CanSend would still return
true on Windows, while blocked on in CanvasTranslator::ActorDestroy
waiting for the task queue to shutdown. The CanSend status is only
updated after ActorDestroy is called from IProtocol::DestroySubtree.
Differential Revision: https://phabricator.services.mozilla.com/D199186
The task queue makes NS_DECL_OWNINGEVENTTARGET confusing for single
threaded uses, when the canvas expects it can just dispatch to the
CanvasRenderThread directly.
Differential Revision: https://phabricator.services.mozilla.com/D191697
This patch makes the PCanvasManager protocol manage the PCanvas
protocol. This allows us to share a top level protocol and message
channel, as well as use the same thread as we need for WebGL. This will
allow future patches to do record/replay for WebGL, particularly for
configurations that do not support threadsafe GL.
Differential Revision: https://phabricator.services.mozilla.com/D187721
In preparation for moving PCanvas to be instantiated from
PCanvasManager, and running its IPDL objects on the virtual thread
chosen by CanvasRenderThread, this patch adds the necessary plumbing for
utilizing worker threads for PCanvas rendering.
A future patch in the series will make use of it.
Differential Revision: https://phabricator.services.mozilla.com/D187720
Prior to this patch, CanvasRenderThread represents the concrete thread
we would spawn if gfxVars::UseCanvasRenderThread() returned true.
CanvasManagerParent was responsible for checking our state and deciding
between using the Compositor, Renderer and CanvasRender threads.
This patch makes the CanvasRenderThread class represent a virtual
thread. It will spawn a CanvasRender thread if necessary. Other classes
may use the abstraction to run on the correct thread without having to
duplicate the selection logic.
Differential Revision: https://phabricator.services.mozilla.com/D187719
If dedicated thread for out-of-process WebGL exists, compositor thread tasks are not delayed by WebGL tasks.
And Bug 1712486 requests that WebGL run on non-compositor thread.
Differential Revision: https://phabricator.services.mozilla.com/D151210