class static
meteoJS/timeline/animation . Animation
Source: timeline/
Object to animate module:meteoJS/timeline.Timeline
.
import Animation from 'meteojs/timeline/Animation';
new Animation(options)
Parameter
Name | Type | Optional | Description |
---|---|---|---|
options |
|
|
Options. |
Methods
getImageFrequency() → number
Returns time frequency of animation steps (in 1/s).
- Returns
-
number
Time frequency.
getImagePeriod() → number
Returns time period between two animation steps (in s).
- Returns
-
number
Time period.
getRestartPause() → number
Returns time duration before a restart (jump from end to beginning, in s).
- Returns
-
number
Time duration.
isStarted() → boolean
Is animation started.
- Returns
-
boolean
setImageFrequency(imageFrequency) → module:meteoJS/timeline/animation.Animation
Sets time frequency of animation steps (in 1/s).
Parameter
Name | Type | Optional | Description |
---|---|---|---|
imageFrequency |
number |
|
Time frequency. |
- Returns
setImagePeriod(imagePeriod) → module:meteoJS/timeline/animation.Animation
Sets time period between to animation steps (in s)
Parameter
Name | Type | Optional | Description |
---|---|---|---|
imagePeriod |
number |
|
Time period. |
- Returns
setRestartPause(restartPause) → module:meteoJS/timeline/animation.Animation
Sets time duration before a restart (in s).
Parameter
Name | Type | Optional | Description |
---|---|---|---|
restartPause |
number |
|
Time duration. |
- Returns
start() → module:meteoJS/timeline/animation.Animation
Starts the animation.
- Fires
- module:meteoJS/timeline/animation#start:animation
- Returns
stop() → module:meteoJS/timeline/animation.Animation
Stops the animation.
- Fires
- module:meteoJS/timeline/animation#stop:animation
- Returns
toggle() → module:meteoJS/timeline/animation.Animation
Toggles the animation.
- Returns