Jump to content
Search Community

Having calls at the end of each timeline improves performance

eduardfossas test
Moderator Tag

Recommended Posts

Hello, I have two versions, one that we can call a prototype and the other one we could call it a production version.

 

The prototype looks like:

SPINNER_TIMELINE.to(..., {...})

function animateHero() {
	INTRO_TIMELINE.to(..., {...})
}

SPINNER_TIMELINE.call(() => animateHero())

And then the production version looks like this:

 

SPINNER_TIMELINE.to(..., {...})
INTRO_TIMELINE.to(..., {...})

MASTER_TIMELINE.to(SPINNER_TIMELINE, {}).to(HERO_TIMELINE, {}).play()

Funnily enough, the second version, which for me has more sense, it makes animations look with a low frame rate.

 

Do you know the reason why?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...