MovieDrawable

class MovieDrawable @JvmOverloads constructor(movie: Movie, val config: Bitmap.Config = Bitmap.Config.ARGB_8888, val scale: Scale = Scale.FIT) : Drawable, Animatable2Compat

A Drawable that supports rendering Movies (i.e. GIFs).

NOTE: Prefer using AnimatedImageDecoder and AnimatedImageDrawable on API 28 and above.

Constructors

Link copied to clipboard
constructor(movie: Movie, config: Bitmap.Config = Bitmap.Config.ARGB_8888, scale: Scale = Scale.FIT)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
open override fun clearAnimationCallbacks()
Link copied to clipboard
open override fun draw(canvas: Canvas)
Link copied to clipboard
open override fun getIntrinsicHeight(): Int
Link copied to clipboard
open override fun getIntrinsicWidth(): Int
Link copied to clipboard

Get the number of times the animation will repeat.

Link copied to clipboard
open override fun isRunning(): Boolean
Link copied to clipboard
Link copied to clipboard
open override fun setAlpha(alpha: Int)
Link copied to clipboard

Set the AnimatedTransformation to apply when drawing.

Link copied to clipboard
open override fun setColorFilter(colorFilter: ColorFilter?)
Link copied to clipboard
fun setRepeatCount(repeatCount: Int)

Set the number of times to repeat the animation.

Link copied to clipboard
open override fun start()
Link copied to clipboard
open override fun stop()