Skip to content

Time leakage bug in anime.js when looping animations #5361

@mrxz

Description

@mrxz

Description:
Every time an animation loops the excess time is ignored. This leads to "time leakage" which can accumulate over time or cause issues when high delta times occur for a given tick. This can easily be triggered by giving focus to another tab, which causes browsers to reduce or halt the rAF until the user clicks back again.

Real-world case where this bug causes multiple entities with the same looping animations randomly offset from each other to end up synchronized. 3DStreet/3dstreet#364

This is a known bug in anime.js (juliangarnier/anime#561) and is also present in A-Frame's fork. Filing this bug here instead for easier discovery in case other people face this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions