From e86c7e501e067f094283d6fd4a6549a94d45dbd4 Mon Sep 17 00:00:00 2001 From: Richard Stanway Date: Tue, 14 Apr 2026 03:04:04 +0200 Subject: [PATCH] frontend: Abort if obs-transitions failed to load The frontend UI assumes transitions are always available and crashes if none are present. Resolving the crashes resulted in a completely broken UI, so it's safe to assume that transitions are a core requirement for a working OBS. Crash reports indicate that obs-transitions is failing to load for some users, so we should handle the case where no transitions load and abort with an error instead of crashing. --- frontend/widgets/OBSBasic.hpp | 4 ++-- frontend/widgets/OBSBasic_Transitions.cpp | 8 ++++++++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/frontend/widgets/OBSBasic.hpp b/frontend/widgets/OBSBasic.hpp index 90460d2ab..e66747e55 100644 --- a/frontend/widgets/OBSBasic.hpp +++ b/frontend/widgets/OBSBasic.hpp @@ -1500,8 +1500,8 @@ private: std::unordered_map transitionNameToUuids; int transitionDuration; std::string currentTransitionUuid; - obs_source_t *fadeTransition; - obs_source_t *cutTransition; + obs_source_t *fadeTransition = nullptr; + obs_source_t *cutTransition = nullptr; std::vector quickTransitions; bool swapScenesMode = true; diff --git a/frontend/widgets/OBSBasic_Transitions.cpp b/frontend/widgets/OBSBasic_Transitions.cpp index 486dd2d8a..bd34efb7f 100644 --- a/frontend/widgets/OBSBasic_Transitions.cpp +++ b/frontend/widgets/OBSBasic_Transitions.cpp @@ -73,6 +73,14 @@ void OBSBasic::InitDefaultTransitions() } } + // We require transitions in order to function, so exit with an error if + // obs-transitions failed to load for whatever reason. + if (!fadeTransition || !cutTransition) { + // FIXME: https://github.com/obsproject/obs-studio/issues/13394 + throw "InitDefaultTransitions: Could not load default transitions. Try re-installing OBS Studio from " + "obsproject.com."; + } + for (OBSSource &tr : defaultTransitions) { std::string uuid = obs_source_get_uuid(tr);