Class

AnimationSequencer

AnimationSequencer.AnimationSequencer()

Advanced animation sequencer with timeline controls

Constructor

# new AnimationSequencer()

View Source utils/animationSequencer.js, line 256

Methods

# addMarker(name, time, color)

Add time marker

Parameters:
Name Type Default Description
name string

Marker name

time number

Marker time

color string #ff0000

Marker color

View Source utils/animationSequencer.js, line 471

# addRegion(name, startTime, endTime, color)

Add time region

Parameters:
Name Type Default Description
name string

Region name

startTime number

Start time

endTime number

End time

color string #0080ff40

Region color

View Source utils/animationSequencer.js, line 490

# addTrack(track)

Add animation track

Parameters:
Name Type Description
track AnimationTrack

Track to add

View Source utils/animationSequencer.js, line 284

# batch(operations)

Batch operations for performance

Parameters:
Name Type Description
operations function

Operations to batch

View Source utils/animationSequencer.js, line 623

# createTrack(name, keyframeData, target) → {AnimationTrack}

Create new track with keyframes

Parameters:
Name Type Default Description
name string

Track name

keyframeData Array

Array of keyframe data

target * null

Target object

View Source utils/animationSequencer.js, line 314

Created track

AnimationTrack

# export() → {Object}

Export sequence data

View Source utils/animationSequencer.js, line 506

Sequence data

Object

# generatePreview(samples) → {Array}

Generate animation preview

Parameters:
Name Type Default Description
samples number 100

Number of time samples

View Source utils/animationSequencer.js, line 574

Preview data

Array

# getCurrentState() → {Object}

Get current state of all tracks

View Source utils/animationSequencer.js, line 453

Current animation state

Object

# getTrack(trackName) → {AnimationTrack}

Get track by name

Parameters:
Name Type Description
trackName string

Track name

View Source utils/animationSequencer.js, line 303

Track instance

AnimationTrack

# import(data)

Import sequence data

Parameters:
Name Type Description
data Object

Sequence data

View Source utils/animationSequencer.js, line 535

# notifyPlayStateChange()

Notify play state change listeners

View Source utils/animationSequencer.js, line 604

# notifyTimeUpdate()

Notify time update listeners

View Source utils/animationSequencer.js, line 595

# notifyTrackUpdate()

Notify track update listeners

View Source utils/animationSequencer.js, line 613

# removeMarker(name)

Remove time marker

Parameters:
Name Type Description
name string

Marker name

View Source utils/animationSequencer.js, line 479

# removeRegion(name)

Remove time region

Parameters:
Name Type Description
name string

Region name

View Source utils/animationSequencer.js, line 498

# removeTrack(trackName)

Remove animation track

Parameters:
Name Type Description
trackName string

Track name to remove

View Source utils/animationSequencer.js, line 293

# seekTo(time)

Seek to specific time

Parameters:
Name Type Description
time number

Time to seek to

View Source utils/animationSequencer.js, line 379

# setDuration(duration)

Set sequence duration

Parameters:
Name Type Description
duration number

Duration in milliseconds

View Source utils/animationSequencer.js, line 417

# setLoop(enabled)

Set loop mode

Parameters:
Name Type Description
enabled boolean

Loop enabled

View Source utils/animationSequencer.js, line 409

# setPlaybackSpeed(speed)

Set playback speed

Parameters:
Name Type Description
speed number

Playback speed multiplier

View Source utils/animationSequencer.js, line 395

# stop()

Stop playback and reset

View Source utils/animationSequencer.js, line 360

# update()

Update animation frame

View Source utils/animationSequencer.js, line 427