pub enum Effect {
None,
Transform(Matrix4),
ClipRect {
rect: Rect,
clip_behavior: Clip,
},
ClipRRect {
rrect: RRect,
clip_behavior: Clip,
},
ClipPath {
path: Path,
clip_behavior: Clip,
},
Opacity {
alpha: u8,
offset: Offset,
},
BackdropFilter {
filter: ImageFilter,
blend_mode: BlendMode,
backdrop_id: Option<u64>,
},
ImageFilter {
filter: ImageFilter,
offset: Offset,
},
}Expand description
What a container does to its children: which of flow’s containers it is.
Variants§
None
flow’s ContainerLayer itself, which does nothing: the scene’s root.
Transform(Matrix4)
TransformLayer: the children’s coordinates taken through the matrix. push_transform,
and push_offset as a translation.
ClipRect
ClipRectLayer: nothing of the children outside the rectangle.
ClipRRect
ClipRRectLayer: nothing of the children outside the rounded rectangle.
ClipPath
ClipPathLayer: nothing of the children outside the path, filled by its fill type.
Opacity
OpacityLayer: the children moved by offset and composited as one at alpha, out of
255.
BackdropFilter
BackdropFilterLayer: what lies beneath filtered, then blended back with blend_mode,
before the children paint. Filters sharing a backdrop_id sample one backdrop.
ImageFilter
ImageFilterLayer: the children moved by offset and composited as one through filter.