Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

fix(ngAnimate): buffer repeated calls to RAF to improve performance for animations #12347

Closed
wants to merge 1 commit into from

Conversation

matsko
Copy link
Contributor

@matsko matsko commented Jul 14, 2015

Prior to this patch ngAnimate buffered all repeated calls to
requestAnimationFrame into a task queue that is flushed once the next
animation frame has passed. While this works it causes a random lag to
jump out when any CPU intensive rAF requests are processed. This patch
sets a configurable task range which then offsets followup rAF requests
into the next available frame.

Closes #12280

@matsko matsko force-pushed the intelligent_raffing branch from 1cc6317 to 6dcca5a Compare July 14, 2015 20:15
…or animations

Prior to this patch ngAnimate buffered all repeated calls to
requestAnimationFrame into a task queue that is flushed once the next
animation frame has passed. While this works it causes a random lag to
jump out when any CPU intensive rAF requests are processed. This patch
sets a configurable task range which then offsets followup rAF requests
into the next available frame.

Closes angular#12280
@matsko matsko force-pushed the intelligent_raffing branch from 6dcca5a to 56fe8db Compare July 14, 2015 20:16
@gkalpak
Copy link
Member

gkalpak commented Jul 15, 2015

LGTM

The implementation seems unnecessarily complex imo. I don't have proof though and since I can't spot any functional issue/bug (e.g. as was the case with the previous implementation), I'll leave it to the LGTM 😄

@matsko
Copy link
Contributor Author

matsko commented Aug 19, 2015

Closed in favour of: #12619

@matsko matsko closed this Aug 19, 2015
@matsko matsko deleted the intelligent_raffing branch August 19, 2015 00:29
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants