moffatman / chan

Flutter imageboard browser for iOS and Android
GNU General Public License v3.0
208 stars 8 forks source link

HIgh refresh rate support #210

Open OlegAckbar opened 1 week ago

OlegAckbar commented 1 week ago

Even on high refresh rate devices with 90 and 120 Hz support Chance is rendering at 60 fps which is visually annoying after using any other application of phone. Would be great if all animations in Chance were rendered at highest refresh rate for the device. Screenshot_2024-10-26-17-53-44-68_74831cf0187efc2b7189e40d20be2ea5

moffatman commented 1 week ago

it's 120hz on my Xiaomi MI MIX 4 double-tap on the "Development news" text on the top of the settings page. there's a secret menu there and you can enable a framerate overlay. a screenrecording of that on your phone might help me fix it for you.

OlegAckbar commented 1 week ago

Here's the recording. According to frametimes I should have around ~200 FPS, but my display shows 60hz mode.

Record_2024-10-26-21-51-31.webm

moffatman commented 1 week ago

Based on that graph Android is only scheduling frames at 60Hz. I would look around your device settings for some app specific power setting maybe? Chance renders more like a video game than other apps.... could be in some game power limiter?

OlegAckbar commented 1 week ago

I've managed to get Chance running at 90 Hz by setting "peak_refresh_rate" to "1" in SetEdit.