For Linux distros still living in the stone ages, use the old
randomization code. Fixes CI not building. We can change it later when
we finalize good random stuff.
Setting this to zero breaks reconnecting (and OBS) entirely as various
parts of the reconnect system do not handle zero values properly, and
there are also possible race conditions with the reconnect thread. Set a
minimum of 1 second to avoid this.
mt19937 is a deterministic RNG and was not seeded, so the state
parameter was identical for all runs. Switch to using Qt's
QRandomGenerator::system() which is implemented as a CSPRNG on
all platforms we care about.
Very low risk of anything bad here since we use a random port and the
chance of a CSRF attack is tiny, but this is a best practie to do when
using OAuth.
Reorder styling so that checked buttons can still
get hover styling.
Add a distinct background color for disabled
buttons. Fixes the text being the same color
as the button when disabled.
In order to be able to POST binary data that may contain NULL-bytes we
must manually specify the size of the array, otherwise cURL will fall
back to `strlen()`.
Appears to be a remnant left by the undo/redo system changes, not used
at all by any parts of the UI. This slot does not have undo/redo
system functionality, so it is not useful in its current form.
There are some cases where an item may attempt to be created for a
removed source.
Previously, items created from removed sources would lead to the item
itself being saved, but the underlying source not being saved. While
this does not break OBS immediately, it means that the source along
with all associated items will disappear on OBS reload.
This prevents the item from being created in the first place, reducing
the chances of user work being lost.
If there is a PTS discontinuity in the playback stream that causes the PTS to
reset, it is likely that new audio frames will come in while there are still
video frames waiting to be dequeued. This will cause the audio frames to be
played while the video frames wait for the PTS to get back up to where they
were before the discontinuity.
66c27c2ceaa65 (#4664) was mistakenly merged. It was also the incorrect
way to fix the deadlock. Because duplicate_item_data() already defers
the texture creation process, we can just add a param to
obs_scene_add_internal() which allows us to exclude the creation of the
item texture for this specific case. The texture will then automatically
be created later before it's used. There was no reason to be creating
the texture there, as it was unnecessary.
Properly fixesobsproject/obs-studio#3166
There is a new toolchain called ARM64EC on MSVC which allows linking x64 objects to ARM64 objects.
It defines multiple architecture preprocessor definition including but not limited to `_M_X64`, `_M_ARM64` and `_M_ARM64EC`.
The original implementation will fail if compiling to ARM64EC.
As logic in video render thread, gs lock (obs_enter_graphics) should be requested before full_lock(scene).
However in function obs_sceneitem_group_ungroup called from UI thread, the order for requesting locks are contrary.
Windows 11 support for DISCARD swap effect seems to be buggy and slow.
Use FLIP_DISCARD instead. Staying with DISCARD on Windows 10 because of
reports of flickering that hopefully won't happen on Windows 11.
We're also not using ALLOW_TEARING because it seems to break after an
OBS cycle of minimize/restore on both Windows 10 and 11. The swap chain
displays a stale image. Not sure if ALLOW_TEARING would be beneficial
even if it was working.
Commit 60d95cb5 introduced some code that used the + operator on two
Qt::Modifier items. Using a pipe operator instead fixes the compilation
error on Qt5 and Qt6.
The YouTube integration changes introduced code that does not build on
Qt6. The errors were:
* void QLocale::setDefault(const QLocale &)': cannot convert argument 1
from 'QString' to 'const QLocale &'
* no suitable user-defined conversion from "QString" to "const QLocale"
exists
This commit creates a new QLocale in place from a QString using the
`QLocale(const QString &name)` constructor, and passing that QLocale to
QLocale::setDefault.