If a frame has a width or height of zero, this value will make it into
libobs/media-io/video-frame.c:video_frame_init and cause linesizes or
heights to be zero, which will result in a bmalloc(0) call and OBS will
crash.
Instead of letting the call stack get that far, check the frame width
and height here at the source, log an error, and return early if the
frame width or height are zero.
(cherry picked from commit 3437e2b082)
082a0a2 - Don't emit a normal call to a function for closing panels
663dc38 - Disable modern game controller API on Windows
4023fad - Log fatal CEF crashes to file
52c1527 - Print browser source renderer crashes to OBS log
af0651b - Log error if CefInitialize fails
8223215 - Revert "Enable Qt message loop on Linux"
16ff0fa - Update version to 2.24.5
Additionally, update buildspec.json and build-aux/modules/99-cef.json to
use the new CEF builds. This is being done because the changes in
obs-browser specifically are meant to work with a CEF build compiled
with use_gtk=false.
(cherry picked from commit 3d9d066d07)
This was logging an intermediate value, rather than the final lookahead
depth value after all calculations. Log the final value instead.
(cherry picked from commit a8a349c805)
The regexp was not tolerating a + sign is the version string,
causing configuration to fail on Ubuntu 24.04 when the installed
version is 6.1.1-3ubuntu5+esm2.
(cherry picked from commit 9b97d48573)
We don't use CUDA RT functions anymore.
So this commit removes their loading from the CUDA RT DLL.
This also fixes a crash when loading different versions of CUDA RT when
the SDK is updated [1].
[1] https://github.com/obsproject/obs-studio/issues/11813
Signed-off-by: pkv <pkv@obsproject.com>
(cherry picked from commit d1249cd993)
This updates checks against current SDK redist versions:
- 0.7.6 (Video Effects)
- 1.6.1.2 (Audio Effects)
Users will receive a warning if their redist versions are lower than
these.
Signed-off-by: pkv <pkv@obsproject.com>
(cherry picked from commit 417eddfc9d)
If - for some reason - the name in a scene collection is empty (or
the key doesn't even exist), use the filename stem as a fallback name.
This ensures that the scene collection entry in the cache has a valid
non-empty name.
Using an std::string allows the use of its "empty" method to check for
this otherwise invalid state of the collection data.
Ported from 1baa4619e4.
Co-authored-by: PatTheMav <PatTheMav@users.noreply.github.com>
Empty names for scene collections are not allowed, but this constraint
is only enforced by UI code during text input.
Thus frontend API users are able to create valid scene collections with
empty names which will lead to later possible crashes as the scene
collection is malformed.
As the frontend API uses the related function CreateNewSceneCollection
which handles exceptions by this method, no crashes should occur when
an empty string is provided by an API caller.
Ported from 552c19cab2.
Co-authored-by: PatTheMav <PatTheMav@users.noreply.github.com>
We directly depend on libx11 for various operations in obs-nix-x11.c,
not just xcb. So be sure to link it in too.
fixes#11667
(cherry picked from commit 22f222600a)
The reaction effects that macOS adds by default are confusing to users
as they're turned on by default and users don't know where they come
from or where to turn them off. Setting this flag in the apps Info.plist
prevents them from being turned on by default. The macOS UI makes it
very obvious to the user where they can turn them on should they wish to
do so.
(cherry picked from commit 79f5ba0e1d)
This fixes a bug where the NVIDIA NVAFX filters are migrated but not
kept in their original order, with respect to other filters.
Signed-off-by: pkv <pkv@obsproject.com>
Revert "docs: Add new relative positioning scene functions"
This partially reverts commit 366cfdb963.
The addition of obs_sceneitem_(get/set)_info2 was not removed as that is
still valid.
The new Scene Collection code uses the lazy creation behaviour of
OBSBasic::Load, which itself uses obs_data_create_from_json_file_safe.
The internal implementation will create a new scene collection with the
contents of an existing backup file with the same name however, thus
users would end up with a nominally "new" scene collection that
contains contents of an old backup.
This update will remove any existing backup file colliding with the
name of the new, duplicated, or renamed, scene collection and remove it
before activating it (and having OBSBasic::Load create a new one).
Upon further review, the build directory is never set to build_$arch.
Currently, our CMake Presets on Ubuntu only use build_ubuntu. However,
we can attempt to be flexible here and simply exclude the build
directory configured in CMake.
When custom module and module data paths are provided via environment
variables, the module paths generated by current code will not be
compatible with the plugin bundle structure used on macOS.
Using environment variables is a simple way to test plugins,
as this allows OBS to discover them from alternative user-provided
locations.
This lambda would be called from the Qt event loop rather than the
original call stack when continuing from an error, resulting in the
captured references being invalid.
To solve this must explicitly use a copy instead of reference capture.
The regex was incorrectly excluding any file with build in the name. The
intent was to exclude any build directories, so we should be able to
restrict this.