Compare commits

..

No commits in common. "b1518282283c8ff9456b97977787be4b8a97c772" and "421158d75f792922aed05bb05af2128e27490c88" have entirely different histories.

16 changed files with 209 additions and 51 deletions

View file

@ -5998,12 +5998,87 @@
}
},
{
"ID": "DisableFixOcclusionCulling",
"ID": "SettingsTabTweaks",
"Translations": {
"ar_SA": "باتشات",
"de_DE": "Tweaks",
"el_GR": "Patches",
"en_US": "Tweaks",
"es_ES": "Parches",
"fr_FR": "Patches",
"he_IL": "פאצ'ים",
"it_IT": "Tweaks",
"ja_JP": "パッチ",
"ko_KR": "패치",
"no_NO": "Patcher",
"pl_PL": "Tweak'i",
"pt_BR": "Patches",
"ru_RU": "Твики",
"sv_SE": "Patcher",
"th_TH": "แพตช์",
"tr_TR": "Tweaks",
"uk_UA": "Твіки",
"zh_CN": "补丁",
"zh_TW": "補丁"
}
},
{
"ID": "SettingsTabTweaksTitle",
"Translations": {
"ar_SA": "باتشات: تجارب وتحديثات",
"de_DE": "Tweaks: Experimente & Patches",
"el_GR": "Patches: Πειράματα & Διορθώσεις",
"en_US": "Tweaks: Experiments & Patches",
"es_ES": "Parches: Experimentos y Ajustes",
"fr_FR": "Patches : Expériences et Corrections",
"he_IL": "פאצ'ים: ניסויים ותיקונים",
"it_IT": "Tweaks: Esperimenti e Patch",
"ja_JP": "パッチ: 実験と修正",
"ko_KR": "패치: 실험 및 수정",
"no_NO": "Patcher: Eksperimenter og Utbedringer",
"pl_PL": "Tweak'i: Eksperymenty i Łatki",
"pt_BR": "Patches: Experimentos e Correções",
"ru_RU": "Твики: Эксперименты и Патчи",
"sv_SE": "Patcher: Experiment och Korrigeringar",
"th_TH": "แพตช์: การทดลองและการแก้ไข",
"tr_TR": "Tweaks: Deneyler ve Yamalar",
"uk_UA": "Твіки: Експерименти та Патчі",
"zh_CN": "补丁:实验与修复",
"zh_TW": "補丁:實驗與修復"
}
},
{
"ID": "SettingsTabTweaksDescription",
"Translations": {
"ar_SA": "تحذير! يجب تغيير هذه الخيارات فقط إذا كانت لعبتك لا تعمل بشكل صحيح.",
"de_DE": "Warnung! Diese Optionen sollten nur geändert werden, wenn dein Spiel nicht ordnungsgemäß funktioniert.",
"el_GR": "Προειδοποίηση! Αυτές οι ρυθμίσεις πρέπει να αλλάξουν μόνο αν το παιχνίδι σας δεν λειτουργεί σωστά.",
"en_US": "Warning! These options should only be changed if your game is not working properly.",
"es_ES": "Advertencia! Estas opciones deben cambiarse solo si tu juego no funciona correctamente.",
"fr_FR": "Avertissement! Ces options doivent être modifiées uniquement si votre jeu ne fonctionne pas correctement.",
"he_IL": "אזהרה! יש לשנות את האפשרויות הללו רק אם המשחק שלך לא פועל כראוי.",
"it_IT": "Avviso! Queste opzioni devono essere modificate solo se il tuo gioco non funziona correttamente.",
"ja_JP": "警告! ゲームが正常に動作しない場合にのみ、これらのオプションを変更してください。",
"ko_KR": "경고! 게임이 제대로 작동하지 않으면 이 옵션들을 변경해야 합니다.",
"no_NO": "Advarsel! Disse alternativene bør kun endres hvis spillet ditt ikke fungerer som det skal.",
"pl_PL": "Ostrzeżenie! Te opcje należy zmienić tylko wtedy, gdy twoja gra nie działa poprawnie.",
"pt_BR": "Aviso! Essas opções devem ser alteradas apenas se o seu jogo não estiver funcionando corretamente.",
"ru_RU": "Предупреждение! Эти параметры следует изменить только в случае, если ваша игра работает неправильно.",
"sv_SE": "Varning! Dessa alternativ bör endast ändras om ditt spel inte fungerar som det ska.",
"th_TH": "คำเตือน! ควรเปลี่ยนตัวเลือกเหล่านี้เฉพาะในกรณีที่เกมของคุณทำงานไม่ถูกต้อง.",
"tr_TR": "Uyarı! Bu seçenekler, oyununuz düzgün çalışmıyorsa yalnızca değiştirilmelidir.",
"uk_UA": "Попередження! Ці налаштування слід змінити лише в тому випадку, якщо ваша гра не працює належним чином.",
"zh_CN": "警告! 只有在游戏无法正常运行的情况下,请更改这些选项。",
"zh_TW": "警告! 只有當遊戲無法正常運行時,請更改這些選項。"
}
},
{
"ID": "FixOcclusionCulling",
"Translations": {
"ar_SA": "",
"de_DE": "",
"el_GR": "",
"en_US": "Disable Occlusion Culling Fix - flickering of objects.",
"en_US": "Fix Occlusion Culling - flickering of objects.",
"es_ES": "",
"fr_FR": "",
"he_IL": "",
@ -6023,7 +6098,7 @@
}
},
{
"ID": "DisableFixOcclusionCullingTooltip",
"ID": "FixOcclusionCullingTooltip",
"Translations": {
"ar_SA": "",
"de_DE": "",

View file

@ -165,7 +165,7 @@ namespace Ryujinx.Graphics.Gpu.Engine.Threed
Timestamp = ticks,
};
if (!GraphicsConfig.DisableFixOcclusionCulling && result <= 0)
if (GraphicsConfig.FixOcclusionCulling && result <= 0)
{
return;
}

View file

@ -76,7 +76,7 @@ namespace Ryujinx.Graphics.Gpu
/// <summary>
/// Enables or disables fix occlusion culling.
/// </summary>
public static bool DisableFixOcclusionCulling = true;
public static bool FixOcclusionCulling = true;
}
#pragma warning restore CA2211
}

View file

@ -472,7 +472,7 @@ namespace Ryujinx.Ava.Systems.Configuration
/// <summary>
/// Fixes Occlusion Culling in Games (test feature)
/// </summary>
public bool DisableFixOcclusionCulling { get; set; }
public bool FixOcclusionCulling { get; set; }
/// <summary>
/// Loads a configuration file from disk

View file

@ -156,7 +156,7 @@ namespace Ryujinx.Ava.Systems.Configuration
Multiplayer.LdnPassphrase.Value = cff.MultiplayerLdnPassphrase;
Multiplayer.LdnServer.Value = cff.LdnServer;
Tweaks.DisableFixOcclusionCulling.Value = cff.DisableFixOcclusionCulling;
Tweaks.FixOcclusionCulling.Value = cff.FixOcclusionCulling;
{
Hacks.ShowDirtyHacks.Value = cff.ShowDirtyHacks;
@ -464,7 +464,7 @@ namespace Ryujinx.Ava.Systems.Configuration
};
}),
(69, static cff => cff.SkipUserProfiles = false),
(70, static cff => cff.DisableFixOcclusionCulling = false)
(70, static cff => cff.FixOcclusionCulling = false)
);
}
}

View file

@ -651,10 +651,10 @@ namespace Ryujinx.Ava.Systems.Configuration
/// <summary>
/// Enable or disable Fix Occlusion Culling
/// </summary>
public ReactiveObject<bool> DisableFixOcclusionCulling { get; private set; }
public ReactiveObject<bool> FixOcclusionCulling { get; private set; }
public TweaksSection()
{
DisableFixOcclusionCulling = new ReactiveObject<bool>();
FixOcclusionCulling = new ReactiveObject<bool>();
}
}

View file

@ -147,7 +147,7 @@ namespace Ryujinx.Ava.Systems.Configuration
LdnServer = Multiplayer.LdnServer,
ShowDirtyHacks = Hacks.ShowDirtyHacks,
DirtyHacks = Hacks.EnabledHacks.Select(it => it.Pack()).ToArray(),
DisableFixOcclusionCulling = Tweaks.DisableFixOcclusionCulling,
FixOcclusionCulling = Tweaks.FixOcclusionCulling,
};
return configurationFile;
@ -321,7 +321,7 @@ namespace Ryujinx.Ava.Systems.Configuration
},
}
];
Tweaks.DisableFixOcclusionCulling.Value = true;
Tweaks.FixOcclusionCulling.Value = true;
}
private static GraphicsBackend DefaultGraphicsBackend()

View file

@ -383,7 +383,7 @@ namespace Ryujinx.Ava.UI.ViewModels
}
}
public bool DisableFixOcclusionCulling { get; set; }
public bool FixOcclusionCulling { get; set; }
public SettingsViewModel(
VirtualFileSystem virtualFileSystem,
@ -663,7 +663,7 @@ namespace Ryujinx.Ava.UI.ViewModels
LdnServer = config.Multiplayer.LdnServer;
// Tweaks
DisableFixOcclusionCulling = config.Tweaks.DisableFixOcclusionCulling.Value;
FixOcclusionCulling = config.Tweaks.FixOcclusionCulling.Value;
}
public void SaveSettings()
@ -791,7 +791,7 @@ namespace Ryujinx.Ava.UI.ViewModels
DirtyHacks.NifmDisableIsAnyInternetRequestAccepted;
// Tweaks
config.Tweaks.DisableFixOcclusionCulling.Value = DisableFixOcclusionCulling;
config.Tweaks.FixOcclusionCulling.Value = FixOcclusionCulling;
config.ToFileFormat().SaveConfig(Program.ConfigurationPath);

View file

@ -4,25 +4,12 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:ext="clr-namespace:Ryujinx.Ava.Common.Markup"
xmlns:viewModels="clr-namespace:Ryujinx.Ava.UI.ViewModels"
mc:Ignorable="d"
x:DataType="viewModels:SettingsViewModel">
<Design.DataContext>
<viewModels:SettingsViewModel />
</Design.DataContext>
<UserControl.Styles>
<Style Selector="TextBlock.DefaultEnable" >
<Setter Property="Foreground" Value="SeaGreen"/>
<Setter Property="Margin" Value="5,0,0,0"/>
<Setter Property="VerticalAlignment" Value="Center"/>
</Style>
<Style Selector="TextBlock.DefaultDisable" >
<Setter Property="Foreground" Value="IndianRed"/>
<Setter Property="Margin" Value="5,0,0,0"/>
<Setter Property="VerticalAlignment" Value="Center"/>
</Style>
</UserControl.Styles>
<ScrollViewer
Name="HacksPage"
HorizontalAlignment="Stretch"
@ -32,6 +19,7 @@
<Border Classes="settings">
<StackPanel
Margin="10"
HorizontalAlignment="Center"
Orientation="Vertical"
Spacing="5">
<TextBlock
@ -39,32 +27,34 @@
Classes="h1"
Text="Dirty Hacks" />
<TextBlock
HorizontalAlignment="Center"
Foreground="{DynamicResource SecondaryTextColor}"
TextDecorations="Underline"
Text="Highly specific hacks &amp; tricks to alleviate performance issues, crashing, or freezing. Can cause issues." />
<Separator/>
<CheckBox IsChecked="{Binding DirtyHacks.Xc2MenuSoftlockFix}"
ToolTip.Tip="{Binding DirtyHacks.Xc2MenuFixTooltip}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="Xenoblade Chronicles 2 Menu Softlock Fix" />
<TextBlock Classes="DefaultDisable" Text="Default: disable" />
</StackPanel>
</CheckBox>
<CheckBox IsChecked="{Binding DirtyHacks.NifmDisableIsAnyInternetRequestAccepted}"
<StackPanel
Margin="0,10,0,0"
Orientation="Horizontal"
HorizontalAlignment="Center"
ToolTip.Tip="{Binding DirtyHacks.Xc2MenuFixTooltip}">
<CheckBox
Margin="0"
IsChecked="{Binding DirtyHacks.Xc2MenuSoftlockFix}"/>
<TextBlock
VerticalAlignment="Center"
Text="Xenoblade Chronicles 2 Menu Softlock Fix" />
</StackPanel>
<Separator/>
<StackPanel
Margin="0,10,0,0"
Orientation="Horizontal"
HorizontalAlignment="Center"
ToolTip.Tip="{Binding DirtyHacks.NifmDisableIsAnyInternetRequestAcceptedTooltip}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="Disable IsAnyInternetRequestAccepted" />
<TextBlock Classes="DefaultDisable" Text="Default: disable" />
</StackPanel>
</CheckBox>
<CheckBox IsChecked="{Binding DisableFixOcclusionCulling}"
ToolTip.Tip="{ext:Locale DisableFixOcclusionCullingTooltip}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="{ext:Locale DisableFixOcclusionCulling}" />
<TextBlock Classes="DefaultDisable" Text="Default: disable" />
</StackPanel>
</CheckBox>
<CheckBox
Margin="0"
IsChecked="{Binding DirtyHacks.NifmDisableIsAnyInternetRequestAccepted}"/>
<TextBlock
VerticalAlignment="Center"
Text="Disable IsAnyInternetRequestAccepted" />
</StackPanel>
</StackPanel>
</Border>
</ScrollViewer>

View file

@ -0,0 +1,65 @@
<UserControl
x:Class="Ryujinx.Ava.UI.Views.Settings.SettingsTweaksView"
xmlns="https://github.com/avaloniaui"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:ext="clr-namespace:Ryujinx.Ava.Common.Markup"
xmlns:viewModels="clr-namespace:Ryujinx.Ava.UI.ViewModels"
xmlns:helpers="clr-namespace:Ryujinx.Ava.UI.Helpers"
mc:Ignorable="d"
x:DataType="viewModels:SettingsViewModel"
x:CompileBindings="True"
Focusable="True">
<Design.DataContext>
<viewModels:SettingsViewModel />
</Design.DataContext>
<UserControl.Styles>
<Style Selector="TextBlock.DefaultEnable" >
<Setter Property="Foreground" Value="SeaGreen"/>
<Setter Property="Margin" Value="5,0,0,0"/>
<Setter Property="VerticalAlignment" Value="Center"/>
</Style>
<Style Selector="TextBlock.DefaultDisable" >
<Setter Property="Foreground" Value="IndianRed"/>
<Setter Property="Margin" Value="5,0,0,0"/>
<Setter Property="VerticalAlignment" Value="Center"/>
</Style>
</UserControl.Styles>
<ScrollViewer
Name="HotkeysPage"
HorizontalAlignment="Stretch"
VerticalAlignment="Stretch"
HorizontalScrollBarVisibility="Disabled"
VerticalScrollBarVisibility="Auto">
<Border Classes="settings">
<StackPanel
Name="SettingButtons"
Margin="10"
Orientation="Vertical"
Spacing="10">
<TextBlock
HorizontalAlignment="Center"
Classes="h1"
Text="{ext:Locale SettingsTabTweaksTitle}" />
<TextBlock
HorizontalAlignment="Center"
Foreground="{DynamicResource SecondaryTextColor}"
TextDecorations="Underline"
Text="{ext:Locale SettingsTabTweaksDescription}" />
<Separator/>
<StackPanel Orientation="Vertical">
<CheckBox IsChecked="{Binding FixOcclusionCulling}"
ToolTip.Tip="{ext:Locale FixOcclusionCullingTooltip}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="{ext:Locale FixOcclusionCulling}" />
<TextBlock Classes="DefaultEnable" Text="Default: enable" />
</StackPanel>
</CheckBox>
</StackPanel>
</StackPanel>
</Border>
</ScrollViewer>
</UserControl>

View file

@ -0,0 +1,12 @@
using Avalonia.Controls;
namespace Ryujinx.Ava.UI.Views.Settings
{
public partial class SettingsTweaksView : UserControl
{
public SettingsTweaksView()
{
InitializeComponent();
}
}
}

View file

@ -34,6 +34,7 @@
<settings:SettingsSystemView Name="SystemPage" />
<settings:SettingsCPUView Name="CpuPage" />
<settings:SettingsGraphicsView Name="GraphicsPage" />
<settings:SettingsTweaksView Name="TweaksPage" />
<settings:SettingsAudioView Name="AudioPage" />
<settings:SettingsNetworkView Name="NetworkPage" />
<settings:SettingsLoggingView Name="LoggingPage" />
@ -101,6 +102,10 @@
Content="{ext:Locale SettingsTabGraphics}"
Tag="GraphicsPage"
IconSource="Image" />
<ui:NavigationViewItem
Content="{ext:Locale SettingsTabTweaks}"
Tag="TweaksPage"
IconSource="Repair" />
<ui:NavigationViewItem
Content="{ext:Locale SettingsTabAudio}"
IconSource="Audio"

View file

@ -70,6 +70,9 @@ namespace Ryujinx.Ava.UI.Windows
case nameof(GraphicsPage):
NavPanel.Content = GraphicsPage;
break;
case nameof(TweaksPage):
NavPanel.Content = TweaksPage;
break;
case nameof(AudioPage):
NavPanel.Content = AudioPage;
break;

View file

@ -569,7 +569,7 @@ namespace Ryujinx.Ava.UI.Windows
GraphicsConfig.EnableShaderCache = ConfigurationState.Instance.Graphics.EnableShaderCache;
GraphicsConfig.EnableTextureRecompression = ConfigurationState.Instance.Graphics.EnableTextureRecompression;
GraphicsConfig.EnableMacroHLE = ConfigurationState.Instance.Graphics.EnableMacroHLE;
GraphicsConfig.DisableFixOcclusionCulling = ConfigurationState.Instance.Tweaks.DisableFixOcclusionCulling;
GraphicsConfig.FixOcclusionCulling = ConfigurationState.Instance.Tweaks.FixOcclusionCulling;
#pragma warning restore IDE0055
}

View file

@ -43,6 +43,7 @@
<settings:SettingsSystemView Name="SystemPage" />
<settings:SettingsCPUView Name="CpuPage" />
<settings:SettingsGraphicsView Name="GraphicsPage" />
<settings:SettingsTweaksView Name="TweaksPage" />
<settings:SettingsAudioView Name="AudioPage" />
<settings:SettingsNetworkView Name="NetworkPage" />
<settings:SettingsLoggingView Name="LoggingPage" />
@ -88,6 +89,10 @@
Content="{ext:Locale SettingsTabGraphics}"
Tag="GraphicsPage"
IconSource="Image" />
<ui:NavigationViewItem
Content="{ext:Locale SettingsTabTweaks}"
Tag="TweaksPage"
IconSource="Repair" />
<ui:NavigationViewItem
Content="{ext:Locale SettingsTabAudio}"
IconSource="Audio"

View file

@ -88,6 +88,9 @@ namespace Ryujinx.Ava.UI.Windows
case "GraphicsPage":
NavPanel.Content = GraphicsPage;
break;
case "TweaksPage":
NavPanel.Content = TweaksPage;
break;
case "AudioPage":
NavPanel.Content = AudioPage;
break;