Add graphics presets, eu07.ini import/export and the new simulator settings

This commit is contained in:
2026-10-27 10:44:48 +01:00
parent 2befefb547
commit 8d6b4805c8
20 changed files with 2034 additions and 410 deletions

View File

@@ -7,6 +7,12 @@ public enum ConsistReadyOverride { Scenery = 0, AlwaysCold = 1, AlwaysReady = 2
public enum ExeProblem { None, NotFound, NotExecutable, WrongPlatform }
// gfxrenderer: the opengl 4.6 renderer ("full", which the simulator reads as "default") or the vulkan 1.4 one.
public enum GraphicsBackend { OpenGL = 0, Vulkan = 1 }
// gfx.antialiasing. Dlss and Dlaa are the vulkan renderer's only; the simulator falls back to taa elsewhere.
public enum AntiAliasingMode { Off, Msaa2, Msaa4, Msaa8, Taa, Dlss, Dlaa }
public sealed class SimulatorSettings
{
public bool LanguageWasSet { get; internal set; }
@@ -37,14 +43,18 @@ public sealed class SimulatorSettings
public bool LogMissingVehicleFiles;
public bool DeveloperTools;
public int RenderEngine;
public GraphicsBackend Backend = GraphicsBackend.OpenGL;
public string VulkanDevice = "";
public int Width = 1280;
public int Height = 720;
public int BufferScalePercent = 100;
public int MaxTextureSize = 4096;
public int MaxCabTextureSize = 4096;
public int TextureFiltering = 8;
public int Multisampling = 2;
public AntiAliasingMode AntiAliasing = AntiAliasingMode.Msaa4;
public string DlssPreset = "default";
public int FrameGeneration = 1;
public int Reflex;
public int DynamicLights = 7;
public double DrawRangeFactor = 3.0;
public bool VSync;
@@ -54,8 +64,27 @@ public sealed class SimulatorSettings
public bool MotionBlur = true;
public bool ExtraEffects = true;
public bool EnvMap = true;
public bool UseVbo = true;
public bool RenderShadows = true;
public bool ShadowSdsm;
public int LightShadows = 2;
public int ContactShadows;
public bool LightsClustered = true;
public int AmbientOcclusion = 2;
public int AoSlices = 3;
public int AoSteps = 4;
public int Ssr = 2;
public bool RayTracing;
public int RayTracingRange = 500;
public bool VolumetricFog = true;
public int FogQuality = 2;
public int Clouds = 2;
public bool CloudShadows = true;
public bool Grass = true;
public int GrassDistance = 60;
public double GrassDensity = 1.0;
public int PrecipitationParticles = 65536;
public bool Bloom = true;
public bool AutoExposure = true;
public int ReflectionsFramerate = 60;
public int ShadowMapResolution = 2048;
public int ShadowProjectionRange = 250;
@@ -69,7 +98,6 @@ public sealed class SimulatorSettings
public int FpsLimit = 30;
public double ShadowAngleLimit = 0.2;
public bool FullscreenWindowed;
public bool RenderAngleVulkan;
public int SplineFidelity = 1;
public bool FullPhysics = true;
@@ -97,7 +125,6 @@ public sealed class SimulatorSettings
public bool CompressTextures = true;
public bool ScaleSpeculars = true;
public bool UseGLES;
public bool ShaderGamma;
public bool ScreenMipmaps = true;
public bool ExtendedModelConversion;
@@ -120,8 +147,8 @@ public sealed class SimulatorSettings
public bool WindowMaximized;
public static readonly string[] RenderEngines =
{ "full", "legacy", "simpleshader", "simple", "off", "experimental" };
// "full" rather than "default": every simulator build reads it, the new ones as the opengl 4.6 renderer.
public static readonly string[] RenderEngines = { "full", "vulkan" };
public static readonly int[] AnisotropySteps = { 1, 2, 4, 8, 16 };