0
0
mirror of https://github.com/obsproject/obs-studio.git synced 2024-09-20 21:13:04 +02:00
Commit Graph

12379 Commits

Author SHA1 Message Date
derrod
4b062a7147 libobs: Add functions for getting/saving pretty JSON 2023-03-10 23:55:42 +01:00
gxalpha
bb4e6f9e51 UI: Don't try to make OBSBasic parent of ControlsSplitButton
Passing the parent of a QLayout sets it directly as the top-level layout
(as per the QLayout docs). This is obviously not what is intended here.
Luckily it doesn't even work since the main window of course already has
a layout which would need to be explicitly removed before, but it makes
Qt yell at us for trying.
2023-03-11 09:38:46 +11:00
derrod
705173a0c3 UI: Add fragmented MP4/MOV formats 2023-03-10 17:12:36 -05:00
derrod
05b1be4f27 UI: Add MP4 to remuxable extensions 2023-03-10 17:12:36 -05:00
gxalpha
4c9ebc753c UI: Create OBSPermissions on stack
This fixes the window leaking and may improve performance.
2023-03-10 13:49:52 -05:00
Stefan Murawski
95cbd21a3b UI/installer: Add quotes around UninstallString
This follows recommended practice from NSIS documentation.

This fixes issue #7935.
2023-03-10 12:58:33 -05:00
derrod
198c2b9e86 media-playback: Fix libavutil version check 2023-03-10 08:15:54 +01:00
Bartłomiej Piotrowski
853ae5ea6e UI: Set flathub::manifest
Currently, the manifest URL on Flathub Beta website points to the
deprecated manifest hosted on Flathub. The flathub::manifest key
is undocumented attribute that will update the website to use the
proper location.

This key will not affect appstream other than providing enough
information to the Flathub website.
2023-03-09 20:33:44 -03:00
gxalpha
b1c96bba86 UI: Re-raise remux dialog after selecting file on macOS 2023-03-09 16:05:40 -05:00
gxalpha
9c6a3a1d49 obs-vst: Fix memory leaks on macOS when VST's fail to load
Detected by clang-analyzer.
2023-03-09 15:18:38 -05:00
Richard Stanway
9d4a7f01dd UI: Add DLL blocking functionality for Windows
Adds a NtMapViewOfSection hook which we can use before DLLs are loaded
to decide whether to abort the process. This is useful for blocking
known problematic DLLs that cause crashes. In addition, the PE timestamp
can be checked to block only older DLLs such as older versions of Vtuber
virtual cameras with known deadlock bugs.

A simple counter of each DLL is used for logging purposes. Since DLLs
can be blocked at any time, the output is only logged on exit of OBS.
2023-03-09 14:16:34 -05:00
Mathijs Kadijk
970c284a65 mac-virtualcam: Prevent PTS rounding
All presentation time stamps are rounded to whole seconds during the
conversion from nanoseconds to seconds, because of the immediate cast
to `int64_t`. This results in the same presentation time stamp being
send to consumers for a whole second.

In previews/live streams this isn't super visible as last frame is
often assumed to be the newest and the stream is updated. It's more
problematic when recording since APIs like Apple's AVFoundation don't
allow duplicate presentation time stamps or it can look like frames are
produced in huge bursts once per second.

In this PR `CMTimeMakeWithSeconds` is used instead of `CMTimeMake` to
make sure the conversion is done correctly and simplify the calculation
we have to do a little.
2023-03-09 15:45:48 +01:00
Mathijs Kadijk
ecaa5466cb mac-virtualcam: Fix incorrect PTS on Apple Silicon
The `fillFrame` method of the mac-virtualcam plugin is creating samples
directly using the value from `mach_absolute_time()` as `hostTime`.
This assumes this value is in nanoseconds, while it is in fact in mach
tick units. On Intel Macs mach tick units will be exactly 1 nanosecond
resulting in valid values, but on Apple Silicon macs this is no longer
the case.

This results in sample buffers with the placeholder image that have
much lower presentation time stamps than the samples containing content
produced by OBS. In previews/live streams this shows due to the last
content sample being shown frozen until the whole buffer is filled with
samples containing the placeholder image. Applications recording the
video stream are even more confused and crash or record videos with
wildly incorrect lengths.

In this PR `clock_gettime_nsec_np` is used to convert from mach tick units
to nanoseconds. This will make sure the `hostTime` value is correct on
both Apple Silicon and Intel macs. Making sure we produce stable
presentation time stamps from the virtual camera plugin at all times.
2023-03-09 15:45:48 +01:00
derrod
f3b1a1cf1f UI: Use bilinear scaling for YT thumbnail 2023-03-08 18:41:20 -05:00
derrod
c99256cf21 UI: Do not set default locale 2023-03-08 18:06:51 -05:00
Ryan Foster
002bd0b5a4 win-capture: Suppress LNK4098
Suppress LNK4098 to allow building against pre-built Jansson for now.
2023-03-08 17:14:11 -05:00
derrod
c55fcbbb12 UI: Use binary mode for QuickReadFile
When not using binary mode (i.e. text mode) CRLF will be converted to
LF, which means that the size provided by tellg() is no longer correct,
and reading prematurely hits an EOF and sets the fail bit.
2023-03-08 22:50:49 +01:00
derrod
5dd1d00a03 UI: Add mutex to reading public key file 2023-03-08 22:50:49 +01:00
derrod
2c48e61207 UI,obs-vst: Set Qt RCC format to 1
v2 introduces last-modified timestamps that ruin reproducibility.
2023-03-07 18:13:24 -05:00
derrod
f06b2ccf55 cmake: Set PDBALTPATH manually 2023-03-07 18:13:24 -05:00
derrod
d2f0dfa341 cmake: Set /Brepro compiler/linker options 2023-03-07 18:13:24 -05:00
derrod
75693a6682 libobs: Write default values to config 2023-03-07 17:44:19 -05:00
tytan652
278973576e obs-outputs: Fix RTMP undefined symbols if built without Mbed TLS 2023-03-07 17:01:49 -05:00
derrod
3fd7216661 CI: Validate compatibility schema 2023-03-07 16:03:18 -05:00
derrod
2e57e09036 win-capture: Display compatibility information 2023-03-07 16:03:18 -05:00
derrod
0ece23dff2 updater: Bump version 2023-03-07 15:34:27 -05:00
derrod
2790e1ab1b updater: Use native WinHTTP decompression (remove zlib) 2023-03-07 15:34:27 -05:00
derrod
fc5a84ed5d updater: Use zstd for patch manifest request 2023-03-07 15:34:27 -05:00
derrod
3eff81207e deps: Remove lzma 2023-03-07 15:34:27 -05:00
derrod
f29e1fdee4 updater: Switch to Zstandard for delta updates
zstd is faster, less resource intensive, and produces smaller
files than bsdiff + LZMA.

Overall, it's a significant improvement for our workflow.
2023-03-07 15:34:27 -05:00
derrod
787c5f67a8 updater: Add Zstandard for compressed downloads
Using zstd reduces the download size for updates by about 2/3.
2023-03-07 15:34:27 -05:00
tytan652
f4e90a5bd7 obs-ffmpeg,cmake: Add a finder for AMF headers 2023-03-07 14:55:03 -05:00
tytan652
6db418fb3f obs-ffmpeg: Replace external/AMF folder by obs-deps headers 2023-03-07 14:55:03 -05:00
derrod
cb475718bd CI: Create Sparkle appcast and deltas on tag 2023-03-07 14:18:32 -05:00
gxalpha
78d195a5df UI: Make T-Bar unclickable
The T-Bar should only be draggable and not act on clicks.
2023-03-07 13:47:51 -05:00
PatTheMav
0fe28e9ceb mac-syphon: Fix warnings in ObjC code for CMake rework
Removes unused functions and explicitly casts higher-precision
CoreFramework data types into lower precision obs-module types.
2023-03-07 19:23:35 +01:00
shiina424
2eb10cd94e UI: Fix disabled text color in dark theme 2023-03-06 19:02:38 -03:00
cg2121
b464ba8129 UI: Set min/max zoom levels for preview
Prevents the preview from zooming in or out too far.
Min zoom: 10%
Max zoom: 1000%
2023-03-04 16:31:49 -08:00
cg2121
03a94aee41 UI: Fix wrong program scene if tbar is aborted
The program scene would be incorrect if the tbar was released
at its original position.
2023-03-04 16:31:37 -08:00
cg2121
6e22af932d UI: Fix preview disabled in studio mode
If OBS is set to minimize to system tray on startup and studio mode is
enabled, the preview would be disabled when showing OBS, if the preview
in non studio mode was disabled.
2023-03-04 16:24:22 -08:00
pkv
a0a23e8a18 libobs: Fix leak with empty path in stats
If the recording path is left empty in Settings, a leak can occur in
window-basic-stats.cpp because a bmalloc is called for a size 1.
This fixes the leak by checking against the path in the
os_get_free_disk_space function.

Signed-off-by: pkv <pkv@obsproject.com>
2023-03-04 16:23:07 -08:00
cg2121
290c1569a9 UI: Don't hardcode properties label colors
Makes the label have colors based on themes, instead of hard coding.
2023-03-04 16:21:01 -08:00
cg2121
a3defd4f58 UI: Fix spacing helpers when rotated and flipped
If the scene item was rotated greater than 45 degrees, and flipped
vertically or horizontally, the spacing helpers would be drawn
incorrectly. This fixes the issue by checking the scale before
the rotation, instead of after.
2023-03-04 16:18:38 -08:00
Ryan Foster
dfc8c29cea CI: Update deps to 2023-03-04 release
Notable changes:
 * deps.windows: Add Zstandard
 * deps.windows: Add nlohmann JSON
 * deps.windows: Add WebSocket++
 * deps.windows: Add Asio
 * deps.windows: Add VLC
 * deps.macos: Add nlohmann JSON
 * deps.macos: Add WebSocket++
 * deps.macos: Add Asio
 * deps.macos: Add Sparkle
 * deps.macos: Add VLC
 * deps.macos: Ready macOS deps for new CMake
2023-03-04 19:15:02 -05:00
Richard Stanway
2468268569 libobs: Hold async mutex when calling set_async_texture_size
Calling set_async_texture_size without holding async_mutex is dangerous
as cur_async_frame could be changed / freed by another thread.
2023-03-04 16:10:19 -08:00
Kurt Kartaltepe
0fb89dc9a1 obs-ffmpeg: Fix crash during ratecontrol check
When iterating over an array of structs we incorrectly check for a null
pointer, but the actual sentinel value is the empty struct.
2023-03-04 16:07:12 -08:00
Richard Stanway
bb7ca3c2c3 UI: Add mutex for writing to the log file
fstream is not thread-safe and the act of writing the string and the
newline are two separate operations which could execute concurrently in
multiple threads, resulting in lines joining together followed by two
newlines. Due to the presence of a static mutex, this also removes
inline on the function.
2023-03-04 15:34:17 -08:00
gxalpha
ffd6ae699c obs-transitions: Add long description for full decode option 2023-03-04 15:33:17 -08:00
Richard Stanway
01786a3f11 libobs: Disable encoder scaling request if it matches output size
It was possible to set the encoder to scale the video to the same size
as the output, resulting in unnecessary passes through swscale and
skipping hardware encoders. This was a common user error in Advanced
Output mode where they would tick the rescale box but leave it at the
same resolution as their main output.
2023-03-04 15:14:42 -08:00
Chris (Flaeri)
e7cd29bbe5 obs-ffmpeg: Implement QVBR for AMF encoders
Makes QVBR rate control usable. Fix wrong rate control check on line
1457. Switch from bitrate to CQ/QP value (no bitrate needed).
2023-03-03 21:48:59 +00:00