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

Skip to content
Commit c9664832 authored by Ady Abraham's avatar Ady Abraham
Browse files

SurfaceFlinger: refresh rate heuristic for TextureView

When an app uses a TextureView (or any other hwui based view)
hwui will attach presentation timestamps to each buffer for
for implementing its render ahead logic. SurfaceFlinger looks at
those timestamps and based on the frame rate it may decide to switch
to a refresh rate that better matches the content. When the refresh rate
changes, hwui may stop doing render ahead and therefore stop attaching
presentation timestamps. The way SurfaceFlinger handles that is by
calculating the content refresh rate by looking at the time the buffer
was queued. SurfaceFlinger will look at the queue time only if this
layer was providing presentation timestamps in the past.

Bug: 155710271
Test: Facebook feed playing video
Test: YouTube video with 24, 25, 30, 60 fps content
Change-Id: I3e981d192ec569087aa16d4c952ef9565d6fb234
parent b28c5cc1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment