using System.Collections.Generic; using AcDream.UI.Abstractions.Settings; namespace AcDream.UI.Abstractions.Panels.Settings; /// /// Display-related preferences persisted to settings.json. /// Modern addition (no retail equivalent for FOV / vsync etc) — replaces /// the various ACDREAM_* environment variables for resolution + /// windowed mode with an in-game UI. /// /// /// Records are immutable; mutation goes through /// which assigns a new instance via /// with-expressions. /// /// public sealed record DisplaySettings( string Resolution, bool Fullscreen, bool VSync, float FieldOfView, float Gamma, bool ShowFps, QualityPreset Quality) { /// Values used on first launch / when settings.json is absent. /// Geometry/render defaults preserve the pre-L.0 runtime state — Resolution /// matches the WindowOptions startup size (1280×720), FieldOfView /// matches camera FovY (60°), VSync matches WindowOptions (false), /// ShowFps matches retail's initially-hidden SmartBox FPS readout. public static DisplaySettings Default { get; } = new( Resolution: "1280x720", Fullscreen: false, VSync: false, FieldOfView: 60f, Gamma: 1.0f, ShowFps: false, Quality: QualityPreset.High); /// 16:9 resolution presets offered in the dropdown. public static IReadOnlyList AvailableResolutions { get; } = new[] { "1280x720", "1366x768", "1600x900", "1920x1080", "2560x1440", "3840x2160", }; }