mirror of
https://github.com/bloxstraplabs/bloxstrap.git
synced 2025-04-21 01:51:29 -07:00
Add option to force MSAA samples (#448)
This commit is contained in:
parent
bfe32ab679
commit
92aaa86d4f
@ -23,6 +23,7 @@ namespace Bloxstrap
|
|||||||
{ "Rendering.ManualFullscreen", "FFlagHandleAltEnterFullscreenManually" },
|
{ "Rendering.ManualFullscreen", "FFlagHandleAltEnterFullscreenManually" },
|
||||||
{ "Rendering.TexturePack", "FStringPartTexturePackTable2022" },
|
{ "Rendering.TexturePack", "FStringPartTexturePackTable2022" },
|
||||||
{ "Rendering.DisableScaling", "DFFlagDisableDPIScale" },
|
{ "Rendering.DisableScaling", "DFFlagDisableDPIScale" },
|
||||||
|
{ "Rendering.MSAA", "FIntDebugForceMSAASamples" },
|
||||||
|
|
||||||
{ "Rendering.Mode.D3D11", "FFlagDebugGraphicsPreferD3D11" },
|
{ "Rendering.Mode.D3D11", "FFlagDebugGraphicsPreferD3D11" },
|
||||||
{ "Rendering.Mode.D3D10", "FFlagDebugGraphicsPreferD3D11FL10" },
|
{ "Rendering.Mode.D3D10", "FFlagDebugGraphicsPreferD3D11FL10" },
|
||||||
@ -61,6 +62,15 @@ namespace Bloxstrap
|
|||||||
{ "Future (Phase 3)", "Future" }
|
{ "Future (Phase 3)", "Future" }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
public static IReadOnlyDictionary<string, string?> MSAAModes => new Dictionary<string, string?>
|
||||||
|
{
|
||||||
|
{ "Automatic", null },
|
||||||
|
{ "1x MSAA", "1" },
|
||||||
|
{ "2x MSAA", "2" },
|
||||||
|
{ "4x MSAA", "4" },
|
||||||
|
{ "8x MSAA", "8" }
|
||||||
|
};
|
||||||
|
|
||||||
// this is one hell of a dictionary definition lmao
|
// this is one hell of a dictionary definition lmao
|
||||||
// since these all set the same flags, wouldn't making this use bitwise operators be better?
|
// since these all set the same flags, wouldn't making this use bitwise operators be better?
|
||||||
public static IReadOnlyDictionary<string, Dictionary<string, string?>> IGMenuVersions => new Dictionary<string, Dictionary<string, string?>>
|
public static IReadOnlyDictionary<string, Dictionary<string, string?>> IGMenuVersions => new Dictionary<string, Dictionary<string, string?>>
|
||||||
@ -118,7 +128,7 @@ namespace Bloxstrap
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (Prop.ContainsKey(key))
|
if (Prop.ContainsKey(key))
|
||||||
App.Logger.WriteLine(LOG_IDENT, $"Setting of '{key}' from '{Prop[key]}' to '{value}' is pending");
|
App.Logger.WriteLine(LOG_IDENT, $"Changing of '{key}' from '{Prop[key]}' to '{value}' is pending");
|
||||||
else
|
else
|
||||||
App.Logger.WriteLine(LOG_IDENT, $"Setting of '{key}' to '{value}' is pending");
|
App.Logger.WriteLine(LOG_IDENT, $"Setting of '{key}' to '{value}' is pending");
|
||||||
|
|
||||||
|
@ -171,6 +171,15 @@
|
|||||||
</ui:CardControl.Header>
|
</ui:CardControl.Header>
|
||||||
<ComboBox Margin="5,0,0,0" Padding="10,5,10,5" Width="200" ItemsSource="{Binding RenderingModes.Keys, Mode=OneTime}" Text="{Binding SelectedRenderingMode, Mode=TwoWay}" />
|
<ComboBox Margin="5,0,0,0" Padding="10,5,10,5" Width="200" ItemsSource="{Binding RenderingModes.Keys, Mode=OneTime}" Text="{Binding SelectedRenderingMode, Mode=TwoWay}" />
|
||||||
</ui:CardControl>
|
</ui:CardControl>
|
||||||
|
<ui:CardControl Margin="0,8,0,0">
|
||||||
|
<ui:CardControl.Header>
|
||||||
|
<StackPanel>
|
||||||
|
<TextBlock FontSize="14" Text="Antialiasing quality" />
|
||||||
|
<TextBlock Margin="0,2,0,0" FontSize="12" Text="Forces the amount of MSAA samples that are taken." Foreground="{DynamicResource TextFillColorTertiaryBrush}" />
|
||||||
|
</StackPanel>
|
||||||
|
</ui:CardControl.Header>
|
||||||
|
<ComboBox Margin="5,0,0,0" Padding="10,5,10,5" Width="200" ItemsSource="{Binding MSAAModes.Keys, Mode=OneTime}" Text="{Binding SelectedMSAAMode, Mode=TwoWay}" />
|
||||||
|
</ui:CardControl>
|
||||||
<ui:CardControl Margin="0,8,0,0">
|
<ui:CardControl Margin="0,8,0,0">
|
||||||
<ui:CardControl.Header>
|
<ui:CardControl.Header>
|
||||||
<StackPanel>
|
<StackPanel>
|
||||||
|
@ -127,6 +127,14 @@ namespace Bloxstrap.UI.ViewModels.Menu
|
|||||||
set => App.FastFlags.SetPresetEnum("Rendering.Lighting", LightingModes[value], "True");
|
set => App.FastFlags.SetPresetEnum("Rendering.Lighting", LightingModes[value], "True");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public IReadOnlyDictionary<string, string?> MSAAModes => FastFlagManager.MSAAModes;
|
||||||
|
|
||||||
|
public string SelectedMSAAMode
|
||||||
|
{
|
||||||
|
get => MSAAModes.First(x => x.Value == App.FastFlags.GetPreset("Rendering.MSAA")).Key ?? MSAAModes.First().Key;
|
||||||
|
set => App.FastFlags.SetPreset("Rendering.MSAA", MSAAModes[value]);
|
||||||
|
}
|
||||||
|
|
||||||
public bool GuiHidingEnabled
|
public bool GuiHidingEnabled
|
||||||
{
|
{
|
||||||
get => App.FastFlags.GetPreset("UI.Hide") == "32380007";
|
get => App.FastFlags.GetPreset("UI.Hide") == "32380007";
|
||||||
|
Loading…
Reference in New Issue
Block a user