Custom Transform Basic

Apply custom transformation matrices to shapes

View code & preview
Direct Update Basic

Direct shape updates with retained properties

View code & preview
Fill Rule Basic

Demonstrate shape fill rules

View code & preview
Fill Spread Basic

Demonstrate gradient spread modes: pad, reflect, and repeat

View code & preview
Gradient Stroke Basic

Apply linear and radial gradients to strokes

View code & preview
Gradient with Transforms Basic

Animate gradients with shape transformations

View code & preview
Linear Gradient Basic

Apply linear and radial gradients to shapes

View code & preview
Image Rotation Basic

Rotate images around center origin

View code & preview
Image Scaling Basic

Scale images around center origin

View code & preview
Opacity Basic

Demonstrate opacity control on shapes and scenes

View code & preview
Path Drawing Basic

Draw shapes using path commands

View code & preview
Radial Gradient Basic

Demonstrate radial gradients

View code & preview
Scene Blending Basic

Demonstrate scene blending modes

View code & preview
Scene Transform Basic

Animate scene transformations with rotate, scale, and translate

View code & preview
Shapes Basic

Draw simple shapes

View code & preview
Stroke Line Basic

Demonstrate stroke join and cap styles

View code & preview
Stroke Miter Limit Basic

Demonstrate stroke miter limit behavior

View code & preview
Stroke Basic

Demonstrate stroke width, join, and cap styles

View code & preview
Shape Transform Basic

Animate shapes with rotation and scaling

View code & preview
Path Trimming Basic

Trim paths to show only portions of shapes

View code & preview
Accessor Advanced

Traverse a picture scene tree and modify paint properties by ID

View code & preview
Blending Advanced

Demonstrate all blend modes with various paint types

View code & preview
Bounding Box Advanced

Display bounding boxes around objects

View code & preview
Clipping Advanced

Demonstrate clipping for shapes and scenes

View code & preview
Duplication Advanced

Duplicate shapes, scenes, pictures, and objects

View code & preview
Effect Drop Shadow Advanced

Drop shadow effect applied to scene content

View code & preview
Error Handling Advanced

Global error handler catches

View code & preview
Gradient Masking Advanced

Demonstrate Alpha and InvAlpha masking with linear gradients

View code & preview
Intersects Advanced

Interactive example demonstrating paint.intersects() API with mouse hover detection

View code & preview
Masking Advanced

Demonstrate Alpha, InvAlpha, Luma, and InvLuma masking with various paint types

View code & preview
Masking Methods Advanced

Demonstrate all 6 mask composition methods (Add, Subtract, Intersect, Difference, Lighten, Darken)

View code & preview
Scene Effects Advanced

Comprehensive demonstration of all scene effects: Gaussian Blur, Fill, Tint, and Tritone

View code & preview
Viewport Advanced

Control canvas viewport for panning effects

View code & preview
Font Provider Text

Use a custom font provider to load fonts from any source

View code & preview
Text Effects Text

Demonstrate text animation with multiple effects

View code & preview
Text Layout Text

Demonstrate text layout with alignment within a bounding box

View code & preview
Text Line Wrap Text

Demonstrate text wrapping modes with different alignments

View code & preview
Text OTF Text

Render text with OpenType fonts

View code & preview
Text TTF Text

Render text with TrueType fonts

View code & preview
JPG Media

Load and display JPG images

View code & preview
Lottie Media

Load and play a Lottie animation with playback controls

View code & preview
Lottie Expressions Media

Lottie animations with expressions support

View code & preview
Lottie Slots Media

Override Lottie properties at runtime with slots (color, gradient, transform, text)

View code & preview
Lottie Interaction Media

Drag on the canvas to spin the Lottie in real time — driven by expression slots

View code & preview
Lottie Asset Resolver Media

Supply external Lottie assets (images, fonts) at runtime via a resolver callback

View code & preview
PNG Media

Load and display PNG images

View code & preview
Raw Media

Load and display raw ARGB8888 image data

View code & preview
SVG Media

Load and display the Ghostscript Tiger SVG

View code & preview
WebP Media

Load and display WebP images

View code & preview