Notable Changes:
* deps.macos: Fix deletion of MbedTLS CMake files
* deps.ffmpeg: Fix deletion of MbedTLS static libs
* deps.ffmpeg: Enable Windows on Arm for nv-codec-headers
Construct 3 games register a top-level window class named
"WindowsWebview2Wrapper" which does not contain "Chrome" or "Mozilla",
causing OBS automatic mode to use BitBlt instead of WGC, which results
in a black screen for Construct 3 games.
Add "WindowsWebview2Wrapper" to wgc_whole_match_classes and add
compatibility entries for window capture BitBlt and game capture
warnings.
Closes#13359
AVC and AV1 encoders in AMF that support B-frames were incrementing
`dts_offset` even when B-frames were set to 0. For AVC, adjust the
`dts_offset` only when B-frames are supported and are greater than 0,
and clamp to maximum supported.
For AV1, remove the dts_offset code completely because it is being
ignored anyway. AV1 handles B-frames and offsets differently; refer
to [1] for details.
[1]: https://github.com/obsproject/obs-studio/pull/10996
obs_module_unload was never properly documented, so some plugins use it
to free resources, some use it to save data, etc. While libobs tries to
ensure all objects are shut down and destroyed before calling unload, if
another plugin is holding a strong reference, or if a reference leak has
occurred, libobs may need to call back into a plugin-provided object's
destroy function even after obs_module_unload has returned. If the
plugin has freed memory or other resources needed for the callback then
this likely results in a crash.
Going forward, we should document that obs_module_unload is now intended
only for saving data and releasing references, and that calling libobs
after it returns is not allowed. For cases where resource cleanup is
actually needed (for example, an external out of process helper needs to
be shut down or a release call to a hardware driver), a new
obs_module_destroy callback is intended to be added in a future version.
It's not that uncommon for apps on Windows to use a hacky method of
extending their windows 1-2px past the supported monitor resolution
to preserve "true" windowed fullscreen and circumvent some exclusive
fullscreen-related issues presented by their graphics library,
Windows itself, or both.
Therefore, the fullscreen detection technique has been relaxed
to properly identify windows slightly larger than the monitor's
viewport as fullscreen.
Windows also does something similar, evident by the fact that
the taskbar disappears, as it always does for fullscreen windows,
even when a window stretches slightly beyond the defined viewport.
libobs/graphics: Update libnsgif to 1.0.0
libobs/graphics: Hide GIF decoding data from exported header file
libobs/graphics: Break image file API to prevent ABI issues
Co-authored-by: Norihiro Kamae <norihiro@nagater.net>
Co-authored-by: Lain <lain@obsproject.com>
I discovered while testing that the first split would always be one GOP
too long (e.g. 1m2s instead of 1m) due to the fact that b-frames and
negative start DTSes were not accounted for.
This is now fixed by setting the start_time to the nonzero negative DTS
produced for the first packet. Additionally, a small tolerance of 1 ms
was also added to account for rounding issues present in the first GOP.
Originally, before file splitting was introduced, I made the choice to
simply ignore the last frame in the packet queue of the muxer, because
frame N+1 is required to properly determine the duration and I figured
nobody would notice if their recording is one frame short.
However, when using frame splitting this would result in the last frame
before the split being dropped. To fix this, we can simply reuse the
previous sample's duration for the final sample in a file. Since OBS
only does CFR, they should all be identical anyway.
The recording audio bitrate was hardcoded to 192 kbps regardless of
channel layout. For a 5.1 mix this yields ~32 kbps per channel which is
very low quality. Scale proportionally from the stereo reference (192
kbps) using the active channel count, snapping to the closest bitrate
supported by the selected encoder (AAC or Opus).
Stereo recordings are unchanged (192 * 2 / 2 = 192 kbps).
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.
This process mitigation flag is inherited by child processes and applies
to load-time DLL resolution, pushing the application's own directory
below the system directories. If there are system-installed copies of
dependent DLLs such as FFmpeg, those get loaded when OBS is updated as
the updater and subsequent relaunch of OBS inherit the mitigation.
As we use SetDefaultDllDirectories, this mitigation is less important,
the proper fix would be to use /DEPENDENTLOADFLAG to protect load-time
import resolution.
Qt 6.11 only supports macOS 13+. It does not support macOS 12, and OBS
Studio will fail to launch on macOS 12 as a result. We should reflect
that with our deployment target.
https://doc.qt.io/qt-6.11/supported-platforms.html
We suspect users hit errors updating the system-wide hook files even if
the file is not in use, but without logging we have no way to know for
sure. This commit adds additional logs. Not logging source paths
anywhere is intentional to avoid wide char to utf-8 issues making this
more complicated than it needs to be - the source will always be the OBS
install dir regardless.
The previous increase from 1 to 3 deltas has an acceptable time cost on
CI. Further increase it from 3 to 5.
This should somewhat improve the update experience on macOS for users
not on the most recent previous version of OBS Studio.