diff --git a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/NativeLibrary.java b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/NativeLibrary.java index 63d40d5a91..8a024499af 100644 --- a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/NativeLibrary.java +++ b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/NativeLibrary.java @@ -302,7 +302,7 @@ public final class NativeLibrary public static native int DefaultCPUCore(); - public static native String GetDefaultGraphicsBackendName(); + public static native String GetDefaultGraphicsBackendConfigName(); public static native int GetMaxLogLevel(); diff --git a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.kt b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.kt index f959764564..b150c845e1 100644 --- a/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.kt +++ b/Source/Android/app/src/main/java/org/dolphinemu/dolphinemu/features/settings/model/StringSetting.kt @@ -45,7 +45,7 @@ enum class StringSetting( Settings.FILE_DOLPHIN, Settings.SECTION_INI_CORE, "GFXBackend", - NativeLibrary.GetDefaultGraphicsBackendName() + NativeLibrary.GetDefaultGraphicsBackendConfigName() ), MAIN_DUMP_PATH(Settings.FILE_DOLPHIN, Settings.SECTION_INI_GENERAL, "DumpPath", ""), MAIN_LOAD_PATH(Settings.FILE_DOLPHIN, Settings.SECTION_INI_GENERAL, "LoadPath", ""), diff --git a/Source/Android/jni/MainAndroid.cpp b/Source/Android/jni/MainAndroid.cpp index 40aada1195..bc6205e190 100644 --- a/Source/Android/jni/MainAndroid.cpp +++ b/Source/Android/jni/MainAndroid.cpp @@ -408,9 +408,10 @@ JNIEXPORT jint JNICALL Java_org_dolphinemu_dolphinemu_NativeLibrary_DefaultCPUCo } JNIEXPORT jstring JNICALL -Java_org_dolphinemu_dolphinemu_NativeLibrary_GetDefaultGraphicsBackendName(JNIEnv* env, jclass) +Java_org_dolphinemu_dolphinemu_NativeLibrary_GetDefaultGraphicsBackendConfigName(JNIEnv* env, + jclass) { - return ToJString(env, VideoBackendBase::GetDefaultBackendName()); + return ToJString(env, VideoBackendBase::GetDefaultBackendConfigName()); } JNIEXPORT jint JNICALL Java_org_dolphinemu_dolphinemu_NativeLibrary_GetMaxLogLevel(JNIEnv*, jclass) diff --git a/Source/Core/Core/Config/MainSettings.cpp b/Source/Core/Core/Config/MainSettings.cpp index 7f4e9989b7..c9cd0333a9 100644 --- a/Source/Core/Core/Config/MainSettings.cpp +++ b/Source/Core/Core/Config/MainSettings.cpp @@ -212,7 +212,7 @@ const Info MAIN_RAM_OVERRIDE_ENABLE{{System::Main, "Core", "RAMOverrideEna const Info MAIN_MEM1_SIZE{{System::Main, "Core", "MEM1Size"}, Memory::MEM1_SIZE_RETAIL}; const Info MAIN_MEM2_SIZE{{System::Main, "Core", "MEM2Size"}, Memory::MEM2_SIZE_RETAIL}; const Info MAIN_GFX_BACKEND{{System::Main, "Core", "GFXBackend"}, - VideoBackendBase::GetDefaultBackendName()}; + VideoBackendBase::GetDefaultBackendConfigName()}; const Info MAIN_HSP_DEVICE{{System::Main, "Core", "HSPDevice"}, HSP::HSPDeviceType::None}; const Info MAIN_ARAM_EXPANSION_SIZE{{System::Main, "Core", "ARAMExpansionSize"}, 0x400000}; diff --git a/Source/Core/DolphinQt/Config/Graphics/GeneralWidget.cpp b/Source/Core/DolphinQt/Config/Graphics/GeneralWidget.cpp index 3574e6893a..b5f5a6b05a 100644 --- a/Source/Core/DolphinQt/Config/Graphics/GeneralWidget.cpp +++ b/Source/Core/DolphinQt/Config/Graphics/GeneralWidget.cpp @@ -239,7 +239,7 @@ void GeneralWidget::AddDescriptions() "recommended. Different games and different GPUs will behave differently on each " "backend, so for the best emulation experience it is recommended to try each and " "select the backend that is least problematic.

If unsure, " - "select OpenGL."); + "select %1."); static const char TR_FULLSCREEN_DESCRIPTION[] = QT_TR_NOOP("Uses the entire screen for rendering.

If disabled, a " "render window will be created instead.

If " @@ -311,7 +311,9 @@ void GeneralWidget::AddDescriptions() "unsure, leave this unchecked."); m_backend_combo->SetTitle(tr("Backend")); - m_backend_combo->SetDescription(tr(TR_BACKEND_DESCRIPTION)); + m_backend_combo->SetDescription( + tr(TR_BACKEND_DESCRIPTION) + .arg(QString::fromStdString(VideoBackendBase::GetDefaultBackendDisplayName()))); m_adapter_combo->SetTitle(tr("Adapter")); diff --git a/Source/Core/VideoCommon/VideoBackendBase.cpp b/Source/Core/VideoCommon/VideoBackendBase.cpp index faf7ac19c6..e8f9f91b41 100644 --- a/Source/Core/VideoCommon/VideoBackendBase.cpp +++ b/Source/Core/VideoCommon/VideoBackendBase.cpp @@ -222,12 +222,18 @@ static VideoBackendBase* GetDefaultVideoBackend() return backends.front().get(); } -std::string VideoBackendBase::GetDefaultBackendName() +std::string VideoBackendBase::GetDefaultBackendConfigName() { auto* default_backend = GetDefaultVideoBackend(); return default_backend ? default_backend->GetName() : ""; } +std::string VideoBackendBase::GetDefaultBackendDisplayName() +{ + auto* const default_backend = GetDefaultVideoBackend(); + return default_backend ? default_backend->GetDisplayName() : ""; +} + const std::vector>& VideoBackendBase::GetAvailableBackends() { static auto s_available_backends = [] { diff --git a/Source/Core/VideoCommon/VideoBackendBase.h b/Source/Core/VideoCommon/VideoBackendBase.h index 5d9ab020d2..2ddfc284ca 100644 --- a/Source/Core/VideoCommon/VideoBackendBase.h +++ b/Source/Core/VideoCommon/VideoBackendBase.h @@ -64,7 +64,8 @@ public: u32 Video_GetQueryResult(PerfQueryType type); u16 Video_GetBoundingBox(int index); - static std::string GetDefaultBackendName(); + static std::string GetDefaultBackendConfigName(); + static std::string GetDefaultBackendDisplayName(); static const std::vector>& GetAvailableBackends(); static void ActivateBackend(const std::string& name);