Commit Graph

15585 Commits

Author SHA1 Message Date
PatTheMav
b1d9dffbc5 plugins: Force C language for clang-format
Only applies to actual ObjC-based plugins.
2026-06-17 15:17:09 -04:00
PatTheMav
d838e11983 plugins: Force C language for clang-format
Only applies to actual C-based plugins.
2026-06-17 15:17:09 -04:00
PatTheMav
00b38750e3 libobs-opengl: Force C language for clang-format 2026-06-17 15:17:09 -04:00
PatTheMav
426c594513 libobs: Force C language for clang-format 2026-06-17 15:17:09 -04:00
PatTheMav
fe522d431e CI: Update clang-format to 22.1.3 2026-06-12 17:22:50 -04:00
Ryan Foster
ef97d2eabd Merge pull request #13543 from RytoEX/update-to-vs2026
CI: Update to VS 2026
2026-06-12 16:57:34 -04:00
Ryan Foster
c60ca298d1 CI: Update sign-windows commit 2026-06-10 22:54:59 -04:00
Ryan Foster
83bb52b682 CI: Update to Windows 2025 with VS 2026
This will also allow us to move to clang-format 22 which ships with
VS 2026.

 * Update the CI image to windows-2025-vs2026
 * Update VS generator to 2026
 * Update Windows SDK to 26100
2026-06-10 22:12:02 -04:00
Ryan Foster
84b8d16134 .git-blame-ignore-revs: Add change from forcing braces in C++ 2026-06-09 14:57:38 -04:00
Warchamp7
30b63c6849 Update C++ files with braces 2026-06-09 13:41:19 -04:00
Warchamp7
32bf5100fb Update clang-format to insert braces in C++ 2026-06-09 13:41:19 -04:00
Ryan Foster
92ecfcfd5b CI: Remove Homebrew's setup-homebrew action
This was used to ensure that we had Python 3.12 or newer. The Ubuntu
24.04 runners now have Python 3.12, and the macOS 15 and 26 runners have
Python 3.14.
2026-06-08 19:15:03 -04:00
PatTheMav
0db6d4f88c frontend: Use conditional custom Sparkle feed
When OBS runs via Rosetta 2 emulation on an Apple Silicon host, the
next automatic update via Sparkle should use a native Apple Silicon
build rather than the newest Intel build.

This is achieved by setting a custom feed URL on the delegate object
which will then respond with this URL (or alternatively with "nil")
when Sparkle calls the appropriate delegate method.
2026-06-08 18:49:46 -04:00
PatTheMav
d91999b4cf frontend: Add feedUrlStringForUpdater delegate
Adds necessary delegate method to OBSSupdateDelegate to provide
alternative AppCast feed URL at runtime.

The NSString pointer is allowed to be "nil" as Sparkle will only use
a non-nil return value to change from the default feed URL.
2026-06-08 18:49:46 -04:00
Nerixyz
b8f7a1e3b8 cmake: Enable Swift language on macOS 2026-06-08 17:52:56 -04:00
Jimi Huotari
714caa7aa3 frontend: Fix build with Qt 6.12
After Qt upstream commit 556028d16a0 [1], 'QHash' and 'QSet' need
to be explicitly included when using 'QT_ENABLE_STRICT_MODE_UP_TO'.

1. https://code.qt.io/cgit/qt/qtbase.git/commit/?id=556028d16a059006cc5a03676260aff5428b767e

Signed-off-by: Jimi Huotari <chiitoo@gentoo.org>
2026-06-08 17:08:45 -04:00
PatTheMav
da54134cb9 libobs-winrt: Fix compile error with MSVC 2026
MSVC Build Tools 14.50 shipping in Visual Studio 2026 18.0 have
officially deprecated any experimental implementation of coroutines.

The WinRT base header does conditionally include the experimental header
if no "native" implementation can be found (which will be true for
any C++ language version before C++20).

Even though libobs-winrt does not make use of any coroutines, it has to
include the base header and will thus trigger this error.

Per the official deprecation notice, this warning can be silenced and
will be automatically resolved once the project upgrades to C++20
support.
2026-06-08 16:51:37 -04:00
tytan652
381d4ba2f4 build-aux: Update Flatpak to 2026-06-06 deps
- Update nv-codec to n13.0.19.0
- Update FFmpeg to 8.1
- Update qrcodegen-cmake to v1.8.0-cmake4
- Update libdatachannel to v0.24.2
  - Update plog to version 1.1.11
- Update Qt to 6.11.1
- Update libvpl to version 2.16.0
- Update vpl-grpu-rt to version 26.1.5
- Update ECM to version 6.26.0
2026-06-08 16:09:33 -04:00
PatTheMav
51efca0026 CI: Fix broken CAS path for macOS analyze builds
With the switch to Xcode 26.5 the analyze command started to use the
built-in compilation cache (per the CMake preset) which breaks those
builds specifically as no writable CAS path is set for this workflow.

This change adds the same code used for the normal build workflow to
set a specific CAS path. Because the contents of that path are not
retained by a caching action, no actual caching for analyze builds takes
place.
2026-06-08 15:34:40 -04:00
PatTheMav
6b1845fe8a frontend: Fix OAuth and dock state save corruption
When the app is quit on macOS, the underlying process is either
triggered by an application-level "Quit" event or by a main window
"close" event.

If the application-level "Quit" event is the trigger, OBSBasic::saveAll
is called twice: First by Qt's session manager (via OBSApp::commitData)
and another time by the main window's close event handled by
OBSBasic::closeWindow.

However if the main window is closed first (and is the first to call
"saveAll") the underlying OAuth data object is destroyed after the data
has been saved. When the second "saveAll" call takes place, it
encounters a "nullptr" for the auth object, which makes "Auth::Save"
effectively remove any OAuth configuration from the settings file
(undoing prior work).

At the other end, if the application quits first, some dock windows
might have been explicitly closed by Qt before the main window is closed
and thus the second call to "saveAll" will overwrite valid browser dock
state data with incomplete data (any dock that has been closed by Qt
before will not be present in that data).

Wrapping the code responsible for saving OAuth and browser dock state
data in a "std::call_once" block should ensure that this data is only
written once and by whoever gets to call "saveAll" first (at which point
state data is still considered "complete").
2026-06-08 15:08:24 -04:00
Rob Howell
026ec264b8 frontend: Fix group bounds not resizing when removing items 2026-06-08 14:25:47 -04:00
Ryan Foster
93ba0b33ed frontend: Fix Apple ifndef preprocessor check
Currently, this is causing this branch to be called even on Apple
because __APPLE_ is not defined anywhere.
2026-06-08 13:55:00 -04:00
Warchamp7
9f4320ec70 frontend: Adjust shutdown logic more 2026-06-08 12:01:28 -04:00
PatTheMav
f61619ce30 frontend: Fix multitrack custom config handling
Custom configuration for multitrack-enabled services is only supposed
to be available for the "rtmp_custom" service type, as that's also
the condition for the corresponding text input to become visible in the
settings dialog.

When a user switches their desired service from the custom service back
to another service that also supports multitrack, the custom service
configuration is still present and will be applied even though it
should only be effective for the custom service.

This change makes the simple decision to ignore any available custom
multitrack configuration if the service is not "rtmp_custom" and
requires an "auto_config_url" to be available in that case. Otherwise
the "rtmp_custom" service requires an "custom_config" to be available.

That way the implementation reflects the behavior of the settings dialog
and will not lead to the present unexpected behavior, including:

* The custom configuration is "merged" with the config ID provided
  via the "auto_config_url".
* A non-custom service might fail to configure because the custom config
  is applied and might be missing required fields.
* A non-custom service might succeed to configure because the custom
  config is applied and has all required fields, but the service was
  meant for an entirely different service.

Additionally the unused "MultitrackVideoDeveloperModeEnabled" function
was removed. For simplicity's sake, all legacy code paths that allowed
interference or custom overrides with the service configuration for
established services are removed.

If such functionality is still desired, it needs to be reimplemented in
a service-agnostic way, taking the possibility of other multitrack-
capable services into account.
2026-06-05 16:43:12 -04:00
PatTheMav
1829492e6b cmake: Move frontend plugins into main plugins dir
Frontend plugins should not require being placed in the frontend
directory to be built successfully. Indeed they should only depend
on libobs and the obs-frontend-api and thus their source tree should
be able to exist anywhere (even standalone) and the plugin should still
compile successfully (just like any 3rd party plugin).

Thus moving those plugins into the main plugin directory ensures that
they don't require on any "special sauce" within the source tree to
compile.
2026-06-05 16:00:18 -04:00
PatTheMav
35c7a5a173 cmake: Fix frontend feature flag mismatch
The actual frontend provided an "ENABLE_FRONTEND" build flag, whereas
the global project still provided an "ENABLE_UI" flag, which itself was
only read and respected by the scripting module.

This change retains the global flag and makes both the actual frontend
as well as the scripting module respect its value.
2026-06-05 16:00:18 -04:00
Richard Stanway
9541600b3d nv-filters: Improve handling of SDK DLL loading 2026-06-05 15:27:30 -04:00
Richard Stanway
e29a640ddd obs-ffmpeg, win-capture: Use better default DLL directory settings 2026-06-05 15:27:30 -04:00
Richard Stanway
8801dbef06 libobs: Avoid calling SetDllDirectory when looking for dependent DLLs
Using the full path and appropriate LoadLibraryEx flags is safer as it
gives us more control over the search paths.
2026-06-05 15:27:30 -04:00
Richard Stanway
77eabcc06a frontend: Set better default DLL directory settings on Windows
This helps mitigate "DLL planting" attacks by removing the current
directory from most DLL loading calls.
2026-06-05 15:27:30 -04:00
Richard Stanway
76ea10e281 coreaudio-encoder: Avoid using SetDllDirectory, specify full path 2026-06-05 15:27:30 -04:00
Ryan Foster
3b4872c5c0 frontend: Replace implicit "=" with "this" 2026-06-05 14:48:32 -04:00
Alex Luccisano
af77628900 frontend: Fix null settings and DBR for custom configs
When using custom RTMP output with a JSON config that omits
encoder settings, settings.dump() produces "null" which
obs_data_create_from_json cannot parse. Fall back to
obs_data_create() for null/non-object settings so encoders
use their defaults.

Additionally, when bitrate_interpolation_points is absent,
the code unconditionally set interpolation_table_data as
empty arrays. This caused build_dbr_interpolation_table to
wipe the default linear table, leaving DBR enabled but
unable to adjust bitrates during congestion. Only set the
interpolation data when all encoders provide it, otherwise
fall back to the default linear 0-to-max interpolation.
2026-06-05 14:11:55 -04:00
Alex Luccisano
83ed914ecf obs-outputs: Use multitrack DBR capability flag
Use the new `OBS_ENCODER_CAP_MULTITRACK_DYN_BITRATE` flag when
streaming with multiple tracks, instead of relying on the single-
track `OBS_ENCODER_CAP_DYN_BITRATE` flag. In multitrack cases where
multiple codecs are being used (e.g. mixed AVC and HEVC), all encoders
must support the multitrack capability flag otherwise the dynamic
bitrate (DBR) feature is disabled for the streaming session.
2026-06-05 14:11:55 -04:00
Alex Luccisano
0943ea2cf6 plugins: Apply multitrack dynamic bitrate flag
Enable the `OBS_ENCODER_CAP_MULTITRACK_DYN_BITRATE` capability on
the encoders that support it.
2026-06-05 14:11:55 -04:00
Alex Luccisano
edbe74b2b5 libobs: Add multitrack dynamic bitrate capability
The `OBS_ENCODER_CAP_DYN_BITRATE` flag indicates if an encoder is
capable of supporting dynamic bitrate changes without disturbing
the stream. In the case of multitrack video, dynamic bitrate changes
are also possible, however the encoder must be able to change bitrates
for multiple renditions and multiple codecs and maintain IDR alignment.
Add the `OBS_ENCODER_CAP_MULTITRACK_DYN_BITRATE` to specify this
capability for the encoder.
2026-06-05 14:11:55 -04:00
Alex Luccisano
14f25811d1 frontend: Remove multitrack locale strings
Remove the locale strings that are no longer needed now that
`HandleIncompatibleSettings()` is removed, and replace some
`<br>` tags with \n to fix rendering issues on MacOS.
2026-06-05 14:11:55 -04:00
Alex Luccisano
b1be50013f obs-ffmpeg: Rework AMF dynamic bitrate change behavior
The `amf_xxx_update()` functions for AVC, HEVC, and AV1 are
unconditionally invoking Flush() and ReInit() even though this is not
required in all situations. Changing the bitrate at least in CBR mode
does not require the flush operation and can result in unaligned IDR
frames across members of an encoder group. Do not flush the pipeline
for CBR bitrate changes; instead, force an IDR to occur with the
bitrate change.
2026-06-05 14:11:55 -04:00
Ruwen Hahn
cd95b3bf49 frontend: Add dynamic bitrate support to multitrack video
The bitrate interpolation points are sent in JSON configuration and
need to be forwarded to `create_video_encoders()`. Also remove the
`HandleIncompatibleSettings()` handler because there are no longer any
incompatible settings.
2026-06-05 14:11:55 -04:00
Ruwen Hahn
4c97c62ccf obs-outputs: Implement multitrack dynamic bitrate 2026-06-05 14:11:55 -04:00
Ruwen Hahn
dd1e93f1ab libobs: Refactor encoder_group access
Also reconfigure all grouped encoders on the same frame.
2026-06-05 14:11:55 -04:00
PatTheMav
b8360d7261 cmake: Update Xcode version requirement on macOS
In preparation for macOS 27 and to fix existing build errors when
Swift 6 (rather than Swift 6.1 is used) to build the project, force use
of Xcode 26.5 for macOS builds.
2026-06-04 15:57:25 -04:00
PatTheMav
2e2612dc95 CI: Update macos runners and used Xcode version
In preparation for macOS 27 and to fix existing build errors when
Swift 6 (rather than Swift 6.1 is used) to build the project, force use
of macOS 26 runners as well as Xcode 26.5 for CI.
2026-06-04 15:57:25 -04:00
Ryan Foster
2598e33a1e CI: Update deps to 2026-06-02 release
Notable Changes:
 * deps.macos: Update Sparkle to 2.9.2
 * deps.qt: Update Qt to 6.11.1 for Windows
 * deps.qt: Update Qt to 6.11.1 for macOS
2026-06-04 14:40:27 -04:00
Ryan Foster
fc95b0a83b CI: Update deps to 2026-05-21 release
Notable Changes:
 * deps.ffmpeg: Update AOM to 3.13.1
 * deps.windows: Add VST3 SDK
 * deps.macos: Add VST3 SDK
 * utils.zsh: Enable debug symbols for ObjC
 * deps.ffmpeg: Update nv-codec to n13.0.19.0
 * deps.ffmpeg: Update AMF to 1.5.0
 * deps.ffmpeg: Update FFmpeg to 8.1
 * deps.macos: Update qrcodegen-cmake to v1.8.0-cmake4
 * deps.macos: Update Sparkle to 2.9.1
 * deps.qt: Update Qt to 6.10.3 for Windows
 * deps.qt: Update Qt to 6.10.3 for macOS
 * deps.ffmpeg: Enable PDBs for FFmpeg builds on Windows
 * deps.ffmpeg: Update libdatachannel to v0.24.2
2026-06-03 16:37:51 -04:00
Wu Haoyu
151097d3bd frontend: Fix a dereference of nullptr
`outputResolution` may not be editable and outputResolution->lineEdit()
can return `nullptr` which causes crash.
2026-06-02 15:15:34 -04:00
Warchamp7
686ee75a05 frontend: Set up theme watcher during init 2026-05-28 16:09:19 -04:00
John Bowers
4d6d9a5166 frontend: Slight change to multi-track text
Change text to indicate that enhanced broadcasting/MT does not have
to configure multiple encodes, although it often/usually does.
2026-05-27 12:45:53 -04:00
Ryan Foster
4726edd113 frontend: Fix updates failing when configured without What's New
The updates config folder is used to download files tied to update
branch selection and application updates. If this folder does not exist,
the downloads fail. Tying this folder creation to What's New, which also
uses this folder, seems incorrect, since it is also uses for application
updates. Remove the ifdef guard for folder creation.
2026-05-26 17:07:05 -04:00
Zhang Boyang
97ee7fa7cb cmake: Fix dependency download logic
Previously, if download failure occurred or interrupted by Ctrl-C, the
broken file is not removed. This is true for the first case because
"message(FATAL_ERROR ..." stops cmake and "file(REMOVE ..." is never
reached. After that, if cmake is run second time, SHA256 verification is
skipped and the broken file will be used.

This patch fixes this by using a temporary intermediate file. The file
data is downloaded into a temporary file first, then the temporary file
is atomically renamed to destination.

Error checking of download status is also improved. The if clause now
checks error code against zero more strictly, according to cmake's
documentation.
2026-05-26 15:41:10 -04:00