Commit Graph

3546 Commits (0a218e06b7601c0e561db518b1b5878557cd1ebc)

Author SHA1 Message Date
jpark37 ff58622df6 obs-transitions: Remove unused shader functions
Leftover from previous commit.
2022-04-23 16:24:27 -07:00
mvji 9a8e50a100 obs-transitions: Fix compiler warning
Fix unused parameter warning.
2022-04-23 16:12:45 -07:00
Norihiro Kamae c5154cc317 aja: Subtract packet time from audio timestamp
When calling `obs_source_output_audio`, timestamp should be the starting
time of the audio packet.
2022-04-23 07:04:59 -07:00
jpark37 cb42be3665 win-dshow: Respect TRC of encoded video
Fixes colors for devices that send HDR streams.
2022-04-23 07:03:35 -07:00
Jim 3883c9e120 cmake: Add option to build hardware HEVC encoders
Allows the ability to enable HEVC encoders whenever we add them.
Disabled by default for now for obvious reasons.
2022-04-22 17:39:43 -07:00
jp9000 c5e328e359 obs-ffmpeg: Refactor FFmpeg video encoders
This reduces code duplication between the different FFmpeg-based video
encoder implementations
2022-04-22 12:51:38 -07:00
mvji 2b6230ef34 win-dshow: Add YVYU format 2022-04-19 19:39:44 +02:00
mvji 93490da4c2 obs-ffmpeg: Use YVYU for FFmpeg pix fmt YVYU422
This commit also modifies deps/media-playback and libobs.
2022-04-19 19:39:22 +02:00
mvji ae94c35152 obs-ffmpeg: Add support for YUV422P10LE, YUV444P12LE, YUVA444P12LE
This commit also modifies deps/media-playback
2022-04-19 19:38:28 +02:00
Richard Stanway 4c96feafab
obs-ffmpeg: Fix compiler warning 2022-04-19 03:23:53 +02:00
jpark37 01565a0293 obs-transitions: More HDR support
Updated luma wipe, slide, and swipe.
2022-04-18 05:24:12 -07:00
jpark37 2e8ea0acdc obs-ffmpeg: Set P3-D65 metadata for HDR
Want to avoid receiver gamut remapping from Rec. 2100 to P3.

Fix min luminance appearing as NaN by switching from 0/0 to 0/1.

Also set max luminance for HLG because why not.
2022-04-17 13:44:32 -07:00
jpark37 3eb85c548f win-dshow: Add reactivation callback 2022-04-17 03:18:38 -07:00
jpark37 73f61922e6 win-dshow: Reference new device-vendor.cpp file 2022-04-17 03:18:38 -07:00
jpark37 e526f4c1fb win-dshow/libshowcapture: Toggle tonemapper according to format 2022-04-17 02:54:32 -07:00
田七不甜 94b19960e7 rtmp-services: Update Bilibili Live 2022-04-16 16:48:54 -07:00
jpark37 0d72c314d4 obs-ffmpeg: Add max luminance metadata for PQ
Necessary for video player to remap display ranges.
2022-04-16 16:26:01 -07:00
PatTheMav 6e65754862 virtualcam-module: Copy Windows virtual camera files to rundir
Fix an issue where the Windows virtual camera build files were not being
copied to the rundir.
2022-04-14 16:15:42 -04:00
jpark37 93fe82d1ce win-capture: Add DXGI/WGC HDR support
HDR for DXGI/WGC display capture, and WGC window capture.

Also add fast SDR paths for BitBlt to skip color conversions.
2022-04-14 09:36:09 -07:00
jp9000 a4c215869f obs-ffmpeg/ffmpeg-mux: Fix splitting hang on Windows
stdout on Windows from a subprocess requires that something read the
stdout buffer, and currently we don't do that. Due to newly introduced
printf/fprintf calls, the stdout buffer eventually fills up because
nothing is emptying it, thus the muxer locks up on an fprintf/printf
call and causes OBS itself to hang.
2022-04-13 14:11:20 -07:00
jpark37 d35e7d3107 win-capture: Add HDR support to Game Capture 2022-04-13 06:23:11 -07:00
jpark37 14b1d34a06 win-dshow: Use Rec. 2100 (PQ) by default for P010 2022-04-12 12:02:43 -07:00
mvji 19defbcf04 obs-ffmpeg: Add mxf extension to open file dialog 2022-04-12 12:11:44 -04:00
Jim b745a100a3
Merge pull request #5371 from norihiro/automatic-file-splitting
Automatic file splitting
2022-04-10 16:49:37 -07:00
jpark37 a63d353463 win-dshow: Add Rec. 2020 HLG support
Also rename "Partial" range to "Limited" range for consistency.
2022-04-10 12:55:02 -07:00
jpark37 a59713eaaa obs-filters: Add HDR support to Scaling filter 2022-04-10 12:54:21 -07:00
jpark37 59dbc3eb81 libobs: Rename Rec. 2020 to Rec. 2100
Rec. 2020 is really an SDR spec, but I think HDR10 made it okay to slap
PQ on it, call it an HDR spec. Rec. 2100 came along after and formally
allowed the use of PQ/HLG, so we should use 2100 instead.
2022-04-10 00:13:52 -07:00
Georges Basile Stavracas Neto 3d7663f417 linux-pipewire: Explicitly enumerate portal capture types
This is very much like previous commit, but there's a catch: there
already was an enumeration in place, which is replaced in this
commit. The obs_pw_capture_type enum was introduced before splitting
the portal code into a separate file, and the enum itself is specific
to the screencast portal, so the appropriate place to enumerate it
is in portal.h.

For completude, PORTAL_CAPTURE_TYPE_VIRTUAL was added to the enum,
even though we never used, and probably never will.

The values are still the same, since both the old and this new enum
were extracted from the screencast portal [1].

https://github.com/flatpak/xdg-desktop-portal/blob/main/data/org.freedesktop.portal.ScreenCast.xml#L290-300
2022-04-09 16:45:02 -07:00
Georges Basile Stavracas Neto e7815dff66 linux-pipewire: Explicitly enumerate cursor modes
The ScreenCast portal defines 3 cursor modes [1]:

 * Hidden: no visible cursor (value: 1)
 * Embedded: cursor is drawn in the frames (value: 2)
 * Metadata: cursor is sent as stream metadata (value: 4)

The values are power-of-two due to be used as flags.

Explicitly listing these values in an enum improves legibility
of the code, so do that instead of hardcoding 1, 2, and 4.

[1] https://github.com/flatpak/xdg-desktop-portal/blob/main/data/org.freedesktop.portal.ScreenCast.xml#L302-L316
2022-04-09 16:45:02 -07:00
Georges Basile Stavracas Neto 1267081e5c linux-pipewire: Move fetching cursor mode to portal.c
The portal.c file was introduced after the PipeWire code landed, and
handles acquiring a D-Bus connection to the portal interface, and also
has helpers to get properties from portals. The available cursor modes
property fits nicely in portal.c.

Move fetching the cursor mode to portal.c.
2022-04-09 16:45:02 -07:00
Georges Basile Stavracas Neto 2534e549f9 linux-pipewire: Remove ellipses from log messages
Ellipses in log messages bring a tone of vagueness and insecurity
that does not match the geist of the OBS Studio community. We're
a bold, industry-leading community producing software that is at
the heart of the biggest services of today's world. When it comes
to PipeWire and Wayland adoption, we're quite literally the app
that protocols and portals are designed for.

Therefore, it is unacceptable that the log messages in the PipeWire
capture don't communicate how strong of a community we are. Not
only that, these ellipses bring harm on the long run. After all,
who on their right mind would design protocols, portals, and user
interactions for an app that doesn't even log their messages in
accordance to its community values?

Our logs must shout strength. They must reflect that OBS Studio
is here to stay. Readers of such logs must fasten their seatbelts
before opening these files. Competition tremble with dread and
fear when presented with these logs. Only extreme metal singers
should be able to read these logs out loud.

No compromise.

Remove ellipses from PipeWire log messages.
2022-04-09 16:45:02 -07:00
Georges Basile Stavracas Neto 25fe22a489 linux-pipewire: Properly capitalize log messages
They are inconsistently capitalized, some with sentence capitalization,
some completely lower-cased.

Capitalize all log messages using sentence capitalization.
2022-04-09 16:45:02 -07:00
Georges Basile Stavracas Neto 6216f4555b linux-pipewire: Log more PipeWire-related info
The information that we currently log is not enough to give proper
support, and at best allows us to know that the first few steps of
negotiation worked.

Transform a few key debug messages into infos.
2022-04-09 16:45:02 -07:00
jpark37 848e128435 libobs,plugins: Replace video matrix function
video_format_get_parameters_for_format provides a more accurate matrix
than video_format_get_parameters.
2022-04-07 19:28:51 -07:00
Joshua Ashton 9903d73f36 linux-capture: Don't initialize format info if init_obs_pipewire fails
The pointer has been freed by this point so it just segfaults.

Signed-off-by: Joshua Ashton <joshua@froggi.es>
2022-04-07 08:41:19 -03:00
wangshaohui db8145e8a2 obs-ffmpeg, win-dshow, deps/media-playback: Use recommended API for AVCodecContext 2022-04-07 01:59:30 -07:00
jpark37 d641ab12f7 win-capture: Use normal blend equation for cursor
Not sure what the previous setup was trying to do. I guess we'll find
out if users complain.
2022-04-07 01:51:15 -07:00
jpark37 433eef5910 obs-transitions: Smooth source transition fades
Add logic to avoid unexpected deviation.
2022-04-07 01:49:57 -07:00
karenkim-AfreecaTV 42c7e29d25 rtmp-services: Update AfreecaTV
Add Brazil server
2022-04-07 01:48:22 -07:00
jpark37 6e4ed48188 obs-transitions: Add HDR support to cut/fade
Both transitions are capable of passing through HDR sources now.
2022-04-06 17:33:53 -07:00
jpark37 e2b0ccdd22 obs-transitions: Add effect files to VS solution 2022-04-06 17:33:53 -07:00
jpark37 a00d53eccf win-dshow: Add HDR support 2022-04-03 00:03:34 -07:00
jpark37 4c2aa58dbe obs-ffmpeg: Support Rec. 2020, I010/P010 formats
Also remove unused function, ffmpeg_to_obs_video_format.
2022-04-03 00:03:34 -07:00
Paul Hindt 743f540fa1 aja: Use correct colorspace for SD or HD/UHD
Set video range to VIDEO_RANGE_PARTIAL
2022-04-02 16:23:21 -07:00
jpark37 083034bb0a obs-filters: Fix scale undistort, attempt two
Undistort checkbox should be ignored if bilinear lowres effect is used.
2022-04-02 16:22:59 -07:00
Kurt Kartaltepe bf660b1d8d linux-pipewire: Version check call to pw_deinit
Per upstream this function is not supposed to be called by users of
PipeWire, and will crash when called twice. Instead only call it on
recent versions of PipeWire where it is safe to call.

This also removes the nearly empty pipewire-common files.
2022-04-02 12:45:39 -03:00
Patrick Heyer 3c1d7aeb86
Merge pull request #6245 from PatTheMav/cmake-resource-fix
win-capture: Fix added resources not properly copied to rundir
2022-03-31 11:52:50 +02:00
PatTheMav d42c98fa22
win-capture: Fix added resources not properly copied to rundir
The `add_target_resource` function uses unnecessary path components
when copying files to the rundir, resulting in files added that way
not to end up where OBS expects them to.

The generated binaries created by sub-targets also need to be copied
as part of `win-capture`'s data files, which was easy to fix as the
target exists before CMake switches into the subdirectories.
2022-03-30 11:10:54 +02:00
striphat-dev 8360893730 rtmp-services: Update Stripchat streaming service 2022-03-29 19:55:44 +02:00
jpark37 a014137ff1 obs-filters: Fix invalid scale filter combination
Undistort checkbox should be ignored if bilinear lowres effect is used.
2022-03-26 13:01:01 -07:00
PatTheMav aae3a6a466 cmake: Fix diverging prefix padding for OBS status outputs
Status output related to OBS configuration is prefixed with the string
"OBS" and added padding for enabled and disabled features. This padding
was not aligned between platforms.

By moving the padding and prefix decoration into its own function,
both elements are controlled in a single place. CMake scripts were
changed to use this new function `obs_status` instead of using CMake's
`message` function directly.
2022-03-26 09:44:23 -04:00
Norihiro Kamae ba68eda590 obs-ffmpeg: Use av_packet_alloc instead of av_init_packet
sizeof(AVPacket) being a part of the public ABI is deprecated. once
av_init_packet() is removed, new packets will only be able to be
allocated with av_packet_alloc().
In ffmpeg-mux, ffmpeg-vaapi, and obs-ffmpeg-nvenc, AVPacket is allocated
at the initialization to avoid frequent allocation of AVPacket.

Includes changes to win-dshow.
2022-03-24 17:19:40 -07:00
Richard Stanway 85addc3dac UI, file-updater, rtmp-services: Enable curl ALPN support
In the years since this code was added, ALPN is now widely supported,
and NPN is being removed entirely in the latest version of nginx. It's
time to start using ALPN!
2022-03-24 17:10:01 -07:00
Ryan Foster ae3570a741 rtmp-services: Fix file mode
Revert file mode changes from 99afbc687e.
2022-03-23 12:44:49 -04:00
vasuais 99afbc687e rtmp-services: Update SharePlay.tv recommendations 2022-03-23 09:16:23 -07:00
Georges Basile Stavracas Neto a147315f33 project: Migrate PipeWire capture into linux-pipewire
The capture ids are preserved, so that it's compatible with the
previous code. No code changes were necessary whatsoever.
2022-03-20 20:53:39 -03:00
columbarius ebe8f6c72a linux-pipewire: Create new plugin
This plugin should contain different plugins importing and exporting
multimedia streams via PipeWire.
2022-03-20 20:53:39 -03:00
pkv c8b2db9760 obs-libfdk: Set bitstream to ADTS for mpegts output
This sets the aac bitstream to ADTS for the mpegts output.
This fixes a bug with mpegts ouput where the avformat muxer issues
an error with fdk-aac encoder.

Signed-off-by: pkv <pkv@obsproject.com>
2022-03-19 15:25:02 -07:00
vasu 7dcd22dc95 rtmp-services: Add Shareplay.tv 2022-03-18 14:21:14 -07:00
tytan652 7d07b57993 obs-outputs,librtmp: Remove encrypted RTMP support
RC4 and Diffie-Hellmann Key related codes are removed
2022-03-18 13:34:03 -07:00
tytan652 179ad9e67b librtmp: Add mbedtls 3 compatibility
Since Mbed TLS 3 doesn't support RC4 algorithm,
encrypted RTMP is disabled if OBS is built with
the version 3 or later of Mbed TLS.
2022-03-18 13:34:03 -07:00
Richard Stanway 9170e0a9b1
obs-qsv11: Fix double free on CreateSurface failure
_dx9_simple_free already frees this pointer. I don't think this code
path is currently reachable, but it should probably still be fixed.
Detected by Coverity Scan.
2022-03-18 18:11:24 +01:00
PatTheMav f3e23c2332
obs-vst: Update submodule to pull in CMake changes 2022-03-17 14:28:59 +01:00
PatTheMav ab021ff3bf
obs-browser: Update submodule to pull in CMake changes 2022-03-17 14:28:34 +01:00
PatTheMav 49e9d49943
plugins: Update CMakeLists.txt for included plugins 2022-03-16 23:11:08 +01:00
jpark37 2a991a4fa0 win-waspai: Tighten version check for RTWQ
Getting reports that it isn't working for 1607 and below.

If they continue, we should probably just pull the RTWQ path.
2022-03-13 06:07:39 -07:00
eightball567 6df5a98534 mac-capture: Add vbcable to whitelist for loopback devices 2022-03-12 15:41:06 -08:00
Florian Zwoch 8886091793 obs-ffmpeg: add NVENC blacklist check for Linux
Similar to the Windows counter part. Check the PCI bus for
installed cards. When found at least one VGA compatible adapter
from NVIDIA that is not in the blacklist we pass the check.
2022-03-08 12:16:07 -08:00
cg2121 efce0f41d0 decklink: Use ComPtr for variables
This makes sure Decklink variables are automatically released.

Closes https://github.com/obsproject/obs-studio/pull/5508
2022-03-08 03:36:01 -08:00
jpark37 c7c52a59f9 win-dshow: Fix hwdevice_ctx leak 2022-03-05 15:02:23 -08:00
jp9000 490c6214f0 virtualcam-module: Revert changes since 27.1.3 (for now)
This reverts commit 4b0767741a,
3f3f9ed7e6,
0e7c17bd6e, and
865eecb739.
2022-03-02 17:35:36 -08:00
jp9000 4b0767741a virtualcam-module: Prevent placeholder memory leak 2022-03-02 05:06:12 -08:00
jp9000 2026270b65 virtualcam-module: Only initialize placeholder once 2022-03-02 05:06:12 -08:00
jp9000 3f3f9ed7e6 virtualcam-module: Fix incorrect correct res/fps
Apparently the testing that was done was not sufficient enough or did
not check all test cases, so resolution/fps does not get set properly on
the virtualcam.
2022-03-02 04:19:02 -08:00
Matt Gajownik 7409496c14 obs-browser: Log CEF version *after* library is loaded on macOS 2022-02-28 23:24:52 +11:00
jp9000 0e7c17bd6e virtualcam-module: Remove unnecessarily inlines 2022-02-27 22:26:10 -08:00
jp9000 865eecb739 virtualcam-module: Stop thread on Stop call
This causes the thread to only start when the IMediaFilter::Run/Pause
calls have been made, and stop whenever either the IMediaFilter::Stop
call has been made, or on destruction, whichever comes first.

This potentially will work around a suspected race condition that
appears to be in the WebRTC library where the filter's library will be
released while the filter is in the process of being destroyed, which
can take longer than usual if the join takes too long. Basically, fixes
a reported crash (that doesn't appear to technically be our fault) when
the filter is used with browsers when the virtualcam is deactivating in
web browsers.
2022-02-27 22:23:41 -08:00
jpark37 847eebc648 win-dshow: Fix wrong AVCodecContext free call 2022-02-27 04:38:30 -08:00
jpark37 2e1d9e8e64 win-dshow: Add hardware decode status to log 2022-02-27 02:40:09 -08:00
Matt Gajownik fe71841b5a obs-browser: Update version to 2.17.14
f3d7a4d - Display runtime version (not built version) in UA string
f93675c - Print both runtime & compile version of CEF on startup
2022-02-27 17:22:05 +11:00
Justin B. Watson 24b2ad8532 rtmp-services: Update Brime Live ingests 2022-02-27 02:06:54 +01:00
cg2121 8510731f2b decklink: Don't load modules if Decklink not found
This also modifies decklink-captions and decklink-output-ui.
2022-02-26 15:44:00 -08:00
obiwac 93c2e681ca linux-v4l2: scandir with alphasort on non-Linux
Sort video device entries with `alphasort` on non-Linux platforms,
as opposed to `versionsort` on Linux.
(`versionsort` is a GNU extension, unavailable on e.g. FreeBSD.)

UI: Fix call to `to_string` on FreeBSD
2022-02-26 15:36:08 -08:00
jpark37 42fad9b2b4 win-dshow: Add hardware decode toggle
Off by default because it can be buggy, or overburden the GPU.
2022-02-26 15:31:48 -08:00
Ryan Foster ebc514e8db obs-ffmpeg: Update nv-codec-header files
Update the in-tree nv-codec-header files (nvEncodeAPI.h and
dynlink_cuda.h) to n11.1.5.1, which is the version currently used in the
OBS Studio dependencies, to keep the in-tree version in sync with the
version in our dependencies.
2022-02-26 15:08:03 -08:00
Kurt Kartaltepe c639255142 linux-v4l2: Fix warnings in mjpeg
Previously the switch did not catch all cases issuing a quite large
warning. Also there was a const-ness warning for codecs on ffmpeg 5.0
that this addresses.
2022-02-25 12:22:22 -03:00
Richard Stanway 702df3cd8d win-wasapi: Fall back to old code if RTWQ fails
Fixes a crash if RTWQ is unavailable, e.g. if the mmcss service is not
running.
2022-02-24 19:28:19 -08:00
jp9000 0dbae4ebef win-dshow: Ensure thread is joinable before joining
This may have been the issue behind the reported firefox crashes, but
strangely, the thread should always be joinable here because it's
explicitly always created in the constructor and joined in the
destructor.
2022-02-23 04:13:38 -08:00
Richard Stanway a39d174100 obs-outputs: Set a fixed size socket buffer on Windows 7
Auto tuning apparently doesn't work very well on this version and
af6844f5c2 caused throughput
regressions.
2022-02-20 16:16:17 -08:00
jp9000 3ca0bf8c0e obs-browser: Add support for custom OBS CEF
Our version fixes the system freeze issue, reduces resource usage, and
improves performance back to 3770 levels.

See obsproject/cef@36fdac16a7 for detailed information.
2022-02-20 11:43:55 -08:00
jp9000 b6b696fd89 obs-browser: Fix texture recreating every frame 2022-02-19 22:52:19 -08:00
Kurt Kartaltepe 23feac1323 linux-v4l2: Use decoded MJPEG pixel format
Previously we assumed mjpeg was always decoded to 422 but it seems some
cameras provide frames that decode to different pixel formats such as
420.

This change delays setting the obs frame pixel format until after we
have decoded the v4l2 frame.

fixes #5821
2022-02-19 23:53:41 -03:00
Matt Gajownik 02f80a1013 win-wasapi: Only enable work queue on Windows 10+
Fixes #5967
2022-02-19 15:37:50 -08:00
jpark37 6eec19771a obs-filters: Reduced GPU work for common LUT cases
Add "Passthrough Alpha" checkbox where alpha doesn't need sanitization.

Remove domain checks, Intel UHD Graphics 750: 591 µs -> 532 µs
Alpha passthrough, Intel UHD Graphics 750: 532 µs -> 486 µs
2022-02-19 15:29:48 -08:00
jpark37 873e3a0aae obs-filters: Reduce 3D LUT calculations
Single tap is good enough.

Intel UHD Graphics 750: 860 µs -> 591 µs
2022-02-19 15:29:48 -08:00
jpark37 8e8c29d84c obs-filters: Interpolate LUT in linear space
More accurate and cheaper.

This is a breaking change because Amount is also now computed as linear,
but most users are probably using 1.0, so v2 isn't worthwhile.

Intel UHD Graphics 750: 980 µs -> 860 µs
2022-02-19 15:29:48 -08:00
jpark37 c434d4d39b obs-filters: Update original.cube
Need more LUT entries to reduce error when shader is optimized.
2022-02-19 15:29:48 -08:00
jpark37 ca3fdd8eaf obs-filters: Add effect files to VS solution 2022-02-19 15:29:48 -08:00
pkv 5b0c09a9f4 obs-ffmpeg: Force mpegts format & disable restart on activate for srt & rist
This fixes crashes in media Source when :
- the user forgets to set the input format for srt or rist URLs;
- disabling / enabling / disabling etc Media source with a rist URL.

Signed-off-by: pkv <pkv@obsproject.com>
2022-02-19 15:17:19 -08:00
Florian Zwoch d16950a2f6 linux-capture: Fix for pipewire capture leaking texture handles
Enter the graphics context before calling gs_texture_destroy() or
else the call will fail causing the texture handles to leak.
2022-02-19 20:06:03 -03:00
jp9000 ab1d20b237 obs-browser: Fix issues with rendering on Linux/macOS 2022-02-19 10:18:48 -08:00
jp9000 ddf1078e32 obs-browser: Fix rendering on non-windows
The copy operation wasn't supposed to be in the #ifdef for windows.
2022-02-19 09:18:36 -08:00
jp9000 6a3043abd2 obs-browser: Fix sRGB rendering 2022-02-15 23:51:07 -08:00
jp9000 40b990a559 obs-browser: Update version to 2.17.10 2022-02-15 23:19:17 -08:00
jp9000 ee878043b2 obs-browser: Acquire, copy, and release immediately
Instead of holding onto an acquire over the duration of an entire frame,
acquire, copy to a texture, and immediately release the lock.

(Note from Jim: When it comes to synchronization, the idea of acquiring
a lock, and then releasing all the way in the next frame just feels a
bit worrisome. Especially when it's a GPU object. But at this point, I'm
just making shots in the dark in an attempt to eliminate any possible
things that might even have a remote chance to trigger latent bugs in a
GPU driver or the kernel. You know, that whole system freeze thing. This
probably doesn't have anything to do with it, at this point I have
nothing but wild geese to chase. Whatever.)
2022-02-15 23:12:20 -08:00
Thulinma 9c504f4d35 rtmp-services: Update Picarto ingests 2022-02-12 15:02:10 -08:00
Translation Updater 25b58f0417 Update translations from Crowdin 2022-02-11 00:34:08 +00:00
jp9000 109b54fd66 obs-ffmpeg: Fix svt-av1 rate control settings
For SVT-AV1, rate control is explicitly set via an "rc" option, so set
those options manually for SVT-AV1. CBR doesn't seem to be fully
supported, but it's sort of supported via CVBR (constrained variable
bitrate), which seems to be specific to each GOP size, which is about as
close to CBR as we can get.
2022-02-07 13:11:34 -08:00
Translation Updater ac8dbf67be Update translations from Crowdin 2022-02-06 02:24:08 +00:00
Cenk Uluisik f52f34b614 linux-capture: Fix missing parameter for pipewire capture
Commit a3a6710 introduced the obs_pipewire_save() function in the
PipeWire code, but only set it to the monitor capture source. This
was an oversight, it should have been set to the window capture
source as well.

Set the .save vfunc of the window capture source as well.

Closes obsproject/obs-studio#5906
2022-02-04 13:09:12 -03:00
Paul Hindt 95020dd629 aja: Fix off-by-one output frame index calculation 2022-02-02 11:20:05 -06:00
Roman Sivriver e6a55e7763 rtmp-services: Update YouNow ingest 2022-02-01 13:42:08 -08:00
Matt Gajownik 3aa90f7076 obs-transitions: Fix All Files option for Stingers
On Windows, All Files was added by default with (*), but on macOS and
Linux this appeared as an empty option in the dropdown and treated as a
Video Files filter rather than All Files.

This also adds proper translation handling for 'Video Files', matching
the obs-ffmpeg-source.

Fixes #5870
2022-01-29 19:53:31 -08:00
Jim 3e4e8d2fd0 vlc-video: Set channel limit to 8 instead of 2
17c069e1d0 changed to add support for surround sound, but the limit
should really just be 8 channels as pointed out by tt
2022-01-29 15:28:36 -08:00
Francisco Oltra 5f5355a813
rtmp-services: Update nanoStream Cloud / bintu ingests (#5884)
* rtmp-services: Update nanoStream Cloud / bintu ingests

 - fix transcoding rtmp urls
 - add information and dashboard links
2022-01-29 15:24:46 -08:00
pkv 17c069e1d0 vlc-video: Enable surround sound support
The vlc plugin was keeping only up to two audio channels. It was overlooked when surround sound support was added to obs-studio. This commit remedies this oversight.

Signed-off-by: pkv <pkv@obsproject.com>
2022-01-29 15:22:29 -08:00
Chris 306e23292d win-dshow: Log buffered state 2022-01-29 15:14:58 -08:00
jpark37 9f41531541 win-dshow: Use OBS_SOURCE_FRAME_LINEAR_ALPHA
This flag leads to a cheaper technique, "Draw" instead of
"DrawNonlinearAlpha", and all the paths are opaque anyway.
2022-01-29 15:10:53 -08:00
Matt Gajownik 364f102561 obs-browser: Fix Windows crash if shared texture is unavailable 2022-01-29 18:05:25 +11:00
Paul Hindt 29b835b20f aja: Disable Analog In/Out selections in the UI
Analog capture/display for supported cards will be added in the future.
2022-01-28 23:58:53 -06:00
Paul Hindt ba875377d0 aja: Fix Kona1 simultaneous capture/output 2022-01-28 20:23:40 -06:00
Paul Hindt 3fbd5d9179 aja: Adjust whitespace for consistency 2022-01-28 20:23:40 -06:00
Paul Hindt 8d051c6a1c aja: Use SDI Transport selection to engage Auto detection
Otherwise use Video and Pixel format selections to engage Auto detection for HDMI
2022-01-28 20:23:40 -06:00
Paul Hindt 0ef3b29cad aja: Show/Hide SDI Transport/4K lists and options
Only show SDI Transport options if IOSelection is SDI and

only show 12G selection in Capture plugin
2022-01-28 20:23:40 -06:00
Paul Hindt f559287723 aja: Fix 2xSDI UHD/4K YCbCr 2SI VPID lookup 2022-01-28 20:23:40 -06:00
Paul Hindt 0d15bb0b94 aja: Hide duplicate HDMI IN entry for Kona HDMI 2022-01-28 20:23:40 -06:00
Paul Hindt a4c0996d59 aja: Filter 6G/12G SDI Transport depending device/plugin type 2022-01-28 20:23:40 -06:00
Paul Hindt d2515170e1 aja: Disable UHD/4K high-framerate for Output
A fix for UHD/4K HFR modes will be added in a future plugin release.
2022-01-28 20:23:40 -06:00
Paul Hindt 5f81d4117f aja: Clear previous crosspoints when signal changes
Fix for a bug where stale crosspoint connections could result in

video glitches upon next connection.
2022-01-28 20:23:40 -06:00
Paul Hindt d18b805aee aja: Remove unfinished 2x4K Squares support
Support for 2x4K Square Division will be added in a future update
2022-01-28 20:23:40 -06:00
Paul Hindt eafe588bd3 aja: Re-work HDMI routing and add missing presets 2022-01-28 20:23:40 -06:00
Paul Hindt 4650cf4574 aja: Fix HDMI RGB crosspoint indices 2022-01-28 20:23:40 -06:00
Paul Hindt 71e3fcc5de aja: Add framestore index helpers to Source/OutputProps 2022-01-28 20:23:40 -06:00
Ryan Foster 5bbb36acf8 mac-vth264: Set RealTime property to False
While the Apple documentation currently seems to indicate that we should
set RealTime to True, it appears that this may be causing issues with
the encoder not being able to meet the target frame rate. Both FFmpeg
and Handbrake have recently explicitly set this value to False, and
preliminary tests seem to indicate that setting this to false in OBS has
favorable results.
2022-01-28 11:35:50 -08:00
Ryan Foster 6360b2e425 mac-vth264: Use float for expected frame rate
The encoder property kVTCompressionPropertyKey_ExpectedFrameRate is a
hint to the video encoder. Since frame rates can be fractional, let's
use a float here instead of an int.
2022-01-28 11:35:50 -08:00
Ryan Foster 63eb2d1c31 mac-vth264: Remove OSX 10.8 compatibility code
OBS no longer supports building on OSX. The minimum version of macOS
that we support is macOS 10.13. We can safely remove this 10.8
compatibility code.
2022-01-28 11:35:50 -08:00
jp9000 c2b1f93a7b obs-vst: Fix VSTs losing their settings when upgrading 2022-01-26 08:12:04 -08:00
derrod 8367c8adfa obs-ffmpeg: Add MX450 to blacklist 2022-01-25 16:46:55 +01:00
Jim b3b4e1b2ef
Merge pull request #5860 from obsproject/deprecate-addref
Deprecate addref for obs objects
2022-01-25 05:55:52 -08:00
Colin Edwards 99fe09e706 aja: Remove inter-plugin debug logging 2022-01-24 22:00:02 -06:00
Jim 404ebdbd51 mac-syphon: Replace source addref calls with get_ref 2022-01-24 14:06:50 -08:00
Jim ad6cb5a8be image-source: Replace source addref calls with get_ref 2022-01-24 14:06:50 -08:00
jp9000 0dd5d93d42 obs-ffmpeg: Add new SVT presets
Don't worry, these preset names are just placeholders for now
2022-01-23 14:57:27 -08:00
jp9000 b9599fed2d obs-browser: Suppress certain warnings 2022-01-23 08:52:15 -08:00
Matt Gajownik 5c07cc12b2 obs-vst: Fix formatting, fix size truncation warning
31c2fc6 - Fix size truncation warning for silenceChannel
7e53139 - Fix formatting
2022-01-23 21:27:59 +11:00
jpark37 63a6534966 win-capture: Fix parameter mismatches
Fix missing HWND argument type, and use DWORD based on MS sample.
2022-01-23 20:39:54 +11:00
Christine Lin 2474775f40 obs-qsv11: Fix memory leak in QSV plugin module 2022-01-22 15:30:36 -08:00
Matt Gajownik 7c84fb49bc obs-vst: Fix closing & resizing VSTs on macOS
* 2b2f15f - Don't disable VST close button on macOS
* 95d81a3 - Fix resizing most VSTs on macOS
2022-01-22 19:07:16 +11:00
Matt Gajownik 00232e6b98 obs-vst: Fix mvMeter2 resize crash, fix SPAN resizing 2022-01-22 13:14:02 +11:00
Paul Hindt 57d1619c8d aja: Fix UHD/4K YCbCr 3G Level-B 2SI preset 2022-01-21 11:58:29 -06:00
Matt Gajownik 838986006b obs-browser: Update version to 2.17.8
* 9dbaed4 - Revert "Fix debug builds for CEF >= 4430 on Windows"

This fixes a crash when loading browser docks in Debug mode.
2022-01-21 20:21:18 +11:00
Paul Hindt a59f6c4e50 aja: Fix crash when capture thread is reset 2022-01-19 11:18:26 -06:00
Paul Hindt 04bf12f130 aja: Workaround for SDI5 output not working on io4K+ 2022-01-18 20:50:37 -06:00
Matt Gajownik a59286f6b5 obs-browser: Fix compilation on non-Windows 2022-01-19 13:20:27 +11:00
Matt Gajownik 35ca19bf68 obs-browser: Update version to 2.17.7
* 7ef33d5 - Allow resizing without recreate
 * 16be8b6 - Fix showing stale frames on show
 * 03942a8 - Fix sources not rendering after hide/show
2022-01-19 11:47:53 +11:00
Matt Gajownik fa35fd0f55 win-capture: Don't list minimized UWP apps 2022-01-18 03:42:27 -08:00
AuroraWright e58421342c mac-vth264: Fix DTS timestamps when blank 2022-01-18 03:02:15 -08:00
Richard Stanway d458780f02
win-capture: Use stack buffer for small window titles
Avoids expensive malloc calls that might also contribute to excessive
heap fragmentation.
2022-01-18 01:58:45 +01:00
Richard Stanway ecf8c1239d
win-capture: Make open_process_proc static
Seems like the original intention and avoids repeatedly calling
GetProcAddress. Detected by PVS Studio.
2022-01-18 00:00:10 +01:00
Richard Stanway 1af1a432e2 text-freetype2: Fix incorrect fread argument order
This fixes UTF-16 BOM files being loaded incorrectly and having their
newlines parsed incorrectly in read from end mode. Detected by PVS
Studio.
2022-01-17 23:40:48 +01:00
Paul Hindt 9728345bf4 aja: Fix signal routing for 4xSDI UHD/4K RGB 3Gb
Crosspoint indices were wrong for the UHD4K_ST425_Quad_3Gb_Squares_RGB_Capture preset and VPID was not being set for the selected 3G-Level B transport mode.
2022-01-15 15:30:58 -06:00
Paul Hindt 9c9efcd04d aja: Fix erroneous HDMI input selection for certain cards 2022-01-15 15:29:39 -06:00
Paul Hindt 3e07c29ec3 aja: Rename IOSelection strings for HDMI and Analog 2022-01-15 15:29:39 -06:00
Paul Hindt 87ce26cfca aja: Fix Kona1 not auto-detecting capture pixel format 2022-01-15 15:28:16 -06:00
Ryan Foster a7d3df3763 linux-v4l2: Fix timeout logging
The timeout_usec variable is uint64_t, but the log format was set to %ld
(signed long int), so it would sometimes log a nonsensical value. Let's
use $PRIu64 instead, which should be equivalent to %llu (unsigned long
long int).

Fixes #5797.
2022-01-14 20:43:25 -08:00
Richard Stanway 42fc705333 obs-filters: Fix incorrect format string
Detected by PVS Studio.
2022-01-15 00:17:02 +01:00
Paul Hindt cb51c974f4 aja: Fix Kona5/io4K+ 6G/12G-SDI routing and RGB HD-DualLink routing 2022-01-13 13:12:47 -06:00
Paul Hindt 8f8b522ca7 aja: Fix for invalid default settings and empty cardID string 2022-01-13 13:11:51 -06:00
Matt Gajownik cdb5b6e812 obs-vst: Fix crashes due to unhandled events, fix stutter when loading
* 106868e - Improve lock for effect object
* 566c213 - Handle more VST events to avoid crashes
2022-01-13 19:09:29 +11:00
Vainock 4e8fbb8f77 obs-ffmpeg: Fix spelling mistake for 'Encoder.Timeout' 2022-01-12 07:33:04 -08:00
gxalpha 723d5a2163 obs-ffmpeg: Add missing "FFmpegOpts" locale 2022-01-12 21:48:38 +11:00
Paul Hindt 1cbf9421d4 aja-output-ui: Add the Multi View UI options for new device. 2022-01-11 17:28:05 -06:00
tytan652 9d02ca0fef aja: Fix format-security warning
On some Linux distributions -Werror=format-security is set when
building package keeping OBS Studio from being built with AJA
plugins.
2022-01-11 20:40:03 +11:00
Matt Gajownik 046d98d871 obs-vst: Fix crashes when switching VSTs, and large channel counts
* 0f6470c - Fix crash with plugins using large channel count
* 9cdde97 - obs-vst: Check hash before applying "chunk_data"
2022-01-11 10:41:57 +11:00
Matt Gajownik 1989391bfc obs-browser: Update version to 2.17.6
* 26dc85e - Add obs-websocket 5.0.0 integration
2022-01-11 10:40:26 +11:00
Matt Gajownik 3900ae0974 libdshowcapture: Add P010 support 2022-01-11 10:40:01 +11:00
Paul Hindt f09137a2e0 aja: Refactor, clean-up and fix bugs in the signal routing system, and add SDITransport UI option to assist signal routing. 2022-01-08 14:05:10 -06:00
pkv d78971b4db obs-ffmpeg: Further FFmpeg deprecations fixes for FFmpeg 4.4+
avcodec.h stopped including channel_layout.h per FFmpeg commit
1be3d8a0cb77 [1]. Fixes compilation error on macOS against
FFmpeg later than the mentioned commit.
[1] 1be3d8a0cb
2022-01-08 18:18:27 +11:00
Tatsuyuki Ishi b684e01aad linux-capture: Disable strict binding for NVIDIA drivers
NVIDIA drivers appears to have a bug where binding would be excessively
slow. Apply a workaround similar to what [KWin] does to prevent the issue.

Also performs a refactor so that the code paths with and without the
workaround can be shared.

[KWin]: 4f2c3a00c4/src/libkwineffects/kwinglplatform.cpp

Fixes: 316f858c6 ("linux-capture: Fix capturing on software rasterization setups")
Closes: https://github.com/obsproject/obs-studio/issues/5685

Tested-By: univrsal <uni@vrsal.xyz>
2022-01-07 15:21:09 -08:00
Matt Gajownik 5defdaf1db obs-vst: Fix resizing, always use source name in window title
425935a - Fix VST plug-ins disappearing when resized
2e90d23 - Correctly use source name (not target) for window title
2022-01-07 23:48:06 +11:00
jp9000 dfaccd1e3a obs-ffmpeg: Fix av1 encoding with fractional framerates
Just use util_mul_div64 instead of using av_rescale_q_rnd
2022-01-04 22:48:10 -08:00
Matt Gajownik da5fc10a8b obs-browser: Update version to 2.17.5
* Get and log Chromium build version
* Fix debug builds for CEF >= 4430 on Windows
* Fix unused-parameter warning
2022-01-04 22:46:23 +11:00
Georges Basile Stavracas Neto a200001d2a linux-capture: Standardize gs_color_format variable names
Name them all to 'gs_format'. We need to be a bit strict with
naming here, since we're dealing with 3 format namespaces (OBS,
PipeWire, and DRM).
2021-12-30 18:41:04 -03:00
Georges Basile Stavracas Neto 64bb5a0974 linux-capture: Unify format lookups
Merge all format lookup functions into a single one, with all
out parameters optional.
2021-12-30 18:41:04 -03:00
Georges Basile Stavracas Neto f0026142f0 linux-capture: Move supported formats into a static table
We've been listing the supported formats in place whenever we
needed so far, but now we're doing it in too many different
places, which is getting confusing.

Move all these sparsely written rules into one single table
of formats, and adjust the code to lookup data on it.
2021-12-30 18:41:04 -03:00
Georges Basile Stavracas Neto d876e735e0 linux-capture: Split array into two variables
Split the 'f' array in two named variables, and move one of
these variables to the appropriate context where its used.

No functional changes.
2021-12-30 18:41:04 -03:00
Georges Basile Stavracas Neto 52a3a8817d linux-capture: Add preferred value out of the loop
Choice pods are built with the first element being the
preferred choice, followed by a list of possible choices.

We add the preferred choice inside the loop, which makes
the code slightly harder to follow.

Factor this out of the loop, into a separate step.
2021-12-30 18:41:04 -03:00
Georges Basile Stavracas Neto 37ba341d3a linux-capture: Rename a variable
'modifierless' is a bit non-descriptive given the lack of a
verb in the variable name. Rename it to 'use_modifiers', and
swap the logic.
2021-12-30 18:41:04 -03:00
Matt Gajownik 7c50621e15 obs-browser: Update version to 2.17.4 2021-12-29 16:55:23 +11:00
Richard Stanway af6844f5c2 obs-outputs: Only log SO_SNDBUF on RTMP socket
From Windows 7 onwards, dynamic send buffering is enabled. By setting
SO_SNDBUF explicitly, we actually disabled the dynamic send buffering
feature which results in reduced throughput. Thankfully this did not
affect the majority of users since the default send buffer is usually
already 64k.

This commit replaces the setting of SO_SNDBUF with log output showing
the current value of SO_SNDBUF at stream start and end. This will aid in
debugging throughput issues caused by a buffer that isn't big enough,
perhaps as a result of the user disabling dynamic send buffering
system-wide.
2021-12-27 14:29:43 -08:00
jp9000 006fdd2be5 Revert "obs-filters: Remove duplicate color correction code"
This reverts commit 6940495e79d6313f61e9c73a0bb75b078810f118.
2021-12-25 17:10:44 -08:00
jp9000 c16f27d269 Revert "obs-filters: Remove duplicate code from color key filter"
This reverts commit a4045ed31aee67649e71d10e2793b39677ce2c04.
2021-12-25 17:10:43 -08:00
jp9000 f4317888de Revert "obs-filters: Remove duplicate code from chroma key filter"
This reverts commit 311330628d2eb197b5bff88c05bedcc21a47ca55.
2021-12-25 17:10:41 -08:00
Matt Gajownik babc07fa5c obs-browser: Include `atomic` for browser source destroy
Fixes build issues on older CEF versions (especially on Linux)
2021-12-25 08:52:20 +11:00
Norihiro Kamae 61c0a76fc0 obs-ffmpeg: Split file by PTS instead of DTS
If B-frame is enabled in video encoder, video packets have different PTS
and DTS, however audio packets do not. That caused audio packets at the
splitting point goes to a different file and audio glitch appeared in an
NLE.
2021-12-24 16:04:15 +09:00
Norihiro Kamae 550b1331ac obs-ffmpeg, UI: Reset timestamps at splitting file
This commit adds a setting to reset timestamps when splitting files.
Some NLEs cannot handle video files whose starting timestamp is not
zero. Default is enabed.
2021-12-24 15:59:26 +09:00
Norihiro Kamae ce92f441b5 obs-ffmpeg: Split ffmpeg_muxer output file by size or time
This commit adds 3 new properties to split output file in the output
`ffmpeg_muxer`.
- `max_time_sec` specifies the limit in seconds.
- `max_size_mb` specifies the limit in megabytes.
- `allow_overwrite` specifies to test an existing file.
If both `max_time_sec` and `max_size_mb` are not positive, the split
file feature won't be enabled.
Another output ffmpeg_mpegts_muxer shares the code but is not affected
since the output is used only for streaming.
2021-12-24 15:21:55 +09:00
Norihiro Kamae d64adb6784 obs-ffmpeg: separate generate_filename function 2021-12-24 11:49:27 +09:00
jp9000 8629d6a028 obs-vst: Fix race condition and prevent double invoke
1dde4c37a obs-vst: Fix VSTPlugin::effect race condition
e33e8ee62 obs-vst: Modify VSTPlugin::closeEditor()
2021-12-23 10:58:44 -08:00
Norihiro Kamae 685f8297e4 obs-ffmpeg: Set frame_size for audio codec parameter
This commit fixes an issue that the last audio packet is sometimes not
written into mp4 format. Since libavformat internally calculates the
packet duration from the frame_size specified in the codec parameter, it
is necessary to set frame_size.
2021-12-23 10:48:37 -08:00