mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2025-07-20 08:15:46 +00:00
[Settings]: Implement force_gpu_blit toggle
Also disables skip_cpu_inner_invalidation by default
This commit is contained in:
parent
fe3b12c64e
commit
6a0ad63453
7 changed files with 32 additions and 3 deletions
|
@ -17,6 +17,7 @@ enum class BooleanSetting(override val key: String) : AbstractBooleanSetting {
|
|||
RENDERER_USE_SPEED_LIMIT("use_speed_limit"),
|
||||
USE_FAST_CPU_TIME("use_fast_cpu_time"),
|
||||
USE_CUSTOM_CPU_TICKS("use_custom_cpu_ticks"),
|
||||
FORCE_GPU_BLIT("force_gpu_blit"),
|
||||
SKIP_CPU_INNER_INVALIDATION("skip_cpu_inner_invalidation"),
|
||||
USE_DOCKED_MODE("use_docked_mode"),
|
||||
USE_AUTO_STUB("use_auto_stub"),
|
||||
|
|
|
@ -655,6 +655,13 @@ abstract class SettingsItem(
|
|||
max = 65535
|
||||
)
|
||||
)
|
||||
put(
|
||||
SwitchSetting(
|
||||
BooleanSetting.FORCE_GPU_BLIT,
|
||||
titleId = R.string.force_gpu_blit,
|
||||
descriptionId = R.string.force_gpu_blit_description
|
||||
)
|
||||
)
|
||||
put(
|
||||
SwitchSetting(
|
||||
BooleanSetting.SKIP_CPU_INNER_INVALIDATION,
|
||||
|
|
|
@ -463,6 +463,7 @@ class SettingsFragmentPresenter(
|
|||
add(IntSetting.FAST_CPU_TIME.key)
|
||||
add(BooleanSetting.USE_CUSTOM_CPU_TICKS.key)
|
||||
add(IntSetting.CPU_TICKS.key)
|
||||
add(BooleanSetting.FORCE_GPU_BLIT.key)
|
||||
add(BooleanSetting.SKIP_CPU_INNER_INVALIDATION.key)
|
||||
add(BooleanSetting.USE_LRU_CACHE.key)
|
||||
add(BooleanSetting.CORE_SYNC_CORE_SPEED.key)
|
||||
|
|
|
@ -105,6 +105,8 @@
|
|||
<string name="custom_cpu_ticks">Custom CPU Ticks</string>
|
||||
<string name="custom_cpu_ticks_description">Set a custom value of CPU ticks. Higher values can increase performance, but may also cause the game to freeze. A range of 77–21000 is recommended.</string>
|
||||
<string name="cpu_ticks">Ticks</string>
|
||||
<string name="force_gpu_blit">Force GPU Blit</string>
|
||||
<string name="force_gpu_blit_description">Forces all surface copy operations to use GPU acceleration. If your system fails to perform a hardware-accelerated copy, the operation will be skipped and software fallback will not be used. This may significantly improve the performance, but may cause rendering issues on some games.</string>
|
||||
<string name="skip_cpu_inner_invalidation">Skip CPU Inner Invalidation</string>
|
||||
<string name="skip_cpu_inner_invalidation_description">Skips certain CPU-side cache invalidations during memory updates, reducing CPU usage and improving it\'s performance. This may cause glitches or crashes on some games.</string>
|
||||
<string name="fast_cpu_time">CPU Clock</string>
|
||||
|
|
|
@ -450,8 +450,15 @@ struct Values {
|
|||
VramUsageMode::Aggressive,
|
||||
"vram_usage_mode",
|
||||
Category::RendererAdvanced};
|
||||
SwitchableSetting<bool> skip_cpu_inner_invalidation{linkage,
|
||||
SwitchableSetting<bool> force_gpu_blit{linkage,
|
||||
false,
|
||||
"force_gpu_blit",
|
||||
Category::RendererAdvanced,
|
||||
Specialization::Default,
|
||||
true,
|
||||
true};
|
||||
SwitchableSetting<bool> skip_cpu_inner_invalidation{linkage,
|
||||
false,
|
||||
"skip_cpu_inner_invalidation",
|
||||
Category::RendererAdvanced,
|
||||
Specialization::Default,
|
||||
|
|
|
@ -114,9 +114,14 @@ void Fermi2D::Blit() {
|
|||
}
|
||||
|
||||
memory_manager.FlushCaching();
|
||||
/*if (!rasterizer->AccelerateSurfaceCopy(src, regs.dst, config)) {
|
||||
|
||||
if (!rasterizer->AccelerateSurfaceCopy(src, regs.dst, config)) {
|
||||
if (Settings::values.force_gpu_blit.GetValue()) {
|
||||
LOG_ERROR(HW_GPU, "AccelerateSurfaceCopy failed, and gpu blit is forced.");
|
||||
return;
|
||||
}
|
||||
sw_blitter->Blit(src, regs.dst, config);
|
||||
}*/
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace Tegra::Engines
|
||||
|
|
|
@ -250,6 +250,12 @@ std::unique_ptr<TranslationMap> InitializeTranslations(QWidget* parent)
|
|||
"of available video memory for performance. Has no effect on integrated graphics. "
|
||||
"Aggressive mode may severely impact the performance of other applications such as "
|
||||
"recording software."));
|
||||
INSERT(Settings,
|
||||
force_gpu_blit,
|
||||
tr("Force GPU Blit"),
|
||||
tr("Forces all surface copy operations to use GPU acceleration. If your system fails to "
|
||||
"perform a hardware-accelerated copy, the operation will be skipped and software fallback will not be used. "
|
||||
"This may significantly improve the performance, but may cause rendering issues on some games."));
|
||||
INSERT(Settings,
|
||||
skip_cpu_inner_invalidation,
|
||||
tr("Skip CPU Inner Invalidation"),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue