Commit Graph

9278 Commits (535e7dfa157b68562ab185c09d6bcc2c9add2d3f)

Author SHA1 Message Date
Ryan Foster 05d29aa4e3 UI: Set default string size arg for QT_UTF8 / QString::fromUtf8
Our QT_UTF8(str) macro uses QString::fromUtf8(str) with no size
argument. In Qt5, QString::fromUtf8 uses a default value of -1 for the
size arg. If size is -1, it is taken to be strlen(str). In Qt6,
QString::fromUtf8 doesn't use a default value for the size arg, but has
the same behavior if you manually specify -1 for the size. Let's
manually specify -1 to maintain the same behavior between Qt5 and Qt6.

https://doc.qt.io/qt-5/qstring.html#fromUtf8
https://doc.qt.io/qt-6/qstring.html#fromUtf8
2021-03-09 09:16:16 -05:00
Ryan Foster 37971e7bf9 UI: Force plugins to use version appropriate Qt Network
Make building against either Qt5 or Qt6 easier by checking the Qt
version used and loading the appropriate Qt Network DLL.
2021-03-09 09:16:07 -05:00
Matt Gajownik b2fb0ca07f UI: Don't attempt to resize parent group when changing cursor
Fixes an issue where resizing a source did not resize the parent group.
2021-03-09 21:15:17 +11:00
Kurt Kartaltepe 513bcb8e35 UI: Cleanup Qt for Qt6
This changes cleans up some deprecated functions that were removed in
Qt6. Some are placed behind version ifdefs and others are replaced for
their non-deprecated Qt5 version.
2021-03-08 21:41:13 -08:00
Mike 40f99da8a2 UI: Fix Qt signal connection warnings
Closes obsproject/obs-studio#4264
2021-03-08 21:39:43 -08:00
Exeldro 901a030adf frontend-tools: Add edit script button 2021-03-08 08:37:37 -08:00
VodBox e81cf90c1e UI: Disable scroll and keyboard input for t-bar
closes #2951
2021-03-09 01:31:08 +13:00
VodBox d2e3d0da3c UI: Remove unnecessary code 2021-03-08 23:42:21 +13:00
VodBox 3046f3b578 UI: Fix grid mode scenes overlapping
fixes #2676
2021-03-08 23:33:54 +13:00
VodBox 58b2da73b3 UI: Fix transform dialog for screen readers 2021-03-08 21:51:20 +13:00
Clayton Groeneveld 753de748e5 UI: Remove redundant code
The UpdateSceneSelection function was doing the same thing as the
code in the SetCurrentScene function.
2021-03-07 22:53:08 -08:00
jpark37 a20b4c67eb libobs/util: Compiler barriers for ARM64 atomics
Unsure if the intrinsics imply ordering. Safer to assume they don't.
2021-03-07 21:11:32 -08:00
VodBox eb98505a2c UI: Fix memory leak with missing files dialog 2021-03-06 15:33:12 +13:00
Matt Gajownik adb8046b7c UI: Use clicked signal for buttons in Missing FIles dialog
Clicked includes the release, whereas pressed occurs before.
2021-03-05 21:14:56 +11:00
Christopher P Yarger fc6d2954fd obs-ffmpeg: Fix bug with obs_source_media_play_pause 2021-03-04 23:43:14 -08:00
Richard Stanway 6c0d234385 libobs: Minor fixes / code cleanups
Fixes some warnings generated by code analysis tools, removing redundant
checks etc.
2021-03-04 19:29:33 +01:00
Richard Stanway 13cfd95fef libobs-d3d11: Avoid temporary ComPtr objects
The ternary operator promotes both sides to the same type if possible,
so it created and destroyed a temporary ComPtr. Found by PVS Studio.
2021-03-04 19:29:00 +01:00
Richard Stanway 43a291806e decklink: Remove unnecessary obs-frontend-api dependency 2021-03-04 19:22:12 +01:00
jp9000 09c3892127 UI: Use more accurate wording 2021-03-01 18:28:43 -08:00
Robert de Bock da8c7e5131 UI: Fix typo
"Ideal" is an absolute.
2021-03-01 15:03:33 -08:00
PatTheMav 9da6fc67c4 CI: Fix missing entitlements on CEF components for obs-browser 2021-03-01 08:27:16 -08:00
pedanticdan bc3decc8d1 mac-virtualcam: DAL PlugIn check for custom png file 2021-03-01 07:40:13 -08:00
Doug Kelly 6a9f25c8ea mac-vth264: Clean up encoder list
When enumerating the list of encoders offered by VideoToolbox,
there's no reason we can't use the returned ID, which allows us to
remove the hardware/software encoder specific functions. At the
same time, this does add a slight complexity when localizing the
encoder name, so we can fall back to the OS-provided encoder name
if there's not a match.
2021-02-28 19:00:43 -08:00
Doug Kelly 437ba31cf6 cmake: Remove pagezero_size from linker options
Previous versions of LuaJIT required setting linker options
-pagezero_size and -image_base.  This was accomplished in commit
c9224edbad, but as of LuaJIT 2.1, this is no longer necessary, and
doing so results in the application being killed when run natively
on macOS ARM targets.
2021-02-28 19:00:43 -08:00
Doug Kelly 5d711ebbda mac-capture: Adjust mHostTime to milliseconds
The timestamp returned by mHostTime in the AudioTimeStamp structure
is the current timestamp equivalent to mach_absolute_time(), which
is relative to the machine's time base. In order to convert this
to milliseconds, it's necessary to get the host's timebase with
mach_timebase_info() and scale the timestamp accordingly, since
the rest of the timestamp synchronization code expects the timestamp
to be in milliseconds.

This is effectively equivalent to the code which was previously in
libobs/util/platform-coca.m, but must be applied here instead.
2021-02-28 19:00:43 -08:00
Doug Kelly 4ab5a3bea1 libobs: use clock_gettime_nsec_np() for macOS
macOS should use the function clock_gettime_nsec_np() to get the
current clock in nanoseconds, instead of manually using
mach_absolute_time() and manually adjusting the timebase. This
greatly simplifies the platform-specific code to manage the
current time in nanoseconds.
2021-02-28 19:00:43 -08:00
Colin Edwards 9b699f65d7
CI: Update macOS dependencies bundle 2021-02-27 21:30:58 -06:00
PatTheMav 516ed4458d mac-virtualcam: Handle missing DAL plugin destination directory 2021-02-26 13:29:49 -08:00
Georges Basile Stavracas Neto 7f27963caa libobs/util: Split bus name from interface
When calling D-Bus methods, three fields are required:

 * The bus name, which is what applications own when they
   want to expose themselves to D-Bus;

 * The object path, which represents a D-Bus object exported
   under a bus name;

 * The interface, which holds the methods and signals;

While out of pure coincidence all the D-Bus buses have a
matching interface name, it is technically incorrect to assume
that.

Add a new 'interface' field to service_info, and split the bus
name.
2021-02-25 12:32:44 -08:00
Georges Basile Stavracas Neto ec1b07cc85 libobs/util: Replace libdbus by GDBus
GDBus is more and better maintained than libdbus these days. In the
future, a potential Wayland-compatible capture plugin will need to
interact with D-Bus in a way that's way too complicated for libdbus,
and it won't be nice to have both libraries talking to the D-Bus
socket.

Replace the libdbus usage by GDBus. As it turns out, it results in less
code.
2021-02-25 12:32:44 -08:00
Georges Basile Stavracas Neto 94d2166951 libobs/util: Rename struct field 'id' to 'cookie'
All D-Bus interfaces call the unique identifier that is returned by their
calls "cookie", so rename the 'id' field to 'cookie' to match that.
2021-02-25 12:32:44 -08:00
Thomas Picquet 848395f326 rtmp-services: Add ePlay service
Closes obsproject/obs-studio#4263
2021-02-22 02:40:56 -08:00
PatTheMav 200a050937 mac-virtualcam: Fix codesign error after updating OBS 2021-02-22 02:37:58 -08:00
Matt Gajownik 472ce22a73 CI: Build on Ubuntu 18.04, use newer clang-format
There are too many issues with 20.04 to successfully build with
VirtualCam - the azure kernel is missing videodev headers. For now,
use 18.04 LTS directly for main CI builds.

Both 18.04 and 20.04 include clang-format-10 without issue.
2021-02-22 02:10:34 -08:00
jp9000 81a89e689f UI: Fix output resolution not properly changing
Fixes a bug where the output resolution wouldn't change when using a
service that uses the "supported resolutions" limitation. When switching
to a non-editable combo box, the signal used to detect whether the combo
box has had its value changed wouldn't work anymore because it was the
signal explicitly used for editable combos. So, to fix, just reapply the
normal combo box signal to detect when the value has been changed.

Fixes obsproject/obs-studio#4124
2021-02-17 03:31:06 -08:00
Gol-D-Ace 7a4844e2fc UI: Fix locale name 2021-02-15 18:16:07 +01:00
Clayton Groeneveld 3e4c2c0535 obs-ffmpeg: Fix replay save callback not working properly
Previously the save callback would be called when the replay buffer
hotkey was pressed and not when the saving of the replay was finished.
When the 'get_last_replay' procedure was called after the saved callback
function, it would return the incorrect path, as the path would still
be the previous path.
2021-02-15 02:40:00 -08:00
jpark37 744cb97524 libobs-winrt: Make Close() failures non-fatal 2021-02-14 23:11:07 -08:00
jpark37 17cb0acdd7 graphics-hook: Fix build without COMPILE_D3D12_HOOK
Just need to forward declare D3D12 type.
2021-02-14 22:20:14 -08:00
jpark37 23e9d4153e win-capture: D3D12 swap chain queue usage
Attempt to schedule shared texture copies against the command queue that
the game's swap chain uses to try to reduce artifacts. The heuristics
for obtaining the queue are not perfect, so provide a toggle to use the
previous behavior.
2021-02-14 02:06:02 -08:00
Jim 622d2f7658
Merge pull request #3338 from GeorgesStavracas/feaneron/egl-dmabuf
DMA-BUF importing for EGL renderers
2021-02-13 21:10:09 -08:00
Georges Basile Stavracas Neto ce50020414 flatpak: Enable Wayland
Expose the Wayland socket to the sandbox, and enable Wayland at build
time using the new ENABLE_WAYLAND define for CMake.
2021-02-14 12:36:23 +11:00
Georges Basile Stavracas Neto 7867d16e6b libobs-opengl: Implement DMA-BUF importing on EGL renderers
Implement device_texture_create_from_dmabuf for EGL/X11 and EGL/Wayland.
The code is shared between them, in a new gl-egl-common.c file.

This is currently limited to a few common RGB(A) formats for now, which
seems to cover most use cases.
2021-02-13 19:48:56 -03:00
Georges Basile Stavracas Neto b26073c5b2 deps-glad: Add DMA-BUF EGL extensions
Import the DMA-BUF importing extensions from GLAD.
2021-02-13 19:42:01 -03:00
Georges Basile Stavracas Neto f7a55f45fd libobs/graphics: Add Linux-only gs_texture_create_from_dmabuf()
DMA-BUF is a widespread Linux buffer sharing mechanism. It is what's
commonly used zero-copy screen sharing by Wayland compositors.

Add a new 'device_texture_create_from_dmabuf' vfunc to gs_exports,
and stub implementations to libobs-opengl. Add a new public method
gs_texture_create_from_dmabuf() that calls this vfunc.
2021-02-13 19:13:54 -03:00
Oliver Lietz 01c00cf271 rtmp-services: Add nanoStream Cloud / bintu
Closes obsproject/obs-studio#4086
2021-02-13 14:06:21 -08:00
Nirusu 2787e63d8e UI: Fix screen resolution for canvas size
In #3988, @RytoEx mentioned that the recent Qt upgrade to 5.15.2
introduced a regression in which Qt begins returning DPI/scaling
aware resolutions for each screen. While this was fixed for
new profiles, this was not reflected in the choice for the
Canvas (Base) Resolution in the Settings screen yet.

This commits fixes this issue, and calculates the correct
physical screen size again, respecting per-screen DPI scaling.
2021-02-12 15:28:26 -08:00
Georges Basile Stavracas Neto e64c61710f flatpak: Disable browser for now
The Chromium sandbox is conflicting with the Flatpak sandbox in a non-trivial,
non-workaroundable way. Until Chromium / CEF provides a way to unconditionally
disable the entire sandbox, let's not degrade the Flatpak experience.
2021-02-12 04:59:30 -08:00
Jim 190ab876cc
Merge pull request #2484 from GeorgesStavracas/feaneron/egl-wayland
EGL/Wayland (Wayland, pt 3)
2021-02-12 01:30:05 -08:00
jp9000 e8a1c082da Revert "UI: Add ability for stingers to use filters"
This reverts commit 36ab7b97cf.

The fact that a transition is a composition of two scenes was not
factored into the merging of this PR. Thus, it would apply to the
underlying scenes when transitioning, making the effectiveness of this
feature cause inconsistent rendering of the underlying scenes when
transitions are activated versus when they're not.
2021-02-11 22:34:55 -08:00