1
0
mirror of https://github.com/ppy/osu.git synced 2026-05-26 10:49:57 +08:00
Files
osu-lazer/osu.Game/Configuration/MigrateNewAudioDialog.cs
T
Dean Herbert 941a4d8994 Make experimental audio the new default (#37856)
Internal offset adjust is based on [survey
results](https://docs.google.com/forms/d/1bWdwN9LPB4dJsqh2NO4z0HBiMiod1k8-tJN5oca-1Iw/edit)
results (mean: 17.95, median: 24.5) with slight skewing based on
cherry-picking results and personal experiences.

For users which have had the setting disabled:

<img width="1380" height="774" alt="osu! 2026-05-21 at 09 19 06"
src="https://github.com/user-attachments/assets/0526517a-fa0b-485b-ac1b-b61b2fccd2af"
/>

For users which are already using it:

<img width="1380" height="774" alt="osu! 2026-05-21 at 09 20 24"
src="https://github.com/user-attachments/assets/1bd77b39-5d75-43e8-8fe1-b324064b25fa"
/>

Note the button is intentionally hidden to avoid any confusion (it's
inverse now, so some users may mistakenly click it). Assume if a user is
already on the new engine, they are happy with it.

Test migration dialog in startup game flow using:

```diff
diff --git a/osu.Game/OsuGame.cs b/osu.Game/OsuGame.cs
index 4bd5ab83a3..091af6d428 100644
--- a/osu.Game/OsuGame.cs
+++ b/osu.Game/OsuGame.cs
@@ -1315,6 +1315,8 @@ protected override void LoadComplete()
         /// </remarks>
         private void applyConfigMigrations()
         {
+            dialogOverlay.Push(new MigrateNewAudioDialog(true));
+
             // arrives as 2020.123.0-lazer
             string rawVersion = LocalConfig.Get<string>(OsuSetting.Version);
 

```

---------

Co-authored-by: Bartłomiej Dach <dach.bartlomiej@gmail.com>
2026-05-22 08:00:50 +02:00

70 lines
2.7 KiB
C#

// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Sprites;
using osu.Game.Localisation;
using osu.Game.Overlays;
using osu.Game.Overlays.Dialog;
using osu.Game.Overlays.Settings.Sections.Audio;
namespace osu.Game.Configuration
{
public partial class MigrateNewAudioDialog : PopupDialog
{
[Cached]
private OverlayColourProvider colourProvider = new OverlayColourProvider(OverlayColourScheme.Purple);
public MigrateNewAudioDialog(bool wasAlreadyUsing)
{
Icon = FontAwesome.Regular.Bell;
if (wasAlreadyUsing)
{
HeaderText = @"New audio engine is now default!";
BodyText =
$"""
We recently added a new "Experimental Audio" backend for Windows users to reduce hitsound latency. Due to overwhelmingly positive feedback, this is now the default mode.
As you were already using this engine, your audio offset has been adjusted to account for an internal offset change (no intervention required).
If you have any issues, you can switch back to the legacy engine from settings via the "{AudioSettingsStrings.LegacyAudioLabel}" checkbox.
""";
}
else
{
HeaderText = @"New audio engine has been enabled";
BodyText =
$"""
We recently added a new "Experimental Audio" backend for Windows users to reduce hitsound latency. Due to overwhelmingly positive feedback, this is now the default mode.
If you have any issues, you can switch back to the legacy engine below, or at any time in settings via the "{AudioSettingsStrings.LegacyAudioLabel}" checkbox.
""";
MainContent.Add(new Container
{
Margin = new MarginPadding { Top = 20 },
Anchor = Anchor.Centre,
Origin = Anchor.Centre,
Width = 400,
AutoSizeAxes = Axes.Y,
Children = new Drawable[]
{
new LegacyAudioCheckbox(),
}
});
}
Buttons = new PopupDialogButton[]
{
new PopupDialogOkButton
{
Text = BeatmapOverlayStrings.UserContentConfirmButtonText,
},
};
}
}
}