ImageSource

sealed interface ImageSource(source)

A still image, either composited over video as a watermark or shown on the timeline in its own right.

A reference to an image rather than decoded pixels, so a composition holding one stays cheap to copy and to compare. The backend decodes it when it renders. Construct one through the companion factories, which are also what a Swift caller uses.

Inheritors

Types

Link copied to clipboard
class Bytes(val bytes: ByteArray) : ImageSource

Encoded image bytes, in any format the backend can decode.

Link copied to clipboard
object Companion
Link copied to clipboard
class Path(val path: String) : ImageSource

An image file on disk.

Link copied to clipboard
class Uri(val uri: String) : ImageSource

A platform URI or URL string.