mirror of
https://git.ryujinx.app/ryubing/ryujinx.git
synced 2025-04-24 09:25:12 +00:00
misc: chore: Simplify usages of HLEConfiguration constructor
This commit is contained in:
parent
6a2116f71a
commit
28526214ba
@ -312,60 +312,37 @@ namespace Ryujinx.Headless
|
||||
|
||||
return new OpenGLRenderer();
|
||||
}
|
||||
|
||||
|
||||
private static Switch InitializeEmulationContext(WindowBase window, IRenderer renderer, Options options) =>
|
||||
new(
|
||||
|
||||
new HleConfiguration(
|
||||
options.DramSize,
|
||||
options.SystemLanguage,
|
||||
options.SystemRegion,
|
||||
options.VSyncMode,
|
||||
!options.DisableDockedMode,
|
||||
!options.DisablePTC,
|
||||
ITickSource.RealityTickScalar,
|
||||
options.EnableInternetAccess,
|
||||
!options.DisableFsIntegrityChecks ? IntegrityCheckLevel.ErrorOnInvalid : IntegrityCheckLevel.None,
|
||||
options.FsGlobalAccessLogMode,
|
||||
options.SystemTimeOffset,
|
||||
options.SystemTimeZone,
|
||||
options.MemoryManagerMode,
|
||||
#if DEBUG
|
||||
new HleConfiguration(
|
||||
options.DramSize,
|
||||
options.SystemLanguage,
|
||||
options.SystemRegion,
|
||||
options.VSyncMode,
|
||||
!options.DisableDockedMode,
|
||||
!options.DisablePTC,
|
||||
ITickSource.RealityTickScalar,
|
||||
options.EnableInternetAccess,
|
||||
!options.DisableFsIntegrityChecks ? IntegrityCheckLevel.ErrorOnInvalid : IntegrityCheckLevel.None,
|
||||
options.FsGlobalAccessLogMode,
|
||||
options.SystemTimeOffset,
|
||||
options.SystemTimeZone,
|
||||
options.MemoryManagerMode,
|
||||
options.IgnoreMissingServices,
|
||||
options.AspectRatio,
|
||||
options.AudioVolume,
|
||||
options.UseHypervisor ?? true,
|
||||
options.MultiplayerLanInterfaceId,
|
||||
Common.Configuration.Multiplayer.MultiplayerMode.Disabled,
|
||||
false,
|
||||
string.Empty,
|
||||
string.Empty,
|
||||
options.CustomVSyncInterval
|
||||
)
|
||||
#else
|
||||
new HleConfiguration(
|
||||
options.DramSize,
|
||||
options.SystemLanguage,
|
||||
options.SystemRegion,
|
||||
options.VSyncMode,
|
||||
!options.DisableDockedMode,
|
||||
!options.DisablePTC,
|
||||
options.EnableInternetAccess,
|
||||
!options.DisableFsIntegrityChecks ? IntegrityCheckLevel.ErrorOnInvalid : IntegrityCheckLevel.None,
|
||||
options.FsGlobalAccessLogMode,
|
||||
options.SystemTimeOffset,
|
||||
options.SystemTimeZone,
|
||||
options.MemoryManagerMode,
|
||||
options.AspectRatio,
|
||||
options.AudioVolume,
|
||||
options.UseHypervisor ?? true,
|
||||
options.MultiplayerLanInterfaceId,
|
||||
Common.Configuration.Multiplayer.MultiplayerMode.Disabled,
|
||||
false,
|
||||
string.Empty,
|
||||
string.Empty,
|
||||
options.CustomVSyncInterval
|
||||
)
|
||||
options.IgnoreMissingServices,
|
||||
#endif
|
||||
options.AspectRatio,
|
||||
options.AudioVolume,
|
||||
options.UseHypervisor ?? true,
|
||||
options.MultiplayerLanInterfaceId,
|
||||
Common.Configuration.Multiplayer.MultiplayerMode.Disabled,
|
||||
false,
|
||||
string.Empty,
|
||||
string.Empty,
|
||||
options.CustomVSyncInterval
|
||||
)
|
||||
.Configure(
|
||||
_virtualFileSystem,
|
||||
_libHacHorizonManager,
|
||||
|
@ -843,68 +843,36 @@ namespace Ryujinx.Ava.Systems.Configuration
|
||||
}
|
||||
|
||||
public HleConfiguration CreateHleConfiguration() =>
|
||||
new(
|
||||
System.DramSize,
|
||||
System.Language.Value.ToHLE(),
|
||||
System.Region.Value.ToHLE(),
|
||||
Graphics.VSyncMode,
|
||||
System.EnableDockedMode,
|
||||
System.EnablePtc,
|
||||
System.TickScalar,
|
||||
System.EnableInternetAccess,
|
||||
System.EnableFsIntegrityChecks
|
||||
? IntegrityCheckLevel.ErrorOnInvalid
|
||||
: IntegrityCheckLevel.None,
|
||||
System.FsGlobalAccessLogMode,
|
||||
System.MatchSystemTime
|
||||
? 0
|
||||
: System.SystemTimeOffset,
|
||||
System.TimeZone,
|
||||
System.MemoryManagerMode,
|
||||
#if DEBUG
|
||||
new(
|
||||
System.DramSize,
|
||||
System.Language.Value.ToHLE(),
|
||||
System.Region.Value.ToHLE(),
|
||||
Graphics.VSyncMode,
|
||||
System.EnableDockedMode,
|
||||
System.EnablePtc,
|
||||
System.TickScalar,
|
||||
System.EnableInternetAccess,
|
||||
System.EnableFsIntegrityChecks
|
||||
? IntegrityCheckLevel.ErrorOnInvalid
|
||||
: IntegrityCheckLevel.None,
|
||||
System.FsGlobalAccessLogMode,
|
||||
System.MatchSystemTime
|
||||
? 0
|
||||
: System.SystemTimeOffset,
|
||||
System.TimeZone,
|
||||
System.MemoryManagerMode,
|
||||
CommandLineState.IgnoreMissingServices,
|
||||
Graphics.AspectRatio,
|
||||
System.AudioVolume,
|
||||
System.UseHypervisor,
|
||||
Multiplayer.LanInterfaceId,
|
||||
Multiplayer.Mode,
|
||||
Multiplayer.DisableP2p,
|
||||
Multiplayer.LdnPassphrase,
|
||||
Instance.Multiplayer.GetLdnServer(),
|
||||
Instance.Graphics.CustomVSyncInterval,
|
||||
Instance.Hacks.ShowDirtyHacks ? Instance.Hacks.EnabledHacks : null);
|
||||
#else
|
||||
new(
|
||||
System.DramSize,
|
||||
System.Language.Value.ToHLE(),
|
||||
System.Region.Value.ToHLE(),
|
||||
Graphics.VSyncMode,
|
||||
System.EnableDockedMode,
|
||||
System.EnablePtc,
|
||||
System.TickScalar,
|
||||
System.EnableInternetAccess,
|
||||
System.EnableFsIntegrityChecks
|
||||
? IntegrityCheckLevel.ErrorOnInvalid
|
||||
: IntegrityCheckLevel.None,
|
||||
System.FsGlobalAccessLogMode,
|
||||
System.MatchSystemTime
|
||||
? 0
|
||||
: System.SystemTimeOffset,
|
||||
System.TimeZone,
|
||||
System.MemoryManagerMode,
|
||||
Graphics.AspectRatio,
|
||||
System.AudioVolume,
|
||||
System.UseHypervisor,
|
||||
Multiplayer.LanInterfaceId,
|
||||
Multiplayer.Mode,
|
||||
Multiplayer.DisableP2p,
|
||||
Multiplayer.LdnPassphrase,
|
||||
Instance.Multiplayer.GetLdnServer(),
|
||||
Instance.Graphics.CustomVSyncInterval,
|
||||
Instance.Hacks.ShowDirtyHacks ? Instance.Hacks.EnabledHacks : null);
|
||||
#endif
|
||||
Multiplayer.GetLdnServer(),
|
||||
Graphics.CustomVSyncInterval,
|
||||
Hacks.ShowDirtyHacks ? Hacks.EnabledHacks : null);
|
||||
Graphics.AspectRatio,
|
||||
System.AudioVolume,
|
||||
System.UseHypervisor,
|
||||
Multiplayer.LanInterfaceId,
|
||||
Multiplayer.Mode,
|
||||
Multiplayer.DisableP2p,
|
||||
Multiplayer.LdnPassphrase,
|
||||
Instance.Multiplayer.GetLdnServer(),
|
||||
Instance.Graphics.CustomVSyncInterval,
|
||||
Instance.Hacks.ShowDirtyHacks ? Instance.Hacks.EnabledHacks : null);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user