Plugins/Async Drawing
Contents
General
- Async Drawing NPAPI spec
- Async Drawing Test Plan
- bug 1217665 - Revive async drawing code for plugins (dvander's landings)
Current WMODE Handling
Linux
WMODE | layout |
---|---|
unspecified | child window |
window | child window |
direct | child window |
opaque | shared surface (windowless) |
transparent | shared surface (windowless) |
OSX
Flash always uses a hybrid windowless mode.
Windows
Windows supports three modes, none of which involve window-backed surfaces:
- direct: Post Adobe Flash version 24, Flash offers a new async rendering API developed by Mozilla and Adobe. This mode handles that behavior. If
dom.ipc.plugins.allow_dxgi_surface=true
(the default) and the DirectX device supports it then hardware accelerated surfaces are used. Otherwise, this mode uses in-memory (unaccelerated) surfaces. - opaque: This mode always uses unaccelerated surfaces. It is intended for plugins that opaquely cover any HTML elements.
- transparent: This mode always uses unaccelerated surfaces. It is intended to blend with HTML elements. For that reason, this mode is slower than opaque mode.
Some wmode values are rewritten by Firefox to promote certain modes to more performant and stable modes.
When dom.ipc.plugins.forcedirect.enabled=true
(the default) [1] and dom.ipc.plugins.asyncdrawing.enabled=true
(also the default) we use:
Requested WMODE | Resulting WMODE | Rendering Mode (GPU supports acceleration) | Rendering Mode (GPU does not support acceleration) |
---|---|---|---|
window | direct | async (GPU accelerated) | async (in-memory bitmap) [2] |
gpu | direct | async (GPU accelerated) | async (in-memory bitmap) [3] |
unspecified | direct | async (GPU accelerated) | async (in-memory bitmap) [2] |
opaque | opaque | not async (in-memory bitmap) | not async (in-memory bitmap) |
transparent | transparent | not async (in-memory bitmap) | not async (in-memory bitmap) |
When dom.ipc.plugins.asyncdrawing.enabled=false
we use [4]:
Requested WMODE | Resulting WMODE | Rendering Mode |
---|---|---|
window | opaque | not async (in-memory bitmap) |
gpu | opaque | not async (in-memory bitmap) |
unspecified | opaque | not async (in-memory bitmap) |
opaque | opaque | not async (in-memory bitmap) |
transparent | transparent | not async (in-memory bitmap) |
[1] bug 1620461
[2] bug 1340276, bug 1359450
[3] bug 1565980
[4] bug 1620466
Telemetry Links
Telemetry Value | Platform | Type |
---|---|---|
0 | Windows, Linux | child window |
1 | OSX | NPDrawingModelQuickDraw |
2 | OSX | NPDrawingModelCoreGraphics |
3 | OSX | NPDrawingModelOpenGL |
4 | OSX | NPDrawingModelCoreAnimation |
5 | OSX | NPDrawingModelInvalidatingCoreAnimation |
6 | Windows | NPDrawingModelSyncWin |
7 | Linux | NPDrawingModelSyncX |
8 | Windows | NPDrawingModelAsyncBitmapSurface |
9 | Windows | NPDrawingModelAsyncWindowsDXGISurface |
PLUGIN_DRAWING_MODEL Nightly Evolution
Testing
To enable:
- dom.ipc.plugins.asyncdrawing.enabled=true
- dom.ipc.plugins.forcedirect.enabled=true (see bug 1620461)
- make sure you are running Flash version >= 23
Main Bug List
No results.
0 Total; 0 Open (0%); 0 Resolved (0%); 0 Verified (0%);
Breakdown
Bugs associated with performance problems.
ID | Summary | Status | Resolution | Whiteboard |
---|---|---|---|---|
1311740 | Since latest update of flash update, Firefox lags and freezes | RESOLVED | INCOMPLETE | repo? |
1311985 | massive performance decrease with certain Kongregate games when using Flash async drawing mode | RESOLVED | DUPLICATE | repo? |
1314467 | Huge performance regression when Flash object is opened in many tabs | RESOLVED | WORKSFORME | [parity-chrome] [parity-edge][qawanted , help gecko profile] |
1314491 | Kongregate's Flash game doesn't load with Flash protected mode disabled and plugin asyncdrawing enabled | RESOLVED | FIXED | fixed by bug 1348629 |
4 Total; 0 Open (0%); 4 Resolved (100%); 0 Verified (0%);
Bugs associated with incorrect clipping with surrounding content, z-order issues.
ID | Summary | Status | Resolution | Whiteboard |
---|---|---|---|---|
1306698 | When resize content/window, image under the flash plug-in is briefly display | RESOLVED | WONTFIX | layout, STR in comment #0 |
1 Total; 0 Open (0%); 1 Resolved (100%); 0 Verified (0%);
Bugs associated with missing plugin frames during painting. Need to determine if the issue is on our end of Adobe's.
ID | Summary | Status | Resolution | Whiteboard |
---|---|---|---|---|
1311524 | Buttons are inaccessible in a new window with Flash (poker's website) | RESOLVED | WORKSFORME | gfx |
1311867 | Flash content fails to paint initially. Content paints when focus is moved to another tab and then returned | RESOLVED | FIXED | gfx, transparency dupe?, testcase in comment #3 |
1311975 | Cannot interact with Flash Video Controls on certain site | RESOLVED | WORKSFORME | gfx, STR in comment #0 (32bit only) |
3 Total; 0 Open (0%); 3 Resolved (100%); 0 Verified (0%);
Bugs associated with incorrect background transparency, wmode="transparent" issues.
ID | Summary | Status | Resolution | Whiteboard |
---|---|---|---|---|
1311374 | Video fails to update after exiting full screen and scrolling the video in and out of view | RESOLVED | WORKSFORME | gfx, layout, STR in comment #0 |
1311928 | the video player on fivethirtyeight.com would not work. | RESOLVED | FIXED | adobe, STR in comment #0 |
1311990 | Painting issues with Farmville 2 (asyncdrawing) | RESOLVED | FIXED | gfx, STR in comment #0 |
1312043 | Paint issues with Comedy Central video player (asyncdrawing) | RESOLVED | FIXED | gfx, STR in comment #0 |
1312208 | Flash fails to paint on image upload site with async plugin painting | RESOLVED | INCOMPLETE | hold |
1312242 | Missing transparency in Adobe Flash objects with wmode="transparent" | RESOLVED | WORKSFORME | layout/gfx, tests, STR in comment #0 with attached test case |
1312293 | With async plugin painting Flash video on TVA website fails to paint / paints black | RESOLVED | FIXED | gfx, STR in comment #0 |
7 Total; 0 Open (0%); 7 Resolved (100%); 0 Verified (0%);
Regressions from the3 bgcolor fix.
ID | Summary | Status | Resolution | Whiteboard |
---|---|---|---|---|
1316438 | Flash plugin doesn't render most of display on Nightly with async painting enabled | RESOLVED | FIXED | [gfx-noted], regresion from bug 1312242, STR in comment #0 |
1 Total; 0 Open (0%); 1 Resolved (100%); 0 Verified (0%);
Bugs associated with sitecompat issues.
ID | Summary | Status | Resolution | Whiteboard |
---|---|---|---|---|
1312369 | dom.ipc.plugins.asyncdrawing.enabled changes mouse wheel behavior | RESOLVED | WONTFIX | sitecompat |
1 Total; 0 Open (0%); 1 Resolved (100%); 0 Verified (0%);