android / android/games-samples

Unity Power Efficiency Demo: setFrameRate not working

Open
#76 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
307
Forks
138
Avg merge
8d 11h
Merged PRs (30d)
2

Description

Setting the refresh rate via the `Surface.setFrameRate()` method of unitySurfaceView is not working.

I have enabled the 'Show Refresh Rate' option in the developer settings and set the screen refresh rate to 90Hz in the system settings.

Observation:
- When starting the app, the refresh rate is 90Hz. However, after idling for 20 seconds, it changes to 30Hz.
- Calling `setFrameRate()` with a value of 60Hz still shows 90Hz initially, but after idling, it displays 60Hz.

This was tested on Redmi 12 5g

Contributor guide

Open the contributing guide

Research direction

Start by locating the Unity Power Efficiency Demo and the unitySurfaceView call to Surface.setFrameRate(). Reproduce the behavior on a Redmi 12 5G with Show Refresh Rate enabled, then verify that the requested rate remains effective after the app idles for 20 seconds.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, cpp, unity
Domain
game-dev, mobile, performance
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.