mirror of
https://github.com/GreemDev/Ryujinx.git
synced 2025-02-02 14:37:12 -03:00
misc: chore: code cleanups
This commit is contained in:
parent
f81cb093fc
commit
33079422fe
5 changed files with 21 additions and 6 deletions
|
@ -8,7 +8,7 @@ namespace Ryujinx.Common
|
||||||
{
|
{
|
||||||
public static class TitleIDs
|
public static class TitleIDs
|
||||||
{
|
{
|
||||||
public static ReactiveObject<Optional<string>> CurrentApplication { get; set; } = new();
|
public static ReactiveObject<Optional<string>> CurrentApplication { get; } = new();
|
||||||
|
|
||||||
public static GraphicsBackend SelectGraphicsBackend(string titleId, GraphicsBackend currentBackend)
|
public static GraphicsBackend SelectGraphicsBackend(string titleId, GraphicsBackend currentBackend)
|
||||||
{
|
{
|
||||||
|
|
|
@ -161,5 +161,20 @@ namespace Ryujinx.HLE
|
||||||
{
|
{
|
||||||
return 1000 / _frameRate[FrameTypeGame];
|
return 1000 / _frameRate[FrameTypeGame];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public string FormatGameFrameRate()
|
||||||
|
{
|
||||||
|
double frameRate = GetGameFrameRate();
|
||||||
|
double frameTime = GetGameFrameTime();
|
||||||
|
|
||||||
|
return $"{frameRate:00.00} FPS ({frameTime:00.00}ms)";
|
||||||
|
}
|
||||||
|
|
||||||
|
public string FormatFifoPercent()
|
||||||
|
{
|
||||||
|
double fifoPercent = GetFifoPercent();
|
||||||
|
|
||||||
|
return $"FIFO: {fifoPercent:00.00}%";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,8 +34,8 @@ namespace Ryujinx.HLE
|
||||||
|
|
||||||
public int CpuCoresCount = 4; //Switch 1 has 4 cores
|
public int CpuCoresCount = 4; //Switch 1 has 4 cores
|
||||||
|
|
||||||
public VSyncMode VSyncMode { get; set; } = VSyncMode.Switch;
|
public VSyncMode VSyncMode { get; set; }
|
||||||
public bool CustomVSyncIntervalEnabled { get; set; } = false;
|
public bool CustomVSyncIntervalEnabled { get; set; }
|
||||||
public int CustomVSyncInterval { get; set; }
|
public int CustomVSyncInterval { get; set; }
|
||||||
|
|
||||||
public long TargetVSyncInterval { get; set; } = 60;
|
public long TargetVSyncInterval { get; set; } = 60;
|
||||||
|
|
|
@ -1151,8 +1151,8 @@ namespace Ryujinx.Ava
|
||||||
LocaleManager.Instance[LocaleKeys.VolumeShort] + $": {(int)(Device.GetVolume() * 100)}%",
|
LocaleManager.Instance[LocaleKeys.VolumeShort] + $": {(int)(Device.GetVolume() * 100)}%",
|
||||||
dockedMode,
|
dockedMode,
|
||||||
ConfigurationState.Instance.Graphics.AspectRatio.Value.ToText(),
|
ConfigurationState.Instance.Graphics.AspectRatio.Value.ToText(),
|
||||||
$"{Device.Statistics.GetGameFrameRate():00.00} FPS ({Device.Statistics.GetGameFrameTime():00.00} ms)",
|
Device.Statistics.FormatGameFrameRate(),
|
||||||
$"FIFO: {Device.Statistics.GetFifoPercent():00.00} %",
|
Device.Statistics.FormatFifoPercent(),
|
||||||
_displayCount));
|
_displayCount));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -22998,4 +22998,4 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
Loading…
Add table
Reference in a new issue