Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 0f4a9597 authored by Shane's avatar Shane
Browse files

Update frame rate category changing logic

This CL is created to avoid the unnecessary (frequent) frame rate
category update. One observed scenario is that when a Video and an
animation have different invalidation intervals and sizes, it can cause
the frameRateCategory to be updated repeatedly.

To resolve this issue, we introudce counters for different category.
Everytime a category is voted, the value of the counter is set to 5 and
this value will be decrease by 1 every frame. When the value of a
counter is greater than 0, it will be taken into consideration when
determining the category to be set.

If the ViewRootImpl doesn't receive a vote of a category in 5 frames,
the category won't be taken into consideration anymore.

Test: atest ViewRootImplTest
Change-Id: I71e1f95381bc696865c50c2dc41a03f1646f5924
parent cb3aab75
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment