Skip to content

can cancel random requestAnimFrame() calback on hide()/pause() #15

Description

@RomanLut

frameID is assigned setTimeout() handle in requestRender() and then
cancelAnimationFrame(frameID) is called in pause().

Handles from setTimeout() should not be used with cancelAnimationFrame().

In my case, where I created and hided FPSMetter at game start, it killed PIXI's requestAnimationFrame callback sometimes. Chances to get handles with same value from setTimeout() and requestAnimationFrame() are high at application start.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions