Models on Sketchfab.com run slower with Webrender software fallback
Categories
(Core :: Graphics: WebRender, defect)
Tracking
()
People
(Reporter: rdoghi, Assigned: gw)
References
(Blocks 1 open bug)
Details
Attachments
(3 files)
[Affected platforms]:
Platforms: Windows 8 / 8.1 , Windows 7, Windows 10
GPU's : AMD Rx550, Intel HD 5500, Nvidia GeForce 730
[Steps to reproduce]
- Launch the Firefox browser and set both gfx.webrender.enabled, gfx.webrender.software = true
- Reach https://sketchfab.com/3d-models/the-turtle-ee2c18fce41c4942b2a99a8638f48858 and wait for the model to load.
- Move/Rotate the Model, Zoom in/out.
[Expected result]
The 3D modal should rotate and move smooth without any issues.
[Actual result]
The 3D model animation looks like its losing frames, its slow when its being rotated or zoomed in and out.
Please note that with WebRender enabled but with gfx.webrender.enabled, gfx.webrender.software = FALSE, this issue does not occur.
Reporter | ||
Comment 1•4 years ago
|
||
Attaching the about:support file
Reporter | ||
Comment 2•4 years ago
|
||
Reporter | ||
Comment 3•4 years ago
|
||
Adding 2 Performance profiles captured in Beta and Nightly
Comment 4•4 years ago
|
||
I can reproduce this locally. It looks like we're spending a bunch of time in the drawing gradients (presumably every time the webgl updates)
Comment 5•4 years ago
|
||
The webgl canvas's parent element has a background-image: linear-gradient(), linear-gradient()
. Disabling this background-image improves performance dramatically.
Comment 6•4 years ago
|
||
The webgl appears to have {alpha: false} so we should be able to avoid doing this drawing. Glenn, do we have the infrastructure to prevent this drawing from happening? Shouldn't the depth buffer be saving us at a minimum?
Reporter | ||
Updated•4 years ago
|
Reporter | ||
Updated•4 years ago
|
Assignee | ||
Comment 7•4 years ago
|
||
It's failing to promote the webgl canvas to an external compositor surface because it thinks that the canvas needs a clip-mask applied.
This means that the canvas is composited into the picture cache slice, and thus invalidates the tile, causing rasterization of both the gradient and blitting the canvas into the tile every time it's rotated.
It's not clear to me yet why it thinks it needs a clip-mask - investigating further now.
Assignee | ||
Comment 8•4 years ago
|
||
The clip that results in a mask is a normal rectangle clip, there are no complex clips involved.
WR creates a mask as it thinks that the clip rectangle is in a different coordinate space (non-axis-aligned) than the primitive - it's not clear yet whether that is a simple bug, some accuracy issue, or a genuine issue.
Assignee | ||
Comment 9•4 years ago
|
||
The source transform for the canvas surface is source_transform: Value([1.0008518, 0.0, 0.0, 0.0, -0.0, -1.0, -0.0, -0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 657.0, 0.0, 1.0])
which looks like it should be handled as a ScaleOffset
. Perhaps the -0.0
is tripping up the logic that determines if a transform only contains scale / offset.
Assignee | ||
Comment 10•4 years ago
|
||
It's actually the negative scale / reflect that is causing WR to select this as a different coordinate system. However, if I allow that to be considered a ScaleOffset
the webgl surface doesn't draw at all, so there is a deeper reason why we don't currently handle this as a compatible coordinate system.
Assignee | ||
Comment 11•4 years ago
|
||
This will be fixed when #1700539 lands.
Assignee | ||
Comment 12•4 years ago
|
||
This should be fixed in m-c now - if you enable the picture caching debug overlay, you should be able to rotate the model without any tile invalidations occurring. If you're able to verify this, we can close this bug.
Reporter | ||
Comment 13•4 years ago
|
||
Yup this issue is verified as fixed in 89.0a1 (2021-03-31).
Assignee | ||
Comment 14•4 years ago
|
||
Great, thanks for checking.
Description
•