Layers events
These evetns are available for all layers. For layer-specific events, refer to the layer documentation.
To add a calback function to a layer event, do the following:
Note
Note that most layer methods can only be called after the event sourceReady has been emmited.
Events
Called only once after the layer has been added to the map, when all the necessary weather data source are loaded and ready to be used.
map
(Map)
: The map instance that contains the layer
layer
(Layer)
: The Layer instance that triggerred the event
Called when the animation is starting to play or plays after having been on pause after calling .animate(...)
time
(Number)
: the timestamp in seconds.
Called when the animation is being paused after calling .animate(0)
time
(Number)
: the timestamp in seconds.
Called for each animation update, possibly many times per seconds
time
(Number)
: the timestamp in seconds.
Called when the progress time of the animation is manually set with .setAnimationTime(...)
time
(Number)
: the timestamp in seconds.