Picture

class Picture : RefCnt

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

Returns the approximate byte size of Picture. Does not include large objects referenced by Picture.

Link copied to clipboard

Returns the approximate number of operations in SkPicture. Returned value may be greater or less than the number of SkCanvas calls recorded: some calls may be recorded as more than one operation, other calls may be optimized away.

Link copied to clipboard

Returns cull Rect for this picture, passed in when Picture was created. Returned Rect does not specify clipping Rect for Picture; cull is hint of Picture bounds.

Link copied to clipboard
expect open val isClosed: Boolean

Check if underlying resource is closed.

Link copied to clipboard
expect val refCount: Int

Number of references on underlying native object.

Link copied to clipboard

Returns a non-zero value unique among Picture in Skia process.

Functions

Link copied to clipboard
expect open fun close()

Free underlying native resource, peer is useless afterwards.

Link copied to clipboard
fun makeShader(tmx: FilterTileMode, tmy: FilterTileMode, mode: FilterMode, localMatrix: Matrix33? = null, tileRect: Rect? = null): Shader

Return a new shader that will draw with this picture. The tile rect is considered equal to the picture bounds.

Link copied to clipboard
fun playback(canvas: Canvas?, abort: () -> Boolean? = null): Picture

Replays the drawing commands on the specified canvas. In the case that the commands are recorded, each command in the Picture is sent separately to canvas.

Link copied to clipboard
Link copied to clipboard
expect open override fun toString(): String