Repository navigation
feat(layers): add star, triangle, diamond, hexagon and speech bubble masks - #901
Merged
Merged
Conversation
…masks A layer mask offered an ellipse, a rounded rectangle, a heart and a linear edge. Hosts want more frames for picture-in-picture clips and stickers, such as a star for a celebration or a speech bubble for a reaction. Every new shape fills the mask's box like the heart does, so stretching, softness, inversion and `toImage` work unchanged. The speech bubble is built in the box's own coordinates so its corners stay round when the box is not square.
Every other mask shape mirrors when its box has a negative width or height. The speech bubble turned its corners inside out instead, and with a negative height its tail reached outside the box. It is now built at the box's absolute size and mirrored onto it.
This was referenced Oct 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Problem. A layer mask offers an ellipse, a rounded rectangle, a heart and a linear edge. Hosts want more frames for picture-in-picture clips and stickers: a star for a celebration, a speech bubble for a reaction, hexagons for a grid of clips.
Approach.
LayerMaskShapegainsstar,triangle,diamond,hexagonandspeechBubble.size,rotation,feather,invert,area,outline,toImageandapplyTowork unchanged.Not changed. Existing shapes paint, capture and serialise exactly as before. A
switchoverLayerMaskShapehas to handle the new values; the CHANGELOG says so.CHANGELOG 14.18.0.
Related Issue: Closes #none; requested in divinevideo/divine-mobile#10396.
Verification
flutter test: 1107 passed on Flutter 3.47.2;flutter analyzeclean;dart formatclean.Type of Change