mirror of
https://github.com/moonlight-stream/moonlight-android.git
synced 2026-10-20 15:27:18 +00:00
Ignore bogus refresh rates just to be on the safe side
This commit is contained in:
1 parent
d4ff58b3ad
commit
3bcd2ee068
2 files changed
+5
-1
No files matched your search
@@ -329,6 +329,10 @@ public class Game extends Activity implements SurfaceHolder.Callback,
|
||||
// Hopefully, we can get rid of this once someone comes up with a better way
|
||||
// to track the state of the pipeline and time frames.
|
||||
int roundedRefreshRate = Math.round(displayRefreshRate);
|
||||
if (roundedRefreshRate <= 49) {
|
||||
// Let's avoid clearly bogus refresh rates
|
||||
roundedRefreshRate = 60;
|
||||
}
|
||||
if (!prefConfig.disableFrameDrop && prefConfig.fps >= roundedRefreshRate) {
|
||||
prefConfig.fps = roundedRefreshRate - 1;
|
||||
LimeLog.info("Adjusting FPS target for screen to "+prefConfig.fps);
|
||||
|
||||
Reference in new issue
Block a user