Previously it was setting the `averageBitRate` value to what is being set in Variable Bitrate rate control mode. However, CQVBR is initialized with a value of `0` and instead Target Quality is being used. This adds a check for the CQVBR mode and if it's set will update the `targetQuality` value, otherwise it will update `averageBitRate`.
Additionally reset `averageBitRate` to 0 if CQVBR is active, and reset `targetQuality` to 0 if it's not in any VBR mode
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.
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.
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.
Replaced implicit type conversion within macOS plugins (mac-capture,
mac-syphon, mac-videotoolbox, mac-virtualcam) with explicit type
conversions to clear compile errors with Apple Clang 21.0 and Xcode
26.4.
Co-authored-by: PatTheMav <patthemav+github@gmail.com>
Co-authored-by: jcm <6864788+jcm93@users.noreply.github.com>
CreateFileW returns INVALID_HANDLE_VALUE on failure, not NULL.
The previous check would always evaluate to true on failure,
causing ReadFile and CloseHandle to be called on an invalid
handle.
Previously, the Image Slide Show source skipped *.webp files when
adding images via 'Add Directory'. This update ensures that .webp
files are now correctly included.
The NVENC session was destroyed before its child resources
(textures, surfaces) were cleaned up, causing resource cleanup
calls to operate on an invalid session handle.
Reorder destruction to free all registered resources before
destroying the encoder session.
Reverts much of PR #11906 in favor of a different way to detect whether
or not the output capabilities must be reset.
The new approach will contain false positives for which the workaround
is not needed but it won't have negative side effects.
When a new device is selected, a best-possible frame rate is chosen
for the initial configuration of the device. This has to be set in the
source settings, as those are the "source of truth" for the properties
and the device configuration.
The object has to be created explicitly first before setting the
frame rate value. The source then has to be updated explicitly as well
to ensure that the change will be picked up by the next iteration
of the render thread to "tick" the source and thus make it configure
a capture session with the fallback framerate set.
v1 of obs_properties_add_button will be deprecated soon.
Also fixes UNUSED_PARAMETER calls in the callbacks for parameters that
are not actually unused, and moves the other ones to the top (as in most
of the rest of the project).
Make sure to use the invalid fd -1 when the output is not opened, and
only close valid fds. If fd 0 is closed, then this closes stdin. The
second time this happens, some other important fd will have become fd 0,
breaking something.
This causes random things to break (browser/CEF in reports, but really
it could be anything) as the wrong fds get closed.
The use of `SPA_POD_OPT_Rectangle()` means that if the rectangle cannot be
parsed, then no error will be returned. In that case uninitialized variables
will be used. This can happen if the pod object contains e.g. a list of
resolutions (`SPA_CHOICE_Enum`).
Fix that by using `SPA_POD_Rectangle()`, which enforces successful parsing.
New Features:
- Added Canvas support [exeldro]
- `GetCanvasList` request
- `CanvasCreated` event
- `CanvasRemoved` event
- `CanvasNameChanged` event
Bug Fixes:
- Fixed a possible crash on OBS shutdown [exeldro]
Changes:
- Updated translations [WizardCM]
- Various fixes and improvements to Canvas support [tt2468/Warchamp7]
The SPA format (pixelformat) was compared with a libobs video format
value.
Also removes the SPA format support check since at this point it already
has been done while listing formats.
The resolution and aspect ration should be added to the description of
the format even if there are no available frame rates.
The code is restructured a bit to avoid having to call `dstr_free()`
before each `continue`.
Fixes: 4cfcfc8c35 ("linux-pipewire: Make camera framerate non-mandatory")