androidx.compose.ui.graphics
Interfaces
Canvas | |
GraphicsLayerScope |
A scope which can be used to define the effects to apply for the content, such as scaling (scaleX, scaleY), rotation (rotationX, rotationY, rotationZ), opacity (alpha), shadow (shadowElevation, shape), and clipping (clip, shape). |
ImageBitmap |
Graphics object that represents a 2 dimensional array of pixel information represented as ARGB values |
Paint | |
Path | |
PathEffect |
Effect applied to the geometry of a drawing primitive. |
PathMeasure | |
Shape |
Defines a generic shape. |
Classes
AndroidPaint | |
AndroidPath | |
AndroidPathMeasure | |
Brush | |
CanvasHolder |
Holder class that is used to issue scoped calls to a Canvas from the framework equivalent canvas without having to allocate an object on each draw call |
Color |
The |
ColorFilter |
Effect used to modify the color of each pixel drawn on a Paint that it is installed on |
ColorMatrix |
4x5 matrix for transforming the color and alpha components of a source. |
LinearGradient |
Brush implementation used to apply a linear gradient on a given Paint |
Matrix | |
NativeColorFilter | |
Outline |
Defines a simple shape, used for bounding graphical regions. |
PixelMap |
Result of a pixel read operation. |
RadialGradient |
Brush implementation used to apply a radial gradient on a given Paint |
ShaderBrush |
Brush implementation that wraps and applies a the provided shader to a Paint The shader can be lazily created based on a given size, or provided directly as a parameter |
Shadow |
A single shadow. |
SolidColor | |
SweepGradient |
Brush implementation used to apply a sweep gradient on a given Paint |
TransformOrigin |
A two-dimensional position represented as a fraction of the Layer's width and height |
Vertices |
A set of vertex data used by Canvas.drawVertices. |
Enums
BlendMode |
Algorithms to use when painting on the canvas. |
ClipOp |
Defines how a new clip region should be merged with the existing clip region. |
FilterQuality | |
ImageBitmapConfig |
Possible ImageBitmap configurations. |
PaintingStyle |
Strategies for painting shapes and paths on a canvas. |
PathFillType |
Determines the winding rule that decides how the interior of a Path is calculated. |
PathOperation |
Strategies for combining paths. |
PointMode |
Used by Canvas.drawPoints. |
StampedPathEffectStyle |
Strategy for transforming each point of the shape along the drawn path |
StrokeCap |
Styles to use for line endings. |
StrokeJoin |
Styles to use for line joins. |
TileMode | |
VertexMode |
Defines how a list of points is interpreted when drawing a set of triangles. |
Top-level constants summary
const Float |
Default alpha value used on Paint. |
const Float |
Default camera distance for all layers |
Top-level functions summary
Canvas | |
Canvas |
Canvas(image: ImageBitmap) Create a new Canvas instance that targets its drawing commands to the provided ImageBitmap |
Color |
Color(red: Float, green: Float, blue: Float, alpha: Float = 1f, colorSpace: ColorSpace = ColorSpaces.Srgb) Create a Color by passing individual red, green, blue, alpha, and colorSpace components. |
Color |
Creates a new Color instance from an ARGB color int. |
Color |