Frames Animation
Simplifies the animation creation process by leveraging the power of AnimationDrawable. With a user-friendly setup and configuration, this component allows effortless control over frame duration, animation initiation, and termination, offering an intuitive way to bring your image collections to life.
All Blocks
Docs:
Events
OnErrorOccurred
Event triggered when an error occurs.
error | text
errorFrom | text
OnStartAnimation
Event triggered when the animation starts.
OnStopAnimation
Event triggered when the animation stops.
Methods
AddFrame
Add a frame to the animation.
imgPath | any
duration | number
Initialize
Initialize the animation with the specified ImageView component.
imageComponent | component
SetImage
Set the image for the specified ImageView component.
imageComponent | component
img | any
GetNumberOfFrames
Get the number of frames in the animation.
Return type : number
GetDuration
Get the duration of a specific frame in milliseconds.
index | number
Return type : number
GetImageAsDrawable
Get a specific frame as a Drawable.
index | number
Return type : any
GetImageAsBitmap
Get a specific frame as a Bitmap.
index | number
Return type : any
SelectFrame
Select a specific frame by index.
index | number
Start
Start frames animation
Stop
Stop frames animation
Properties
OnShot
Set the animation plays once or repeats.
Property Type : write-only
Accepts : boolean
OneShot
Check whether the animation plays once or repeats.
Property Type : read-only
Accepts : boolean
Demo Blocks
Demo
AIX
me.aemo.framesanimation.aix (12.0 KB)
AIA
FramesAnimationEx.aia (213.0 KB)