mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-19 00:05:36 +00:00
Bug 1687409
- Use offscreen surface for backface visibility + non-preserve3d stacking contexts r=nical
Removes another case of pass through pictures, by handling the rare case of a stacking context with backface-visibility: false that is _not_ part of a 3d rendering context as an offscreen surface. Differential Revision: https://phabricator.services.mozilla.com/D102251
This commit is contained in:
parent
8b93f9f4c5
commit
7db4ab6160
@ -1575,6 +1575,15 @@ impl<'a> SceneBuilder<'a> {
|
||||
blit_reason |= BlitReason::ISOLATE;
|
||||
}
|
||||
|
||||
// If backface visibility is explicitly set, force this stacking
|
||||
// context to be an off-screen surface. If part of a 3d context
|
||||
// (common case) it will already be an off-screen surface. If
|
||||
// the backface-vis is used while outside a 3d rendering context,
|
||||
// this is an edge case.
|
||||
if !prim_flags.contains(PrimitiveFlags::IS_BACKFACE_VISIBLE) {
|
||||
blit_reason |= BlitReason::ISOLATE;
|
||||
}
|
||||
|
||||
// If this stacking context has any complex clips, we need to draw it
|
||||
// to an off-screen surface.
|
||||
if let Some(clip_id) = clip_id {
|
||||
@ -3430,11 +3439,6 @@ impl FlattenedStackingContext {
|
||||
}
|
||||
}
|
||||
|
||||
// If backface visibility is explicitly set.
|
||||
if !prim_flags.contains(PrimitiveFlags::IS_BACKFACE_VISIBLE) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// If need to isolate in surface due to clipping / mix-blend-mode
|
||||
if !blit_reason.is_empty() {
|
||||
return false;
|
||||
|
Loading…
Reference in New Issue
Block a user